Repository navigation
test(ui): avoid app boot in MCP surface fixture - #178709
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: needs maintainer review before merge. What this changesThis PR serves an empty same-origin document before mounting the MCP component fixture, avoiding incidental application startup. Example: The browser test checks dashboard and inline MCP iframe backgrounds.
Review scores
ProductKind: Test only · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-authored PR makes a focused test-fixture improvement, with no actionable correctness or security findings. Priority: P3 Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherThe responsive browser suite loads UI modules from its Vite server, mounts the MCP component inside an application-context fixture, and reads computed iframe colors. flowchart LR
A[Responsive browser test] --> B[One-use document route]
B --> C[Same-origin empty page]
C --> D[Real MCP component and context]
D --> E[Computed background assertions]
Technical reviewBest possible solution: Keep the empty document local to this fixture while preserving the existing component, stylesheet, context provider, and assertions. Do we have a high-confidence way to reproduce the issue? Source inspection confirms the original fixture boots the application and then replaces its body; no target code was executed during this read-only review. Is this the best way to solve the issue? The change removes unnecessary work at the existing fixture owner without adding a parallel renderer or weakening the assertions. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 52714b572789. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
PR surfaceTests +10. Total +10 across 1 file. Added test files: 0. View PR surface stats
LabelsLabel changes:
Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 20, 2026, 3:35 PM ET / 19:35 UTC. |
|
Merged via squash auto-merge.
|
What Problem This Solves
The responsive layout suite's MCP App background case loads the full app, then discards its body and mounts a small component fixture. In full UI run 39477098124, that case took 10.536 seconds; the file took 37.754 seconds. App startup is incidental to its two iframe-background assertions.
Why This Change Was Made
Serve one empty same-origin document for this fixture's initial navigation. Keep the real MCP App registration, its component-owned CSS, application context, both component mounts, and both exact color assertions. The one-use route is page-scoped; module requests still go to the existing Vite server. No production code, test case, assertion, geometry wait, browser isolation, or dependency changes.
The accepted tradeoff is removing incidental shell startup from a component CSS fixture. The suite's actual app tests continue to exercise startup. Static relative UI imports avoid 311 boot-only files; that count excludes package/dynamic imports and is not a measured request count or speedup.
Evidence
Acceptance requires all unchanged responsive cases to pass and measured improvement in the same file/case on CI. Local proof passed once: frozen-lockfile install,
pnpm tsgo:ui, targeted type-aware lint/format, andpnpm test ui/src/pages/chat/chat-responsive.browser.test.ts --maxWorkers=1on the pinned default Bun runtime. All 66 local cases passed, including the three extra WebKit image-alignment cases skipped on Linux (63 baseline cases). Vitest took 61.54 s; wrapper 68.47 s. The MCP case took 2.292 s locally; comparing it directly with a different CI host would not establish a speedup. Exact-head CI unit results are now available below; all 14 full UI gates passed. Independent P0–P2 review found no actionable issue; the simplification pass kept only the one-use document fixture.Concurrent case durations do not add up to file or shard wall time. No shard saving is claimed from the historical baseline alone; full-unit step observations will be reported separately. No product visual change. Solid production refactor-checklist counts remain unchanged. No local E2E or app build under the campaign budget.
Exact-head CI39482614583, unit2 job118835318491 passed the same63names on merge1881ca94 (head3d18a370 into3508eba1). Latest completed-main responsive file was40.934 s/body39.482 s and its MCP case10.219 s; candidate27.691/26.209/4.311 s remains below both full-workload observations. Collection stayed about1.4 s. The same656-file unit inventory had a383 s Test step; no aggregate saving is attributed to this single case.
Latest completed scheduled-main shard comparison (39476345087): actual
Test Control UIstep 416 → 383 s (observed −33 s), with identical 656-file inventories. Both compared unit2 jobs passed. This is observed whole-shard elapsed, not causal savings assigned to this diff, and is not summed with overlapping module wall spans.Full exact-head run 39482614583 completed successfully with all 14 UI jobs passing. Merged as
994480ac503f791cde1a72fb2a89ef74e5c9205f, verified reachable fromorigin/main.