Skip to content

Commit 15a83fa

Browse files
committed
Set a fallback for the Playwright base URL
1 parent babdeba commit 15a83fa

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

playwright.config.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ export default defineConfig({
2424
/* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
2525
use: {
2626
/* Base URL to use in actions like `await page.goto('/')`. */
27-
baseURL: process.env.BASE_URL,
27+
baseURL: process.env.BASE_URL || 'http://127.0.0.1:8888',
2828

2929
testIdAttribute: 'data-test-id',
3030

@@ -74,7 +74,7 @@ export default defineConfig({
7474
/* Run your local dev server before starting the tests */
7575
webServer: {
7676
command: 'pnpm dev:full',
77-
url: 'http://127.0.0.1:8888',
77+
url: process.env.BASE_URL || 'http://127.0.0.1:8888',
7878
reuseExistingServer: !process.env.CI,
7979
},
8080
})

0 commit comments

Comments
 (0)