Repository navigation
test: hold the deck's timers and motion until the page reads the wheel - #7421
Merged
Merged
Conversation
test_a_scroll_as_the_card_moves_on_keeps_the_page answers a card by key and then turns the wheel, asserting the wheel supersedes the arrival the answer schedules. Nothing ordered the two: on a starved CPU the wheel reached the page after the card's settle timer had fired, so the arrival focused the card, and once the flight had landed and scrolled, as the deck is designed to when no newer input has come. A trace showed the arrival running at the answer's input count, before the wheel's. The test now pauses the page's clock and holds the deck's motion before the answer, waits for the page to read the wheel, then lets both run. The behavior it protects is unchanged: a wheel while the card comes up keeps the page where the wheel took it and takes no focus. Before, at --cpu-throttle 8 on Linux: 3 of 6 copies failed; the macOS dispatch 46042055447 failed 2 of 6. After: 12 of 12 pass at --cpu-throttle 8. With the arrival's intent check removed, the test fails 3 of 3. Closes #7412
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.
test_a_scroll_as_the_card_moves_on_keeps_the_pageanswers a deck card by key, then turns the wheel, and asserts that the wheel supersedes the arrival the answer schedules. Nothing in the test ordered those two. On a starved CPU the wheel reached the page after the card's 250 ms settle timer had fired. The arrival then focused#tall-ask(the scheduled macOS failure), or the landing scrolled the page back (thescrollY287 / 272 failures in the macOS probe). The deck does both by design when no newer input has arrived. An instrumented run showed each failing copy's arrival running at the answer's input count, before the wheel's.The test now pauses the page's clock (
clocked) and holds the deck's motion (HOLD_MOTION) before the answer. It waits until the page has read the wheel, then lets both run. The protected behavior is unchanged: a wheel turned while the card comes up leaves the page where the wheel took it, and focus doesn't move to the card. Only the test file changes.main)--cpu-throttle 8As a negative control, I removed the
moves()check from the deck's delayed arrival, and the test failed 3 of 3.#7412 names four other macOS failures. Each passed all 6 copies in the same macOS probe, so they wait on a recurrence and this PR doesn't touch them.
Closes #7412 — automated triage