]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Make dbus_wps_oom more robust
authorJouni Malinen <j@w1.fi>
Sun, 6 Dec 2015 15:10:06 +0000 (17:10 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 6 Dec 2015 15:10:06 +0000 (17:10 +0200)
It was possible for the BSSs object property change signal to be
generated during the OOM test case for Get(). If that happened, the
signal was not sent out, but the following Get(BSSs) operation succeeded
unexpectedly which resulted in a test failure. Make this less likely to
happen by waiting 50 ms between the scan and Get(BSSs) operation. This
should be sufficient to cover most cases since wpa_supplicant uses 5 ms
timeout for D-Bus property changed updates.

Signed-off-by: Jouni Malinen <j@w1.fi>
tests/hwsim/test_dbus.py

index 399b4aff8ea8eee06e31543a108abaa55699986e..7666dbb9669c5f1f71aad0b5781dded79598b515 100644 (file)
@@ -480,6 +480,7 @@ def test_dbus_wps_oom(dev, apdev):
     bssid = apdev[0]['bssid']
     dev[0].scan_for_bss(bssid, freq=2412)
 
+    time.sleep(0.05)
     for i in range(1, 3):
         with alloc_fail_dbus(dev[0], i, "=wpas_dbus_getter_bsss", "Get"):
             if_obj.Get(WPAS_DBUS_IFACE, "BSSs",