Skip to content

test: stop the XCTest import warning flood - #13163

Merged
teamleaderleo merged 1 commit into
mainfrom
fix-consistent-xctest-imports
Sep 20, 2026
Merged

teamleaderleo merged 1 commit into
mainfrom
fix-consistent-xctest-imports

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Sep 20, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Three cmuxTests files import XCTest with @_implementationOnly while the rest of the target use ordinary imports. The notification integration job in run 35494917252 emitted 122,136 inconsistent-XCTest-import warnings and about 90 MB of total logs.

Use ordinary XCTest imports in all three files. Test bodies and assertions are unchanged. This removes the import mismatch at its source; the compile-time saving has not been measured.

Testing

  • Reproduced the same diagnostic with a two-file XCTest module using mixed import modes on Apple Swift 6.2.4.
  • The identical compiler reproduction with consistent imports passes swiftc -typecheck -warnings-as-errors with no output.
  • git diff --check passes.
  • Full cmuxTests compilation is delegated to macOS compile admission in this PR's CI. No app runtime code changed, so no app reload or UI demo is needed.

Summary by cubic

Replaces @_implementationOnly import XCTest with a normal import XCTest in the three test files that still used the private import. This removes the source of the 122,136 inconsistent-XCTest-import warnings (about 90 MB of logs) from the notification integration CI job. Test bodies and assertions are unchanged, and no runtime code changed.

Written for commit 1631b47. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • Tests
    • Updated test module imports to use standard XCTest access, improving compatibility and test integration.

@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 20, 2026 •

Copy link
Copy Markdown

Review Change StackReview Change Stack

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: e23026f7-5b02-4e65-a786-383581bb584e

📥 Commits

Reviewing files that changed from the base of the PR and between 02cd032 and 1631b47.

📒 Files selected for processing (3)
  • cmuxTests/AutomationProcessSessionTests.swift
  • cmuxTests/KimiResumeReviewRegressionTests.swift
  • cmuxTests/WorkspaceUnitTests.swift

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


📝 Walkthrough

Walkthrough

Three test files now import XCTest normally instead of using @_implementationOnly.

Changes

Test import visibility

Layer / File(s) Summary
Regular XCTest imports
cmuxTests/AutomationProcessSessionTests.swift, cmuxTests/KimiResumeReviewRegressionTests.swift, cmuxTests/WorkspaceUnitTests.swift
The three test files now use standard XCTest imports without @_implementationOnly.

Priority: ➖ Normal

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Bug fix

Suggested reviewers: austinywang

