summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2022-01-20 14:36:38 +0100
committerBastien Nocera <hadess@hadess.net>2022-01-20 14:37:19 +0100
commitd1cb796fd6bdbbf5ea07dd179a0869e5fe5f831b (patch)
tree1ee84ec0d5ebd25efce1d7244c292be407c14540 /tests
parentee4b8916e5d6b915d34889d9b0340a9277a3b499 (diff)
downloadgnome-bluetooth-d1cb796fd6bdbbf5ea07dd179a0869e5fe5f831b.tar.gz
tests: Make tests faster
By using smaller timeouts when waiting for events on the mainloop.
Diffstat (limited to 'tests')
-rwxr-xr-xtests/integration-test.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/integration-test.py b/tests/integration-test.py
index 543f3876..39000499 100755
--- a/tests/integration-test.py
+++ b/tests/integration-test.py
@@ -77,7 +77,7 @@ class OopTests(dbusmock.DBusTestCase):
def wait_for_mainloop(self):
ml = GLib.MainLoop()
- GLib.timeout_add_seconds(1, ml.quit)
+ GLib.timeout_add(100, ml.quit)
ml.run()
def wait_for_condition(self, condition, timeout=5):
@@ -86,7 +86,7 @@ class OopTests(dbusmock.DBusTestCase):
def timeout_cb():
nonlocal timed_out
timed_out = True
- GLib.timeout_add_seconds(1, timeout_cb)
+ GLib.timeout_add(100, timeout_cb)
while not condition() and not timed_out:
ctx.iteration(True)