Skip to content

Commit 7980c98

Browse files
committed
Fixing a timing flake in b2view tests
1 parent 28b1d78 commit 7980c98

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

tests/b2view/test_basics.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -168,9 +168,7 @@ async def test_tree_and_panel_focus(store_path):
168168
# Tab: tree -> meta -> vlmeta -> data and wraps back to the tree
169169
for expected in ["meta-scroll", "vlmeta-scroll", "data-scroll", "tree"]:
170170
await pilot.press("tab")
171-
await pilot.pause()
172-
assert app.focused is not None
173-
assert app.focused.id == expected
171+
assert await _wait_focus(pilot, expected) == expected
174172

175173
await pilot.press("down", "enter") # root -> level0, select + expand
176174
await pilot.pause()

0 commit comments

Comments
 (0)