// THE @serial SPECS (plans/e2e-speed.md S5): with more than one worker these // run in a project of their own, AFTER the parallel one (its `teardown`, which // Playwright runs even when a parallel test failed), on one worker. With one // worker there is one project and this list changes nothing. // // Two reasons put a file here, and only these: // - it writes into the CHECKOUT, not its slot's data root: a site's or the // hub's build stage makes `export/out` (EXPORT_NEXT_BIN's fake copies the // composed bundle there), a homepage build `homepage/out` — one each for // every slot; // - it times wall-clock behaviour that contention bends (a cooldown, a // pacing gap, an audio check's interval), or was a load flake in a gate // run (release 19/20 records: storage-locations, sites-crud, whisper). // A file that passes alone and fails beside others joins with its reason (the // first full runs at 2 and 3 workers added five). export const SERIAL_SPECS: readonly string[] = [ // the checkout's build outputs "build.spec.ts", "deploy-page.spec.ts", "publish.spec.ts", "publish-lane.spec.ts", "site-publish-preview.spec.ts", "sites-crud.spec.ts", "sites-homepage.spec.ts", // timing under contention "pacing.spec.ts", "rate-limit.spec.ts", "audio-check-scenarios.spec.ts", "fetch-window.spec.ts", "channel-storage.spec.ts", "storage-locations.spec.ts", "whisper.spec.ts", // red once under 2 or 3 workers, green alone (r24 S5b measurement, 2026-10-10) "backfill.spec.ts", "channels.spec.ts", "settings.spec.ts", "cleanup-page.spec.ts", "sync-deep.spec.ts", ]; const escape = (s: string) => s.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"); /** Matches a serial spec file's path (Playwright's testMatch/testIgnore). */ export const SERIAL_SPEC_PATTERN = new RegExp(`(^|/)(${SERIAL_SPECS.map(escape).join("|")})$`);