Repository navigation
Fix the send progress test race on iOS - #1117
Merged
Merged
Conversation
The running status reaches the screen on its own stream after send progress clears, so the settle hold can still show the last Sending label when sendPrompt returns.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes a race in the iOS test
sendPrompt_attachmentInFlight_showsSendingPercent.When a send is accepted, the composer clears its progress first. The running status then reaches the screen through the session status stream, which is asynchronous. Until it lands, the turn pill's normal settle hold keeps the last label,
Sending 25%. The test asserted the label immediately aftersendPromptreturned, so it failed whenever the status arrived late. It now waits for the label to leaveSending.This is a test-only change. The hold is the pill's documented behavior, so product code is unchanged.
Checks
SessionChatViewModelTestsx25: 22 passed, 3 failed. All 3 failures arecatchUpChrome_showsSyncingPill, a separate flake this pull request does not change. The same test failed 1 of 25 baseline runs without this change.Issue
No tracked issue. Found through intermittent
ios-checksfailures.Risks / Follow-ups
catchUpChrome_showsSyncingPillis still flaky and can still failios-checks.testUserMessageOf190000Lines_hasASmallRowended the test process once in CI. The cause is unknown: no crash report or result bundle was retained. It did not reproduce in 90 focused runs or 3 full-suite runs, and this pull request does not address it.sendPrompt_postSendReloadMatchingUser_dropsOptimisticis unchanged. It passed 150 of 150 iterations under CPU load. A reload superseded by a newer timeline apply calls its completion before the newer apply publishes, which could explain its one failure, but that link is unconfirmed.Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.