Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion packages/playground-website/e2e/playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,21 @@ const root = resolve(__dirname, "..");

const config: PlaywrightTestConfig = {
forbidOnly: !!process.env.CI,
// Safety net for the occasional e2e flake in CI.
retries: process.env.CI ? 1 : 0,
timeout: 120 * 1000,
expect: { timeout: 10_000 },
webServer: {
command: "pnpm watch",
// Serve the pre-built app instead of the Vite dev server (`pnpm watch`).
// The dev server transforms modules on demand and re-optimizes dependencies
// on the first page load; discovering a new dependency mid-load triggers a
// full page reload that aborts the in-flight `page.goto` (net::ERR_ABORTED),
// which intermittently failed whichever test ran first. `vite preview` serves
// the static build (the `test:e2e` task already depends on `build`), so there
// is no on-demand transform, dependency re-optimization, or HMR reload.
command: "vite preview --port 5173 --strictPort",
port: 5173,
cwd: root,
timeout: 120 * 1000,
reuseExistingServer: !process.env.CI,
},
Expand Down
Loading