Skip to content

test(cli): expect the client-side workspace ref resolution #13964 added - #14230

Merged
teamleaderleo merged 1 commit into
mainfrom
test/cli-workspace-ref-resolution-requests
Sep 24, 2026
Merged

teamleaderleo merged 1 commit into
mainfrom
test/cli-workspace-ref-resolution-requests

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Sep 24, 2026 •

Copy link
Copy Markdown
Collaborator

Why

#13964 (merged 10:20Z on 09-24) resolves a workspace:N ref inside the CLI before sending the command's own request. It first reads a parameterless workspace.list snapshot, and if that fails it scans windows. Four tests still counted the old request sequence, so they fail on every main full-suite run since then:

Test Observed on main Old expectation
"Default pane inspection JSON keeps IDs for agent targeting" 2 requests 1
"Explicit pane inspection ID formats remain respected" 2 requests 1
closeSurfaceRejectsMissingExplicitRefWithoutMutation workspace.list, window.list, surface.list surface.list
respawnPaneRejectsMissingExplicitUUIDWithoutMutation workspace.list, surface.list window.list, workspace.list, surface.list

The two pane-inspection tests came from #10674, which merged one minute before #13964. Each PR was green on its own base, so together they formed a semantic conflict. Both commands still refuse the missing target without mutating anything, and the tests still assert that.

What changed (tests only)

  • Pane-inspection ID tests: the helper drops one leading parameterless workspace.list before counting the command's request.
  • Close test: now asserts the full resolution fallback, then that the unresolved ref passes through on the surface.list request.
  • Respawn test: now expects the snapshot-first order.

These are the same edits #14211 makes while moving these files to a host-free target. They land here separately so main goes green now.

Verification

Focused run of CLIWorkspaceStableIDTests and CLIExplicitSurfaceRoutingTests on blacksmith-6vcpu-macos-15: 16 tests in 2 suites pass. run

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Summary by cubic

Fixes four CLI tests that failed on every main run since #13964 added client-side workspace:N ref resolution.

#13964 resolves a workspace:N ref by reading a parameterless workspace.list snapshot, then scanning windows, before sending the command's own request. These tests still expected the old request sequence; two came from #10674, which merged a minute before #13964. They now assert the new request sequence.

Test-only change. Commands still reject missing targets without mutating anything, which the tests continue to assert.

Written for commit a144f69. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • Tests
    • Updated CLI coverage for workspace and surface reference routing, including expected request sequences when references are unresolved.