🚥 Pre-merge checks | ✅ 25
✅ Passed checks (25 passed)
Check name Status Explanation
Description check ✅ Passed The description clearly explains the import changes, the reason for them, and the testing performed. It also explains why no demo video is needed. The review trigger and checklist sections are omitted…
Title check ✅ Passed The title clearly identifies the main change: stopping the XCTest import warning flood.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 3…
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 authoritative PR diff changes only three cmuxTests files, and each change replaces @_implementationOnly import XCTest with import XCTest. No Cloud terminal creation, persistent `cmux-…
Cmux Swift Actor Isolation ✅ Passed PASS: The authoritative diff changes only three files under cmuxTests/. Each change replaces @_implementationOnly import XCTest with import XCTest; test bodies and production Swift files are unc…
Cmux Swift Blocking Runtime ✅ Passed PASS. The authoritative diff changes only three files under cmuxTests, and each added line is only import XCTest. No semaphore, wait, sleep, delayed dispatch, polling, main-queue sync, or lock was…
Cmux Browser Automation Off-Main ✅ Passed PASS. The authoritative diff changes only three XCTest import lines in cmuxTests files. It does not add or move any browser.* socket command, WebKit wait, main-actor route, socket-worker route, browse…
Cmux Expensive Synchronous Load ✅ Passed The authoritative diff changes only three XCTest import lines in cmuxTests files, replacing @_implementationOnly import XCTest with import XCTest. Test bodies and all production code remain unch…
Cmux Cache Substitution Correctness ✅ Passed PASS: The reviewed range changes only three test files, and each change is a one-line replacement of @_implementationOnly import XCTest with import XCTest. No production Swift, TypeScript, or Java…
Cmux No Hacky Sleeps ✅ Passed PASS. The authoritative diff changes only three Swift files under cmuxTests, and each change only replaces @_implementationOnly import XCTest with import XCTest. The custom check applies to prod…
Cmux Algorithmic Complexity ✅ Passed PASS. The authoritative diff changes only three files under cmuxTests, with one XCTest import replacement per file. No production code or collection algorithm changed. The policy explicitly passes t…
Cmux Swift Concurrency ✅ Passed PASS. The pull request changes only three import lines: each @_implementationOnly import XCTest becomes import XCTest. The changed-line filter shows no new Dispatch, Combine, completion-handler, o…
Cmux Swift @Concurrent ✅ Passed PASS: The PR changes only three XCTest import declarations from @_implementationOnly import XCTest to import XCTest. The diff introduces no @concurrent, nonisolated async, actor-isolation, o…
Cmux Swift Package Boundaries ✅ Passed PASS. The authoritative diff changes only three files under cmuxTests. Each change replaces @_implementationOnly import XCTest with import XCTest; test declarations and bodies are unchanged. The…
Cmux Swiftpm Lockfiles ✅ Passed PASS. The pull request changes only three cmuxTests Swift files. Each change replaces @_implementationOnly import XCTest with import XCTest. The diff contains no Package.swift, `Package.resolved…
Cmux Swift Logging ✅ Passed PASS: The pull request changes only three XCTest import declarations, from @_implementationOnly import XCTest to import XCTest. No print, debugPrint, dump, NSLog, Logger, file logging, o…
Cmux User-Facing Error Privacy ✅ Passed The pull request changes only three test files. Each change replaces @_implementationOnly import XCTest with import XCTest; no user-facing errors, alerts, command output, API bodies, or recovery t…
Cmux Full Internationalization ✅ Passed PASS. The authoritative diff changes only three files under cmuxTests, and each change is only @_implementationOnly import XCTest to import XCTest. It adds no production user-facing text, locali…
Cmux Swiftui State Layout ✅ Passed The pull request changes only three XCTest import lines. The authoritative diff contains no new or modified SwiftUI state, GeometryReader layout, lazy/list row store reference, or render-time mutation…
Cmux Architecture Rethink ✅ Passed PASS. The scoped diff changes only three XCTest import declarations in test files. After replacing the old import spelling with the new spelling, each file is identical. The patch adds no timing, bl…
Cmux Swift Auxiliary Window Close Shortcuts ✅ Passed PASS. The review-scoped diff changes only three cmuxTests XCTest import lines. It adds or materially changes no NSWindow, NSPanel, NSWindowController, SwiftUI Window, or WindowGroup code. …
Cmux Source Artifacts ✅ Passed The pull request changes only three tracked Swift test source files: cmuxTests/AutomationProcessSessionTests.swift, cmuxTests/KimiResumeReviewRegressionTests.swift, and `cmuxTests/WorkspaceUnitTes…
Cmux No Test Or Debug Seam In Production Source ✅ Passed PASS: The reviewed diff changes only three files under cmuxTests/, outside the custom check scope of Swift files under **/Sources/** and not under **/Tests/**. Each change only replaces `@_imple…
✨ Finishing Touches
📝 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.

@greptile-apps

greptile-apps Bot commented Sep 20, 2026

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

The PR appears safe to merge because it only standardizes XCTest imports in test files.

Summary

This PR standardizes XCTest imports in three test files to eliminate inconsistent-import compiler warnings.

  • Replaces @_implementationOnly import XCTest with import XCTest.
  • Leaves test bodies, assertions, and production code unchanged.

Reviews (1) · Last reviewed commit: "test: use consistent XCTest imports to s..."

