Skip to content

Commit 5a4142d

Browse files
committed
add asgiref dep + set default timeout on page
1 parent a2bd7ad commit 5a4142d

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

requirements/pkg-deps.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ jsonpatch >=1.32
55
fastjsonschema >=2.14.5
66
requests >=2
77
colorlog >=6
8+
asgiref >=3

src/idom/testing/display.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
from playwright.async_api import Browser, BrowserContext, Page, async_playwright
88

99
from idom import html
10+
from idom.config import IDOM_TESTING_DEFAULT_TIMEOUT
1011
from idom.types import RootComponentConstructor
1112

1213
from .backend import BackendFixture
@@ -57,6 +58,8 @@ async def __aenter__(self) -> DisplayFixture:
5758
browser = self._browser
5859
self.page = await browser.new_page()
5960

61+
self.page.set_default_timeout(IDOM_TESTING_DEFAULT_TIMEOUT * 1000)
62+
6063
if not hasattr(self, "backend"):
6164
self.backend = BackendFixture()
6265
await es.enter_async_context(self.backend)

0 commit comments

Comments
 (0)