]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Add some more time for olbc_ht update in olbc_5ghz
authorJouni Malinen <j@w1.fi>
Sun, 18 Jan 2015 10:55:49 +0000 (12:55 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 18 Jan 2015 10:55:49 +0000 (12:55 +0200)
It looks like this test case is failing every now and then, so add some
more time for the olbc_ht value to get updated before reporting a
failure.

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

index f300efc7eaf5b91bf070a44b01b927cc188a24d3..c06db18b565dc9aeeecbd90a999a748a9d0b5436 100644 (file)
@@ -490,9 +490,15 @@ def test_olbc_5ghz(dev, apdev):
                    "ieee80211n": "0",
                    "wmm_enabled": "0" }
         hapd2 = hostapd.add_ap(apdev[1]['ifname'], params)
-        time.sleep(0.5)
-        status = hapd.get_status()
-        if status['olbc_ht'] != '1':
+        found = False
+        for i in range(20):
+            time.sleep(0.1)
+            status = hapd.get_status()
+            logger.debug('olbc_ht: ' + status['olbc_ht'])
+            if status['olbc_ht'] == '1':
+                found = True
+                break
+        if not found:
             raise Exception("Missing OLBC information")
     finally:
         if hapd: