-
Notifications
You must be signed in to change notification settings - Fork 2
fix: enable mock server for E2E tests to fix sidebar rendering failures #1221
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -25,6 +25,7 @@ | |||||||||||
| "start:mock": "pnpm msw:init && vite preview", | ||||||||||||
| "build:plugin": "tsc -p tsconfig.plugin.json", | ||||||||||||
| "build": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=false vite build && pnpm build:plugin", | ||||||||||||
| "build:e2e": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=true vite build && pnpm build:plugin", | ||||||||||||
| "build:vercel": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=true vite build && pnpm build:plugin", | ||||||||||||
|
Comment on lines
+28
to
29
|
||||||||||||
| "build:e2e": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=true vite build && pnpm build:plugin", | |
| "build:vercel": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=true vite build && pnpm build:plugin", | |
| "build:mock": "pnpm msw:init && tsc && VITE_USE_MOCK_SERVER=true vite build && pnpm build:plugin", | |
| "build:e2e": "pnpm build:mock", | |
| "build:vercel": "pnpm build:mock", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The console build is now executed outside Turbo (
pnpm --filter @object-ui/console build:e2e), which means Turbo caching won’t apply to that portion of the build. If CI build time becomes an issue, consider addingVITE_USE_MOCK_SERVERto Turbo’s tracked env (turbo.jsonglobalEnv/task env) and running the console build via Turbo with the env set, so cache correctness and performance are both preserved.