File tree Expand file tree Collapse file tree 2 files changed +20
-2
lines changed Expand file tree Collapse file tree 2 files changed +20
-2
lines changed Original file line number Diff line number Diff line change 5959
6060 - name : Run Playwright e2e tests
6161 run : pnpm test:e2e
62+
63+
Original file line number Diff line number Diff line change 1- import { defineConfig } from "@playwright/test" ;
1+ import { defineConfig , devices } from "@playwright/test" ;
22
33export default defineConfig ( {
44 testDir : "tests/e2e" ,
5- // You can add more Playwright options here if needed
5+ fullyParallel : true , // Run tests in parallel
6+ forbidOnly : ! ! process . env . CI , // Fail if test.only is left in code in CI
7+ retries : process . env . CI ? 2 : 0 , // Retry on failure in CI
8+ workers : process . env . CI ? 1 : undefined , // Limit workers in CI
9+ reporter : "html" , // Reporter to use
10+ use : {
11+ baseURL : "http://localhost:3000" , // Base URL for actions like page.goto()
12+ trace : "on-first-retry" , // Record trace only when retrying a failed test
13+ } ,
14+ webServer : {
15+ command : "pnpm start" , // Command to start the dev server
16+ url : "http://localhost:3000" , // URL to wait for
17+ reuseExistingServer : ! process . env . CI , // Reuse server locally, start fresh in CI
18+ timeout : 120 * 1000 , // Increase timeout for server start
19+ } ,
20+ // Optional: Configure projects for major browsers
21+ // projects: [ { name: 'chromium', use: { ...devices['Desktop Chrome'] } } ],
622} ) ;
You can’t perform that action at this time.
0 commit comments