From e4d7b5134eca79d9860bacafd387a2888422c425 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Fri, 28 Nov 2014 16:16:24 +0200 Subject: [PATCH] tests: Move hessid and access_network_type reset to test case This removes unnecessary reset() steps from between every test case. Signed-off-by: Jouni Malinen --- tests/hwsim/test_ap_hs20.py | 7 +++++++ tests/hwsim/wpasupplicant.py | 2 -- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/tests/hwsim/test_ap_hs20.py b/tests/hwsim/test_ap_hs20.py index 5e02f160d..7a44be330 100644 --- a/tests/hwsim/test_ap_hs20.py +++ b/tests/hwsim/test_ap_hs20.py @@ -241,6 +241,13 @@ def test_ap_nai_home_realm_query(dev, apdev): def test_ap_interworking_scan_filtering(dev, apdev): """Interworking scan filtering with HESSID and access network type""" + try: + return _test_ap_interworking_scan_filtering(dev, apdev) + finally: + dev[0].request("SET hessid 00:00:00:00:00:00") + dev[0].request("SET access_network_type 15") + +def _test_ap_interworking_scan_filtering(dev, apdev): bssid = apdev[0]['bssid'] params = hs20_ap_params() ssid = "test-hs20-ap1" diff --git a/tests/hwsim/wpasupplicant.py b/tests/hwsim/wpasupplicant.py index 1ef5ea470..5a782c942 100644 --- a/tests/hwsim/wpasupplicant.py +++ b/tests/hwsim/wpasupplicant.py @@ -93,8 +93,6 @@ class WpaSupplicant: logger.info("FLUSH to " + self.ifname + " failed: " + res) self.request("WPS_ER_STOP") self.request("SET pmf 0") - self.request("SET hessid 00:00:00:00:00:00") - self.request("SET access_network_type 15") self.request("SET p2p_add_cli_chan 0") self.request("SET p2p_no_go_freq ") self.request("SET p2p_pref_chan ")