summaryrefslogtreecommitdiff
path: root/crocoite/test_controller.py
diff options
context:
space:
mode:
authorLars-Dominik Braun <lars@6xq.net>2019-06-18 16:57:29 +0200
committerLars-Dominik Braun <lars@6xq.net>2019-06-18 16:57:29 +0200
commit9c1de8ebb7b9e00bc6afc9f2ed2978a003d9abd8 (patch)
tree4ad0c2a78e23896739d6dadbfbea9cfd1bb4d722 /crocoite/test_controller.py
parentb4669705fa8e581c17bbe0ca0c7cf4fadbd3deb8 (diff)
downloadcrocoite-9c1de8ebb7b9e00bc6afc9f2ed2978a003d9abd8.tar.gz
crocoite-9c1de8ebb7b9e00bc6afc9f2ed2978a003d9abd8.tar.bz2
crocoite-9c1de8ebb7b9e00bc6afc9f2ed2978a003d9abd8.zip
Re-inject behavior scripts on site reload
Fixes #13. Event handler’s push() is async now.
Diffstat (limited to 'crocoite/test_controller.py')
-rw-r--r--crocoite/test_controller.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/crocoite/test_controller.py b/crocoite/test_controller.py
index fa478a1..7e79dbe 100644
--- a/crocoite/test_controller.py
+++ b/crocoite/test_controller.py
@@ -130,11 +130,11 @@ async def test_idle_state_tracker ():
assert idle._idle
# idle change
- idle.push (PageIdle (False))
+ await idle.push (PageIdle (False))
assert not idle._idle
# nothing happens for other objects
- idle.push ({})
+ await idle.push ({})
assert not idle._idle
# no state change -> wait does not return
@@ -144,7 +144,7 @@ async def test_idle_state_tracker ():
# wait at least timeout
delta = 0.2
timeout = 1
- idle.push (PageIdle (True))
+ await idle.push (PageIdle (True))
assert idle._idle
start = loop.time ()
await idle.wait (timeout)