From cd96015b9dbd071e3117e63ce149a1254910f422 Mon Sep 17 00:00:00 2001 From: yiling Date: Fri, 10 Jul 2026 15:35:59 +0800 Subject: [PATCH] feat(e2e): add browser selection support for app-level E2E tests --- playwright.config.ts | 45 ++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 43 insertions(+), 2 deletions(-) diff --git a/playwright.config.ts b/playwright.config.ts index ce0878bf..e5793256 100644 --- a/playwright.config.ts +++ b/playwright.config.ts @@ -25,8 +25,9 @@ export default defineConfig({ }, projects: [ + /* Harness Integration Projects */ { - name: 'harness', + name: 'harness-chromium', testDir: './packages/webui/e2e/tests', use: { ...devices['Desktop Chrome'], @@ -35,7 +36,27 @@ export default defineConfig({ }, }, { - name: 'app', + name: 'harness-firefox', + testDir: './packages/webui/e2e/tests', + use: { + ...devices['Desktop Firefox'], + // eslint-disable-next-line @typescript-eslint/naming-convention + baseURL: 'http://localhost:5199', + }, + }, + { + name: 'harness-webkit', + testDir: './packages/webui/e2e/tests', + use: { + ...devices['Desktop Safari'], + // eslint-disable-next-line @typescript-eslint/naming-convention + baseURL: 'http://localhost:5199', + }, + }, + + /* Fullstack App E2E Projects */ + { + name: 'app-chromium', testDir: './apps/web/e2e', fullyParallel: false, // run sequentially to avoid DB and storage conflicts use: { @@ -44,6 +65,26 @@ export default defineConfig({ baseURL: 'http://localhost:5200', }, }, + { + name: 'app-firefox', + testDir: './apps/web/e2e', + fullyParallel: false, + use: { + ...devices['Desktop Firefox'], + // eslint-disable-next-line @typescript-eslint/naming-convention + baseURL: 'http://localhost:5200', + }, + }, + { + name: 'app-webkit', + testDir: './apps/web/e2e', + fullyParallel: false, + use: { + ...devices['Desktop Safari'], + // eslint-disable-next-line @typescript-eslint/naming-convention + baseURL: 'http://localhost:5200', + }, + }, ], // Launch both the isolated harness server and the fullstack web app server