#13964 resolves a workspace:N ref from a parameterless workspace.list
snapshot, then a window scan, before the command's own request. Four CLI
tests still counted the old request sequence and failed on every main run
since: the two pane-inspection ID-format cases (added by #10674 a minute
before #13964 merged), closeSurfaceRejectsMissingExplicitRef... and
respawnPaneRejectsMissingExplicitUUID.... They now expect the resolution
requests. Neither command mutates anything, which the tests still assert.
The same edits are in #14211, which moves these files to a host-free target.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

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

@coderabbitai

coderabbitai Bot commented Sep 24, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

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

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 2a45ef11-d478-4652-b422-0638f08e01ed

📥 Commits

Reviewing files that changed from the base of the PR and between 7434ad0 and a144f69.

📒 Files selected for processing (2)
  • cmuxTests/CLIExplicitSurfaceRoutingTests.swift
  • cmuxTests/CLIWorkspaceStableIDTests.swift

Included review availability: Your plan provides up to 10 included reviews per hour; 1 remains after this review.


📝 Walkthrough

Walkthrough

The CLI tests now account for client-side workspace-ref resolution. They expect parameterless workspace.list requests where applicable and remove that resolution request before checking the command request.

Changes

Workspace-ref resolution tests

Layer / File(s) Summary
Update CLI request expectations
cmuxTests/CLIExplicitSurfaceRoutingTests.swift, cmuxTests/CLIWorkspaceStableIDTests.swift
The explicit-routing tests expect the updated workspace and window listing requests. The stable-ID test helper filters a parameterless workspace.list request before asserting that one command request remains.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~8 minutes

Change: Other

Suggested reviewers: austinywang

Merge Risk: ⚪ Minimal · up to a144f

This updates CLI tests to account for workspace-reference resolution requests without changing CLI behavior. The inspected expectations and assertions reveal no actionable current-head risk, so the change is mergeable.

🚥 Pre-merge checks | ✅ 24 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 5 functions across 2 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (24 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies a test update for client-side workspace reference resolution and relates directly to the pull request changes.
Description check ✅ Passed The description explains the problem, lists the test changes, and records focused verification results. It does not use the template headings or include the checklist, but the required summary and tes…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Cmux Cloud Persistent Session And Early Input ✅ Passed PASS. The diff changes only two Swift test files. It updates CLI request-count and request-order assertions for workspace.list resolution. It does not change Cloud terminal creation, PTY readiness, …
Cmux Swift Actor Isolation ✅ Passed The pull request changes only cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. The diff updates test request expectations and adds a test helper; it in…
Cmux Swift Blocking Runtime ✅ Passed PASS. The pull request changes only two files under cmuxTests/. The added code updates deterministic request assertions and parses a JSON request to identify client-side workspace.list resolution.…
Cmux Browser Automation Off-Main ✅ Passed PASS. The pull request changes only two CLI test files: cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. The diff contains no browser.* socket comman…
Cmux Expensive Synchronous Load ✅ Passed PASS: The authoritative PR diff changes only cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. It adds or updates test request expectations and a test h…
Cmux Cache Substitution Correctness ✅ Passed PASS: The review-scoped diff changes only two files under cmuxTests/. It updates test request expectations and a test helper; it does not change production Swift, TypeScript, or JavaScript code. The…
Cmux No Hacky Sleeps ✅ Passed PASS: The pull request changes only two Swift test files. The diff adds or updates request-count and request-order assertions plus a JSON helper; it adds no TypeScript, JavaScript, shell, build/runtim…
Cmux Algorithmic Complexity ✅ Passed PASS: The review-scoped diff changes only cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. The changes update request expectations and add test-only JS…
Cmux Swift Concurrency ✅ Passed PASS: The PR changes only XCTest expectations and a JSON request-classification helper in two test files. The added code introduces no background queues, Combine state, completion-handler APIs, or fir…
Cmux Swift @Concurrent ✅ Passed PASS: The PR changes only synchronous test assertions and one existing async throws test helper body. It adds no @concurrent, @MainActor, or nonisolated async declaration, and it does not add …
Cmux Swift Package Boundaries ✅ Passed PASS: The diff changes only cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. It adds and updates test expectations and a test helper. It introduces no …
Cmux Swiftpm Lockfiles ✅ Passed PASS: The authoritative diff changes only two Swift test files. It contains no Package.swift, Package.resolved, .gitignore, workflow, Xcode project, or dependency changes. Therefore, the SwiftPM lockf…
Cmux Swift Logging ✅ Passed PASS. The diff changes only two Swift test files. Added lines contain test expectations, JSON parsing, and comments. No print, debugPrint, dump, NSLog, ad hoc diagnostic logging, Logger declar…
Cmux User-Facing Error Privacy ✅ Passed PASS: The PR changes only two test files. The diff updates request-count assertions and adds developer-only test comments/helper logic. It does not add or materially change production user-facing erro…
Cmux Full Internationalization ✅ Passed PASS. The review-scoped diff changes only two Swift test files: cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. The changes update request expectation…
Cmux Swiftui State Layout ✅ Passed PASS: The pull request changes only two Swift test files. The diff updates CLI request expectations and adds JSON request filtering. It introduces no SwiftUI view, ObservableObject, @Published, @Obser…
Cmux Architecture Rethink ✅ Passed PASS. The diff changes only two files under cmuxTests. It updates request-sequence assertions and adds JSON-based test request classification for existing client-side workspace resolution. It introd…
Cmux Swift Auxiliary Window Close Shortcuts ✅ Passed PASS: The PR changes only two files under cmuxTests (CLIExplicitSurfaceRoutingTests.swift and CLIWorkspaceStableIDTests.swift). The diff updates request-count and request-order test expectations…
Cmux Source Artifacts ✅ Passed The PR changes only two tracked Swift test source files: cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. The diff contains hand-written test expectati…
Cmux No Test Or Debug Seam In Production Source ✅ Passed The pull request changes only cmuxTests/CLIExplicitSurfaceRoutingTests.swift and cmuxTests/CLIWorkspaceStableIDTests.swift. No Swift file under a production Sources/ path is changed, so the prod…
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

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.

@teamleaderleo
teamleaderleo enabled auto-merge (squash) September 24, 2026 14:09
@teamleaderleo
teamleaderleo merged commit f2106e5 into main Sep 24, 2026
48 checks passed
teamleaderleo added a commit that referenced this pull request Sep 24, 2026
#14230 landed the same two workspace-ref expectations this branch had
already made in the moved CLIExplicitSurfaceRoutingTests; keep main's
stricter close-surface assertion (the full lookup sequence).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rustybret pushed a commit to rustybret/bmux that referenced this pull request Sep 24, 2026
cd7a4cf Prepare iOS 1.0.6 beta compatibility release (manaflow-ai#14112)
2d9b4e8 test: skip dead persistent-SSH restore tests and fix relay-less legacy fixtures after manaflow-ai#14216 (manaflow-ai#14222)
df44058 ci: run focused cmuxTests against products CI already compiled (manaflow-ai#14229)
06ec6cb Stop unrelated defaults writes and pane geometry changes from re-evaluating chrome-heavy views (manaflow-ai#14058)
185d99e chore(cli): remove dead persistent SSH PTY startup path (manaflow-ai#14231)
dddffea ci: take the build-fleet host lock for nightly mini builds (manaflow-ai#14233)
f2106e5 test(cli): expect the client-side workspace ref resolution manaflow-ai#13964 added (manaflow-ai#14230)
59fa5b9 docs(ci): fix persistent-compile pilot runbook drift (manaflow-ai#14206)

# Conflicts:
#	.github/workflows/app-host-test-rerun.yml
#	.github/workflows/nightly-mini-build.yml
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