Repository navigation
Wait for a test's preview to close before pressing Escape, now that previews take Escape first inside modals - #5734
Merged
Merged
Conversation
…ew takes Escape first in a modal #5638 made a standing preview take Escape's first step inside a modal dialog too, and the obligation pick's focus preview now names the key that answers it, so three tests pressed Escape while a preview stood and watched it put the preview away instead of the step they assert: - `preview_parts` moved the pointer off its target and returned while the pointer's preview still stood for its dwell, so the next Escape in the command reference put that preview away and left the dialog open. It now waits for the preview to go, as its docstring already promised. - The obligation pick test puts the pick's focus preview away first, then asserts the next Escape lets go onto the page. Behaviour unchanged: Escape still closes the command reference and lets go of an answered pick once no preview stands. Closes #5703
Owner
|
#5746 stops a focus placement that isn't Tab from showing a preview, so Space on the obligation's pick no longer opens one. On that branch
|
Collaborator
Author
This was referenced Nov 9, 2026
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.
Three browser tests have failed on main since #5638. In each, a preview was still standing when the test pressed Escape, and #5638 deliberately made a standing preview take Escape's first step everywhere, inside a modal dialog included ("While a preview stands, Escape's first step puts it away"). The tests now let that step happen; the runtime is unchanged.
preview_parts(tests/render_harness.py) moved the pointer off its target and returned while the pointer's preview still stood for its 200 ms dwell. In the command reference, a modal, the next Escape put that preview away and left the dialog open. The helper now waits for the preview to go, which is what its docstring already promised ("the next reading is a new one"). This fixestest_slash_finds_page_text_without_a_target_kindandtest_tab_opens_the_comment_picker_with_individual_emoji_buttons.test_an_obligations_pick_stays_a_place_to_stand_after_the_answer: the focused pick now shows a focus preview naming its1key, since Previews say only the keys that reach a control and take Escape first wherever they show; the shift watch credits a preview riding its target #5638 draws every key that reaches a control from where the user stands. At Previews say only the keys that reach a control and take Escape first wherever they show; the shift watch credits a preview riding its target #5638's parent this preview said nothing and didn't show. The test now puts the preview away withput_preview_awayand checks the pick keeps focus. It then asserts, as before, that the next Escape lets go onto the page.The user-facing behavior these tests protect is unchanged. Once no preview stands, Escape closes the command reference and lets go of an answered pick.
Verification: all three failed on main
2f47830e4and pass with this change. The other 20 tests that callpreview_parts, including the journeytest_the_feature_gallery_exercises_its_core_journeys, also pass. One of them,test_z_names_what_it_takes_and_how_long_ago_in_a_fresh_tab, errors at teardown withunchanged write: hidden on div.lf-fp-quickon main without this change too. That error is tracked in #4745.Closes #5703 — automated triage