Skip to content

test: stabilize preferred-window workspace routing - #15385

Merged
teamleaderleo merged 1 commit into
manaflow-ai:mainfrom
teamleaderleo:fix/appdelegate-workspace-routing-test
Sep 28, 2026
Merged

teamleaderleo merged 1 commit into
manaflow-ai:mainfrom
teamleaderleo:fix/appdelegate-workspace-routing-test

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Sep 28, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • make the minimal-mode workspace-routing regression test explicitly focus its own window immediately before invoking the ambient preferred-window route
  • preserve the production routing behavior and the traffic-light inset assertion

Root cause

The test drained the main run loop after creating its window, then called addWorkspaceInPreferredMainWindow without reasserting focus. That API intentionally chooses the focused/key/main window. Under full-suite ordering, unrelated window activity could therefore route the returned workspace into another manager; the failure was Expected new workspace in test window, before the inset assertion ran.

Evidence

Before:

  • Full-suite run 36346707374, shard 4 failed testMinimalModeCollapsedSidebarResyncsTrafficLightInsetAfterNewWorkspaceCreation() because the created workspace was absent from the test window's manager.
  • The same test passed in surrounding full-suite runs 36341390537 and 36367062636, consistent with ambient focus/order dependence.

After:

  • python3 scripts/verify-local.py --only swift-syntax --swift-changed upstream/main passes for the one changed test file.
  • git diff --check upstream/main...HEAD passes.
  • Hosted changed-suite rerun: pending. No cmux app build or native test ran on Air Blue.

Impact map

  • Source of truth: the test's focused-window precondition for addWorkspaceInPreferredMainWindow.
  • Direct consumer: the minimal-mode new-workspace inset regression test.
  • Cross-surface effects: test-only; production sources and routing semantics are unchanged.
  • Residual risk: the assertion still verifies that the ambient route targets the focused window and that the new workspace receives the expected inset.

Review

An independent reviewer approved exact head 5a00294d5921530c1f3b7548325b0ecffb8ea630, confirming that the suite's focused-window capture updates synchronously and the added call establishes, rather than bypasses, the production route's intended precondition.

The isolated structured reviewer reported no actionable finding (0.98 patch-correctness confidence). The mechanical XCTest migration policy fired because this existing XCTest file was touched; it is rejected under the documented existing-suite exception because this patch adds no test or assertion, and moving this one maintenance change would split the tightly coupled AppDelegate routing suite.

— Mochi

Mergeability

  • Base SHA: e02c385b051c3fad814a8269ce10a0937e2dea2f
  • Head SHA: 5a00294d5921530c1f3b7548325b0ecffb8ea630
  • Conflict-only gate: passed; speculative merge 8701292045b8eb2f4538db19e5194f72cecb2ad5.

Changelog

none

@cursor

cursor Bot commented Sep 28, 2026

Copy link
Copy Markdown

Bugbot is paused — on-demand spend limit reached

Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.

@coderabbitai

coderabbitai Bot commented Sep 28, 2026

Copy link
Copy Markdown

Warning

Review limit reached

Next included review available in 15 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 10 included reviews currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Repository: manaflow-ai/cmux/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 9f3616d7-ca92-4c11-93f1-5432da7a34a7

📥 Commits

Reviewing files that changed from the base of the PR and between e02c385 and 5a00294.

📒 Files selected for processing (1)
  • cmuxTests/AppDelegateShortcutRoutingTests.swift

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@teamleaderleo
teamleaderleo merged commit 192ee4c into manaflow-ai:main Sep 28, 2026
57 of 60 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

Merge receipt for 5a00294d59: every check was green at merge (14 verified; 18 skipped by policy). Full suite runs on main after merge.

rustybret pushed a commit to rustybret/bmux that referenced this pull request Sep 28, 2026
9eb402d Sidebar: opt-in compact status glyph for agent, PR and branch state (manaflow-ai#14838)
0b2d3e0 ci: run CmuxCloud package tests and move 22 Cloud logic suites out of the app host (manaflow-ai#15333)
defccda fix(cloud): say a machine's id and age in its accessibility label (manaflow-ai#15326)
8b23dd7 ci: re-run lost-runner jobs; end the UI wait when compile admission fails (manaflow-ai#15400)
734cff3 ci: let the UI test lane replay the fuzzer regressions (manaflow-ai#15401)
c9b235a Refuse a split that would leave a pane below its minimum size (manaflow-ai#15392)
56eacd4 Describe memory-pressure hibernation the way it works (manaflow-ai#15290)
da27bbc ci: passing guard tests print no ::error annotations (manaflow-ai#15399)
93d0706 ci: explicit owned E2E runs take root runners; rescue jobs waiting in setup (manaflow-ai#15402)
f12f578 PR media: keep each tour's folder through the artifact hand-off (manaflow-ai#15405)
cd9d1c9 test: release offscreen terminal fixtures before the next suite (manaflow-ai#15322)
78c566c triage: severity and area labels, with the rules in the repo (manaflow-ai#15228)
54473f6 Serialize async test app contexts (manaflow-ai#15390)
192ee4c Stabilize minimal-mode workspace routing test (manaflow-ai#15385)
31a59ab Cloud machine list reports who created each machine (manaflow-ai#15261)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant