Description
Purpose
XCTest Nightly has failed twice in a row (runs 41578854330 on 2026-11-03 and 41773968778 on 2026-11-04), after green nights through 2026-11-02 at 343b7fcf41. Both fail in one test.
Current behavior
RunnerTests.testFreshCoordinateTapContainsUnavailableTextInputProbe (apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/UnitTests/RunnerTests+TextInputProbeTests.swift:239-240) sends the same type command twice, both with commandId: "type-after-unavailable-probe". The first send is expected to fail with TEXT_INPUT_NOT_FOCUSED; the second, after a tap that focuses the field, is expected to type.
Since #4140 (e4034a714d), the runner's command journal answers a repeated commandId from its recorded outcome. So the second send returns the first send's TEXT_INPUT_NOT_FOCUSED, and the field stays empty:
RunnerTests+TextInputProbeTests.swift:239: error: XCTAssertTrue failed
RunnerTests+TextInputProbeTests.swift:240: error: XCTAssertEqual failed: ("Optional("")") is not equal to ("Optional("must-not-type")")
The journal behavior is intended (ADR 0005); the test reuses an id it must not reuse.
Required behavior
- The second
typein this test sends its owncommandId. - XCTest Nightly passes the iPhone full suite.
- The PR lane's XCTest selection did not run this test for fix(ios): prevent duplicate mutations and preserve read retries #4140's journal change. If the selection map can cheaply route
RunnerCommandJournalchanges to the text-input probe tests, it does.
Completion conditions
- The test passes in the iPhone full suite.
pnpm check:xctest-selectionpasses.
Activity
apex-sentinel-staging commentedon Nov 4, 2026
Apex Sentinel · Issue review
Suggested label:
bugThe issue reports failing XCTest Nightly tests caused by
RunnerTests.testFreshCoordinateTapContainsUnavailableTextInputProbereusing the samecommandIdtwice, so the command journal returns the first failedTEXT_INPUT_NOT_FOCUSEDoutcome. It identifies the failing test, expected behavior, and completion conditions, making it actionable.Required sections
test(ios): give the post-probe type its own commandId (callstack#4261)