diff mbox

[3/8] tests: increase timeout for remote tests

Message ID 1466702196-26828-3-git-send-email-jonathan@wizery.com
State Changes Requested
Headers show

Commit Message

Jonathan Afek June 23, 2016, 5:16 p.m. UTC
Some operations take longer time on real hardware than
on hwsim. This patch increases 3 timeouts so that
the tests will pass on real hardware too.

Signed-off-by: Jonathan Afek <jonathanx.afek@intel.com>
---
 tests/hwsim/test_ap_csa.py    | 2 +-
 tests/hwsim/test_ap_qosmap.py | 2 +-
 tests/hwsim/wpasupplicant.py  | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

Comments

Jouni Malinen June 27, 2016, 10:39 a.m. UTC | #1
On Thu, Jun 23, 2016 at 08:16:31PM +0300, Jonathan Afek wrote:
> Some operations take longer time on real hardware than
> on hwsim. This patch increases 3 timeouts so that
> the tests will pass on real hardware too.

Could these be made conditional on the test cases being run remotely? I
would not really want to slow down mac80211_hwsim testing with
unnecessarily long waits.
diff mbox

Patch

diff --git a/tests/hwsim/test_ap_csa.py b/tests/hwsim/test_ap_csa.py
index 7ff94a6..48f1a88 100644
--- a/tests/hwsim/test_ap_csa.py
+++ b/tests/hwsim/test_ap_csa.py
@@ -27,7 +27,7 @@  def switch_channel(ap, count, freq):
         raise Exception("CSA finished event timed out")
     if "freq=" + str(freq) not in ev:
         raise Exception("Unexpected channel in CSA finished event")
-    time.sleep(1)
+    time.sleep(3)
 
 # This function checks whether the provided dev, which may be either
 # WpaSupplicant or Hostapd supports CSA.
diff --git a/tests/hwsim/test_ap_qosmap.py b/tests/hwsim/test_ap_qosmap.py
index 0030d94..48348bf 100644
--- a/tests/hwsim/test_ap_qosmap.py
+++ b/tests/hwsim/test_ap_qosmap.py
@@ -21,7 +21,7 @@  def check_qos_map(ap, hapd, dev, sta, dscp, tid, ap_tid=None):
     wt = Wlantest()
     wt.clear_sta_counters(bssid, sta)
     hwsim_utils.test_connectivity(dev, hapd, dscp=dscp, config=False)
-    time.sleep(0.02)
+    time.sleep(0.2)
     tx = wt.get_tx_tid(bssid, sta, tid)
     if tx == 0:
         [ tx, rx ] = wt.get_tid_counters(bssid, sta)
diff --git a/tests/hwsim/wpasupplicant.py b/tests/hwsim/wpasupplicant.py
index 0c8a76a..480346a 100644
--- a/tests/hwsim/wpasupplicant.py
+++ b/tests/hwsim/wpasupplicant.py
@@ -813,7 +813,7 @@  class WpaSupplicant:
             except:
                 pass
             self.gctrl_mon = None
-        ev = self.wait_global_event(["P2P-GROUP-REMOVED"], timeout=3)
+        ev = self.wait_global_event(["P2P-GROUP-REMOVED"], timeout=10)
         if ev is None:
             raise Exception("Group removal event timed out")
         if "reason=GO_ENDING_SESSION" not in ev: