Repository navigation
fix(ui): serve the mock playwright suite from a production build, not the dev server - #3163
Draft
Charlesthebird wants to merge 1 commit into
Draft
Charlesthebird wants to merge 1 commit into
Charlesthebird wants to merge 1 commit into
Conversation
… the dev server Both mock web servers ran `yarn dev`, so each page load fetched hundreds of unbundled modules through the service worker, and under load a plain `page.goto` could exceed the 30s test budget. The suite also tested dev-mode code rather than the bundle that ships. Each mock server now runs `vite build` into its own `outDir` and serves it with `vite preview`. The API-mode and example-extension pins are inlined at build time, so the bare and extension apps need separate builds. The mock backend is unchanged, and the build keeps `mockServiceWorker.js`. The live suite stays on `yarn dev`. Closes #3134 Verified with `yarn test:pw` (chromium, firefox, chromium-with-extension) on a heavily loaded machine: three runs on the build, 190/190 each, 2.1-2.6m wall. Two runs on the dev server before the change failed 8 and 5 tests and took 3.7-4.4m. `yarn lint` (0 errors), `yarn typecheck` and the `playwright/` vitest checks pass. Signed-off-by: Nicholas Bucher <behappy54321@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
cjlg-soloio
approved these changes
Oct 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 written by Claude (start)
Release note
Changes
Closes #3134. Each mock Playwright server now runs
vite buildinto its ownoutDirand serves it withvite preview, so pages load one bundle instead of hundreds of dev modules, and the suite tests the code that ships. The API mode and extension settings are fixed at build time, so the bare and extension apps get separate builds; the mock backend and the live suite are unchanged.Testing
yarn test:pwinui/.dist/e2e-<port>and the suite needs no retries.🤖 written by Claude (end)
🤖 Generated with Claude Code