소스 검색

pytest: check if timing problem

Rodja Trappe 2 년 전
부모
커밋
5f1fbee1f3
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      tests/test_element.py

+ 1 - 0
tests/test_element.py

@@ -11,6 +11,7 @@ def test_keyboard(screen: Screen):
     ui.keyboard(on_key=lambda e: result.set_text(f'{e.key, e.action}'))
 
     screen.open('/')
+    screen.wait(0.5)
     assert any(s.endswith('keyboard.js') for s in screen.get_attributes('script', 'src'))
     assert screen.get_tags('span')  # NOTE keyboard dom element is a span
     ActionChains(screen.selenium).send_keys('t').perform()