From 9c9883b66077b64b90190e9c3bc3983c78343f27 Mon Sep 17 00:00:00 2001 From: taroj1205 Date: Fri, 16 May 2025 12:51:48 +1200 Subject: [PATCH] fix(playwright.config): update web server command and URL for local development - Modified the web server command to use 'npm run start' in CI environments and 'npm run dev' locally. - Changed the URL from 'http://127.0.0.1:3000' to 'http://localhost:3000' for consistency. - Added a port specification for clarity. --- playwright.config.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/playwright.config.ts b/playwright.config.ts index c0fb088..96c0b9d 100644 --- a/playwright.config.ts +++ b/playwright.config.ts @@ -65,8 +65,9 @@ export default defineConfig({ /* Run your local dev server before starting the tests */ webServer: { - command: 'npm run dev', - url: 'http://127.0.0.1:3000', + command: process.env.CI ? 'npm run start' : 'npm run dev', + url: 'http://localhost:3000', + port: 3000, reuseExistingServer: !process.env.CI, }, });