Repository navigation
🤖 tests: setupWorkspaceView and withSharedWorkspace wait for workspace setup to end - #7546
Merged
Merged
Conversation
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. |
Contributor
🟢 e2e stories (Haiku): 14 passed27 agent steps · 7 replayed from cache · 32 model calls · 224.9k tokens (72% cached) All 14 tests in 9 files
e2e 0.20.0 · 3m 4s · web · run artifacts 🟢 e2e Electron stories (Haiku): 3 passed3 agent steps · 3 model calls · 7.9k tokens (22% cached) All 3 tests in 3 files
e2e 0.20.0 · 18.2s · electron · run artifacts 🟢 e2e agent repros (Haiku): no tests selectedSpend: $0.00 of the $1.00 cap (proxy ledger) e2e 0.20.0 · 5.3s · 2 targets (web, phone) · run artifacts |
github-merge-queue
Bot
removed this pull request from the merge queue due to failed status checks
Oct 26, 2026
github-merge-queue
Bot
removed this pull request from the merge queue due to failed status checks
Oct 26, 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.
Summary
setupWorkspaceView(tests/ui/helpers.ts) andwithSharedWorkspace(tests/ipc/sendMessageTestHelpers.ts) now return only after workspace setup has ended. UI tests no longer race the controls that setup holds back: the row's actions menu, quick archive, and the Review panel.Fixes #7543
Background
While
metadata.isInitializingis true, a sidebar row shows a cancel button in place of its actions menu, hides quick archive, and the Review tab shows a placeholder.setupWorkspaceViewdid not wait for setup, andwithSharedWorkspacewaited forinit-endonly 1.5 s, best effort. #7450 and #7541 fixed this race in single tests. In an instrumented run of all oftests/ui, 224 of 328setupWorkspaceViewcalls found the row still in setup.Implementation
setupWorkspaceView: after it selects the row, it waits up to 30 s for the row's actions-menu trigger (button[data-workspace-id=<id>][aria-haspopup]). The row renders that trigger only after setup. The wait uses this positive signal, not the absence of the cancel button's label text: if the trigger ever goes away, the wait fails loudly instead of passing at once. The helper has no ORPC client, so it waits on the DOM.withSharedWorkspace:env.services.initStateManager.waitForInit(workspaceId)replaces the 1.5 s best-effort wait, ascreateAppHarnessalready does. It never throws.waitForInitCompletecalls from 🤖 tests: the lifecycle archive tests wait for workspace setup before using the row's archive controls #7541 inlifecycle.test.tsare no longer needed, so they are removed. 🤖 tests: the review focus test waits for the real panel before Ctrl+2 #7450's Review-panel mount wait infocus.test.tsstays, because the test uses that element. No caller needs the workspace during setup:actionsMenu.test.tsusescreateAppHarnessand its own init wait, andinitMessage.test.tsis a component test. So there is no opt-out.Validation
.xum/inithook withsleep 8, committed in the test repo (not in this PR), and the lifecycle archive tests without their per-test waits. With this PR: 3/3 pass. With main's helpers: 3/3 fail (Quick archive button not found,Workspace actions menu button not found).tests/ui(91 suites, 482 tests) passes. Run time: main 428/523/761 s and this change 325/654/672/338/642 s, interleaved on a shared host, so the difference is within noise. The new waits add 80 s in total over 328 calls (max 587 ms). That is at most about 5% of wall time with 4 workers, and less in practice, sincecreateAppHarnesscallers waited for init anyway.Generated with
xum• Model:anthropic:claude-opus-5-5• Thinking:high• Cost:$266.13