test: fix RuntimeWarnings in multi-tab concurrency test
This commit is contained in:
@@ -172,6 +172,8 @@ async def test_session_state_concurrency_with_popup(service, session):
|
|||||||
new_page = AsyncMock()
|
new_page = AsyncMock()
|
||||||
new_page.on = MagicMock()
|
new_page.on = MagicMock()
|
||||||
new_page.is_closed = MagicMock(return_value=False)
|
new_page.is_closed = MagicMock(return_value=False)
|
||||||
|
new_page.url = "https://new.test"
|
||||||
|
new_page.bring_to_front = AsyncMock()
|
||||||
service._handle_new_page(session, new_page)
|
service._handle_new_page(session, new_page)
|
||||||
# Yield to let the registration task start (it will block on the lock)
|
# Yield to let the registration task start (it will block on the lock)
|
||||||
await asyncio.sleep(0.01)
|
await asyncio.sleep(0.01)
|
||||||
|
|||||||
Reference in New Issue
Block a user