ci: make playwright tests more stable with additional settings (#547)

make playwright more stable on ci: reduce number of workers,
increase retries and timeouts
This commit is contained in:
Ilya Kreymer
2026-08-11 13:36:12 -07:00
committed by GitHub
parent dada76f7c8
commit f76ba228f1
+13 -2
View File
@@ -2,7 +2,18 @@
import { defineConfig, devices } from "@playwright/test"; import { defineConfig, devices } from "@playwright/test";
export default defineConfig({ export default defineConfig({
reporter: process.env.CI ? "github" : "list", reporter: process.env.CI ? "github" : "list",
expect: { timeout: 30_000 },
timeout: 60_000,
expect: { timeout: 60_000 },
workers: process.env.CI ? 2 : undefined,
retries: process.env.CI ? 2 : 0,
use: {
trace: "retain-on-failure",
screenshot: "only-on-failure",
video: "retain-on-failure",
},
projects: [ projects: [
{ {
name: "chrome", name: "chrome",
@@ -36,5 +47,5 @@ export default defineConfig({
timeout: 120 * 1000, timeout: 120 * 1000,
reuseExistingServer: !process.env.CI, reuseExistingServer: !process.env.CI,
}, },
], ]
}); });