Refine desktop setup and remove bundled app center apps

This commit is contained in:
inman
2026-06-04 09:58:58 +08:00
parent 6153579b90
commit 84128dbe23
73 changed files with 3888 additions and 2024 deletions

View File

@@ -31,7 +31,7 @@ function stableStringify(value: unknown): string {
}
test.describe('Zhinian delivery smoke', () => {
test('covers setup, login, chat quick capabilities, history, workspace pages, Travel Resource Ordering, and Quick Video Creation shell', async ({ launchElectronApp }) => {
test('covers setup, login, chat quick capabilities, history, workspace pages, and cleared App Center', async ({ launchElectronApp }) => {
const app = await launchElectronApp();
await installIpcMocks(app, {
@@ -62,22 +62,6 @@ test.describe('Zhinian delivery smoke', () => {
port: 18789,
pid: 12345,
}),
[hostKey('/api/apps/nianxx-play/status')]: hostJson({
success: true,
running: true,
starting: false,
managed: true,
baseUrl: 'http://127.0.0.1:3000',
port: 3000,
}),
[hostKey('/api/apps/nianxx-play/start', 'POST')]: hostJson({
success: true,
running: true,
starting: false,
managed: true,
baseUrl: 'http://127.0.0.1:3000',
port: 3000,
}),
[hostKey('/api/channels/accounts')]: hostJson({ success: true, channels: [] }),
[hostKey('/api/cron/jobs')]: hostJson({
jobs: [{
@@ -178,20 +162,9 @@ test.describe('Zhinian delivery smoke', () => {
await page.getByTestId('sidebar-nav-app-center').click();
await expect(page.getByTestId('app-center-page')).toBeVisible();
await expect(page.getByTestId('app-center-item-product-center')).toBeVisible();
await page.getByTestId('app-center-item-product-center').click();
await expect(page.getByTestId('product-center-page')).toBeVisible();
await expect(page.getByTestId('product-center-frame')).toHaveAttribute('src', /https:\/\/ticket\.nianxx\.cn\/.*zhinianEmbed=1/);
await expect(page.getByTestId('product-center-frame')).toHaveAttribute('partition', 'persist:yinian-travel-resource-ordering');
await page.getByTestId('product-center-back').click();
await expect(page.getByTestId('app-center-page')).toBeVisible();
await expect(page.getByTestId('app-center-item-nianxx-play')).toBeVisible();
await page.getByTestId('app-center-item-nianxx-play').click();
await expect(page.getByTestId('nianxx-play-page')).toBeVisible();
await page.getByTestId('nianxx-play-nav-planning').click();
await expect(page.getByTestId('nianxx-play-page')).toBeVisible();
await page.getByTestId('nianxx-play-back').click();
await expect(page.getByTestId('app-center-page')).toBeVisible();
await expect(page.getByText('暂无应用')).toBeVisible();
await expect(page.getByTestId('app-center-item-product-center')).toHaveCount(0);
await expect(page.getByTestId('app-center-item-nianxx-play')).toHaveCount(0);
} finally {
await closeElectronApp(app);
}