CmuxNext Cloud: the start's harness login decision calls Rust; the Swift copy and its tests go (step B)
Merged
TE
3d ago+95+95+01234567890123456789-142-142-012345678901234567890123456789
Leo: "But why are there so many tests in Swift? It's Cloud code. Why is it not in Rust?" and "Why are there so many of these tests in the first place?"
What
Step B of the move #32305 started: the NEXT Cloud start's harness login decision is now Rust's, and the Swift copy and its tests go.
- Re-pins
CCmuxAppFFItocmux-app-ffi-2b457e203eac(base's newest FFI release; it carries #32305'scloud_harness_login*ops and #31927's hover ABI, which Swift does not call yet). CloudHarnessLoginDecision(CmuxNextCloudCredentials, which now linksCCmuxAppFFI) keeps only what the start knows so far. It reads the step, reason,readsMachine,guestTakesLogin,skippedTeamMachineand the record line fromcmux-cloud-start-corein one FFI call.loginProvider, the vm-kind probe and its parse are FFI calls too. If the FFI does not answer, the start skips the login with reasonffi-failed, and the record says so, so the skip is never silent.CloudStartChat+Logindrops its ownloginProviderand calls the decision's.CloudStartChatLoginTests: its 6 decision tests are deleted; the crate's 10 cargo tests cover every case. One bridge test replaces them. The 3 build-gate tests stay, because theUserDefaultsread stays in Swift.
No behavior change: the Rust rules are a 1:1 port, checked case for case in #32305.
Takes back #31305: on purpose. Its decision rules (the team-guest allowance included) now live, unchanged, in Rust (cmux-cloud-start-core, #32305), and this Swift type calls them. The behavior is the same.
Tests
cmux-ci run --class light --script scripts/ci/run-swift-testing-suites.sh ... CMUX_SWIFT_TEST_SUITES=CloudStartChatLoginTestsat a6b1903b9f75: 4 tests in 1 suite passed.scripts/cmux-next/check-app-ffi-pin.sh --verify-release: the sources match 2b457e203eac and the release checksum matches.- Rust side (from #32305):
cargo test -p cmux-cloud-start-coregave 10 passed; the FFIcloud_harness_logintest gave 4 passed.
Observed / Not run
I ran the suite above and the pin check. I did not run the full CmuxNext suite locally; CI runs it.
Changelog
none
š¤ Generated with Claude Code
Agent session: agent session