From 6b4300d0c63a17809a8e8e4025921699c608a075 Mon Sep 17 00:00:00 2001 From: Jonathan Afek Date: Tue, 7 Jun 2016 16:42:41 +0300 Subject: [PATCH] tests: Use apdev[0] more consistently in ap_ht The test cases ap_ht40_5ghz_invalid_pair and ap_ht40_5ghz_disabled_sec mixed use of apdev[0] and apdev[1] while only needing a single AP. This works when both the devices are on the same host (e.g., with mac80211_hwsim), but not when using separate remote hosts. Fix this by using apdev[0] more consistently in these test cases. Signed-off-by: Jonathan Afek --- tests/hwsim/test_ap_ht.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/hwsim/test_ap_ht.py b/tests/hwsim/test_ap_ht.py index 804e56d04..6048d8a37 100644 --- a/tests/hwsim/test_ap_ht.py +++ b/tests/hwsim/test_ap_ht.py @@ -1122,7 +1122,7 @@ def test_ap_ht40_5ghz_invalid_pair(dev, apdev): "channel": "40", "country_code": "US", "ht_capab": "[HT40+]"} - hapd = hostapd.add_ap(apdev[1], params, wait_enabled=False) + hapd = hostapd.add_ap(apdev[0], params, wait_enabled=False) ev = hapd.wait_event(["AP-DISABLED", "AP-ENABLED"], timeout=10) if not ev: raise Exception("AP setup failure timed out") @@ -1142,7 +1142,7 @@ def test_ap_ht40_5ghz_disabled_sec(dev, apdev): "channel": "48", "country_code": "US", "ht_capab": "[HT40+]"} - hapd = hostapd.add_ap(apdev[1], params, wait_enabled=False) + hapd = hostapd.add_ap(apdev[0], params, wait_enabled=False) ev = hapd.wait_event(["AP-DISABLED", "AP-ENABLED"], timeout=10) if not ev: raise Exception("AP setup failure timed out")