@teamleaderleo
teamleaderleo added this pull request to the merge queue Sep 20, 2026
@teamleaderleo
teamleaderleo removed this pull request from the merge queue due to a manual request Sep 20, 2026
@teamleaderleo
teamleaderleo added this pull request to the merge queue Sep 20, 2026
@teamleaderleo
teamleaderleo enabled auto-merge (squash) September 20, 2026 10:32
@teamleaderleo
teamleaderleo merged commit d10aa64 into main Sep 20, 2026
42 of 44 checks passed
rustybret pushed a commit to rustybret/bmux that referenced this pull request Sep 20, 2026
4b18fc9 ci: track package test helper inputs (manaflow-ai#13188)
b210493 Merge pull request manaflow-ai#13181 from manaflow-ai/ci-focused-app-host-tests
ced163c Merge pull request manaflow-ai#13180 from manaflow-ai/ci/remote-tmux-crash-diagnostics
9faf726 Merge pull request manaflow-ai#13178 from manaflow-ai/ci-reject-incomplete-test-runs
14c3ca1 Merge pull request manaflow-ai#13166 from manaflow-ai/ci-reuse-build-for-runtime-regressions
7c3574a ci: let the pre-merge Release check compile arm64 only (manaflow-ai#13195)
887839a ci: drop a stalled GhosttyKit download and resume it (manaflow-ai#13197)
70a244d Merge pull request manaflow-ai#13177 from manaflow-ai/ci-fast-static-preflight
fcad43f build: read Xcode projects with Foundation and drop XcodeProj and PathKit (manaflow-ai#13111)
76d80b1 ci: skip Release and its helper for test-only pull requests (manaflow-ai#13122)
fdc63e9 Merge pull request manaflow-ai#13176 from manaflow-ai/ci-reuse-queue-build-products
3162fee test: split an expression Xcode 27 cannot type-check (manaflow-ai#13126)
d10aa64 test: use consistent XCTest imports to stop compiler diagnostic flood (manaflow-ai#13163)
1b69bf9 test: stop real-Git reftable tests depending on a 2s wall clock (manaflow-ai#13186)
cad333b Merge origin/main into ci-fast-static-preflight
7522486 Merge origin/main into ci-reuse-build-for-runtime-regressions
43210e1 Bound automatic terminal titles before session persistence (manaflow-ai#13009)
674a0db ci: retire Depot macOS runners (manaflow-ai#13162)
f48ef36 Merge pull request manaflow-ai#13183 from manaflow-ai/ci-early-cli-smoke
ebbb17f ci: skip app-host teardown when setup never started (manaflow-ai#13179)
5fb6d8c Merge pull request manaflow-ai#13168 from manaflow-ai/ci-cache-r2-store
a348064 ci: skip compile admission when an earlier run compiled the same build inputs (manaflow-ai#13139)
88e102c reload: let a reused checkout keep one warm DerivedData across tags (manaflow-ai#13131)
7a049e9 Merge origin/main into ci-reuse-build-for-runtime-regressions
cd05c6e Merge origin/main into ci-fast-static-preflight
5cf41fa Merge origin/main into ci-reuse-queue-build-products
5a6322e test: guard early CLI smoke ordering
0438552 fix: pass R2 public URL through workflow environment
0716c59 test: bound app-host replay subprocesses
2e0b9b5 ci: terminate cancelled focused discovery
14bbad4 ci: keep R2 public URL configuration inside the cache actions
e342c67 ci: make focused run discovery cancellable
cf3984b test: avoid hard timeout in app-host classifier replay
251b050 ci: allow privileged crash report collection
7d9a7f2 Merge main after landing cache backend and suite policy
b6853ee ci: allow manual cache-only seeding for R2 rollout
81d3026 test: require manual cache seeding to skip app publication
6980f8e ci: harden remote tmux diagnostics collection
c24d77f ci: publish R2 cache pointers conditionally and repair failed writes
2432805 test: cover R2 pointer repair and out-of-order saves
4779d01 ci: continue past unusable build artifact candidates
9dd1579 test: reproduce corrupt candidate blocking product reuse
bfb43f5 ci: check CLI version and help before app-host fan-out
f2b0fae docs: use an existing suite in focused launcher example
2c04b6a ci: drain tar streams portably with BSD tar
c5e1d59 ci: pin focused tests to a commit and track the requested run
1a44bde ci: consume tar padding when restoring zstd caches
31d4fd9 test: cover padded R2 archives on macOS
a46567a ci: isolate R2 cache writes from release credentials
ce26a8e test: require early CLI smoke gate to propagate probe failures
18a67fb test: reproduce focused launcher revision and run attribution bugs
4dd543e test: require cache-only R2 credentials for cache saves
2c8412c ci: make product reuse attempt-safe and bound archive expansion
59fb526 ci: preserve remote tmux mirror crash diagnostics
d8107e4 test: cover artifact reruns, expansion limits and producer source checks
28a03e3 ci: reject interrupted app-host runs despite later passing summaries
302551d test: reproduce false-green app-host timeout and restart runs
bc3a63a ci: reject invalid static inputs before expensive validation
baf65d9 test: require successful static preflight before macOS admission
6cea5f0 ci: fall back when build identity cannot be established
7632c7e ci: reuse compatible compiled products in merge groups
8be0c54 ci: add an R2 bucket as a cache store every runner can read
25f50c3 test: behaviour of an R2-backed cache store script
17c2498 ci: reuse compiled app and UI products for runtime regressions
6ed96f4 test: require UI products in the shared CI build artifact
230ad52 ci: drop a timeout note about a DerivedData cache that no longer exists
b5ec5cc ci: stop restoring DerivedData in pull request jobs
a42ad38 Merge remote-tracking branch 'origin/main' into ci-cache-backend-switch
477fb0f ci: choose the cache store per dispatched run, and cover the nightly app build
03363d7 ci: let a repository variable move the seeded caches to the Warp store
f791f87 ci: pull request jobs restore caches and never save them
5b65bb1 test: pull request jobs must restore caches read-only
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