@@ -4,14 +4,15 @@ import { defineConfig, devices } from '@playwright/test';
44 * See https://playwright.dev/docs/test-configuration.
55 */
66export default defineConfig ( {
7+ globalSetup : './global-setup.ts' ,
78 testDir : './tests' ,
89 /* Run tests in files in parallel */
910 fullyParallel : true ,
1011 /* Fail the build on CI if you accidentally left test.only in the source code. */
1112 forbidOnly : ! ! process . env . CI ,
1213 /* Retry on CI only */
1314 retries : process . env . CI ? 2 : 0 ,
14- workers : process . env . CI ? 2 : undefined ,
15+ workers : process . env . CI ? 4 : undefined ,
1516 maxFailures : process . env . CI ? 5 : undefined ,
1617 /* Reporter to use. See https://playwright.dev/docs/test-reporters */
1718 reporter : 'html' ,
@@ -21,7 +22,7 @@ export default defineConfig({
2122 baseURL : 'http://localhost:4005' ,
2223
2324 /* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */
24- trace : 'on-first-retry ' ,
25+ trace : 'retain- on-failure ' ,
2526 } ,
2627
2728 projects : [
@@ -38,11 +39,13 @@ export default defineConfig({
3839 {
3940 name : 'serial-tests chromium' ,
4041 use : { ...devices [ 'Desktop Chrome' ] } ,
42+ workers : 1 ,
4143 testMatch : '**/*.serial.spec.ts' ,
4244 dependencies : [ 'chromium' , 'firefox' ] ,
4345 } ,
4446 {
4547 name : 'serial-tests firefox' ,
48+ workers : 1 ,
4649 use : { ...devices [ 'Desktop Firefox' ] } ,
4750 testMatch : '**/*.serial.spec.ts' ,
4851 dependencies : [ 'chromium' , 'firefox' , 'serial-tests chromium' ] ,
0 commit comments