Skip to content

Commit 126b41e

Browse files
committed
add some timeout for webkit browser tests
1 parent a044f39 commit 126b41e

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

tests/playwright/shiny/bookmark/chat/chatlas/test_bookmark_chatlas.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ def test_bookmark_chatlas(page: Page, local_app: ShinyAppProc):
1212

1313
chat_controller = Chat(page, "chat")
1414

15-
chat_controller.expect_messages("Welcome!")
15+
# adding the timeout to avoid webkit errors
16+
chat_controller.expect_messages("Welcome!", timeout=2000)
1617

1718
chat_controller.set_user_input("Testing")
1819
chat_controller.send_user_input()

tests/playwright/shiny/bookmark/chat/client_state/test_bookmark_chat.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
from playwright.sync_api import Page
21
import re
32

3+
from playwright.sync_api import Page
4+
45
from shiny.playwright.controller import Chat
56
from shiny.run import ShinyAppProc
67

@@ -20,7 +21,7 @@ def test_bookmark_chatlas(page: Page, local_app: ShinyAppProc):
2021

2122
chat_controller.expect_messages("Welcome!\nTesting\nRepeater: Testing")
2223

23-
page.wait_for_url(re.compile(r".*\?.*"), timeout=2) # Wait up to 2 seconds
24+
page.wait_for_url(re.compile(r".*\?.*"), timeout=2) # Wait up to 2 seconds
2425

2526
page.reload()
2627

0 commit comments

Comments
 (0)