chore: update playwright config for platform examples#23352
chore: update playwright config for platform examples#23352Ryukemeister merged 1 commit intomainfrom
Conversation
Graphite Automations"Add ready-for-e2e label" took an action on this PR • (08/26/25)1 label was added to this PR based on Keith Williams's automation. |
WalkthroughThe Playwright configuration in packages/platform/examples/base/playwright.config.ts was modified by changing the fullyParallel property from true to false. No other configuration options were altered. Possibly related PRs
Tip 🔌 Remote MCP (Model Context Protocol) integration is now available!Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats. ✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR/Issue comments)Type Other keywords and placeholders
Status, Documentation and Community
|
E2E results are ready! |
There was a problem hiding this comment.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
packages/platform/examples/base/playwright.config.ts (1)
39-46: Secrets leak risk: interpolating env values intowebServer.commandcan expose credentials in logs.Interpolating
X_CAL_SECRET_KEYand OAuth client secrets directly into the command string risks leakage in CI logs and local terminals. Prefer passing them via thewebServer.envmap so the command itself stays clean. Also avoids accidental injection of literal "undefined" when a var is missing.Apply this diff:
webServer: { - command: process.env.CI - ? `yarn workspace @calcom/atoms dev-on && yarn workspace @calcom/atoms build && rm -f prisma/dev.db && yarn prisma db push && NEXT_PUBLIC_IS_E2E=1 NODE_ENV=test NEXT_PUBLIC_X_CAL_ID="${process.env.ATOMS_E2E_OAUTH_CLIENT_ID}" X_CAL_SECRET_KEY="${process.env.ATOMS_E2E_OAUTH_CLIENT_SECRET}" NEXT_PUBLIC_CALCOM_API_URL="${process.env.ATOMS_E2E_API_URL}" VITE_BOOKER_EMBED_OAUTH_CLIENT_ID="${process.env.ATOMS_E2E_OAUTH_CLIENT_ID_BOOKER_EMBED}" VITE_BOOKER_EMBED_API_URL="${process.env.ATOMS_E2E_API_URL}" ORGANIZATION_ID=${process.env.ATOMS_E2E_ORG_ID} yarn dev:e2e` - : `rm -f prisma/dev.db && yarn prisma db push && yarn dev:e2e`, + command: process.env.CI + ? `yarn workspace @calcom/atoms dev-on && yarn workspace @calcom/atoms build && rm -f prisma/dev.db && yarn prisma db push && yarn dev:e2e` + : `rm -f prisma/dev.db && yarn prisma db push && yarn dev:e2e`, url: "http://localhost:4322", timeout: 600_000, + env: process.env.CI + ? { + NEXT_PUBLIC_IS_E2E: "1", + NODE_ENV: "test", + NEXT_PUBLIC_X_CAL_ID: process.env.ATOMS_E2E_OAUTH_CLIENT_ID, + X_CAL_SECRET_KEY: process.env.ATOMS_E2E_OAUTH_CLIENT_SECRET, + NEXT_PUBLIC_CALCOM_API_URL: process.env.ATOMS_E2E_API_URL, + VITE_BOOKER_EMBED_OAUTH_CLIENT_ID: process.env.ATOMS_E2E_OAUTH_CLIENT_ID_BOOKER_EMBED, + VITE_BOOKER_EMBED_API_URL: process.env.ATOMS_E2E_API_URL, + ORGANIZATION_ID: process.env.ATOMS_E2E_ORG_ID, + } + : undefined, reuseExistingServer: !process.env.CI, },Additionally, consider failing fast if required vars are missing in CI (place near the top of the file):
if (process.env.CI) { const required = [ "ATOMS_E2E_OAUTH_CLIENT_ID", "ATOMS_E2E_OAUTH_CLIENT_SECRET", "ATOMS_E2E_API_URL", "ATOMS_E2E_OAUTH_CLIENT_ID_BOOKER_EMBED", "ATOMS_E2E_ORG_ID", ]; const missing = required.filter((k) => !process.env[k]); if (missing.length) { throw new Error(`Missing required CI env vars: ${missing.join(", ")}`); } }
🧹 Nitpick comments (1)
packages/platform/examples/base/playwright.config.ts (1)
13-13: Confirm intent:fullyParallel: falseonly affects local runs (CI already serial).With
workers: process.env.CI ? 1 : undefinedon Line 11, CI runs are already single-worker, so disabling intra-file parallelism has no CI effect; it will only serialize tests within a file for local developers. If the goal is to deflake CI, this change won’t help there. If the goal is to make local runs more predictable due to shared state, this is fine. Optionally gate it behind an env var so devs can opt-in when needed.Optional toggle:
- fullyParallel: false, + fullyParallel: !!process.env.SERIAL_E2E ? false : true,
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
packages/platform/examples/base/playwright.config.ts(1 hunks)
🧰 Additional context used
📓 Path-based instructions (3)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/review.mdc)
**/*.ts: For Prisma queries, only select data you need; never useinclude, always useselect
Ensure thecredential.keyfield is never returned from tRPC endpoints or APIs
Files:
packages/platform/examples/base/playwright.config.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (.cursor/rules/review.mdc)
Flag excessive Day.js use in performance-critical code; prefer native Date or Day.js
.utc()in hot paths like loops
Files:
packages/platform/examples/base/playwright.config.ts
**/*.{ts,tsx,js,jsx}
⚙️ CodeRabbit configuration file
Flag default exports and encourage named exports. Named exports provide better tree-shaking, easier refactoring, and clearer imports. Exempt main components like pages, layouts, and components that serve as the primary export of a module.
Files:
packages/platform/examples/base/playwright.config.ts
⏰ Context from checks skipped due to timeout of 180000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (10)
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
- GitHub Check: Publish HTML report / publish-report
What does this PR do?
Visual Demo (For contributors especially)
A visual demonstration is strongly recommended, for both the original and new change (video / image - any one).
Video Demo (if applicable):
Image Demo (if applicable):
Mandatory Tasks (DO NOT REMOVE)
How should this be tested?
Checklist