2 # Copyright (c) 2014, Jouni Malinen <j@w1.fi>
4 # This software may be distributed under the terms of the BSD license.
5 # See README for more details.
12 def test_module_wpa_supplicant(dev, apdev, params):
13 """wpa_supplicant module tests"""
14 if "OK" not in dev[0].global_request("MODULE_TESTS"):
15 raise Exception("Module tests failed")
16 # allow eloop test to complete
19 with open(os.path.join(params['logdir'], 'log0'), 'r') as f:
21 if "FAIL - should not have called this function" in res:
22 raise Exception("eloop test failed")
24 def test_module_hostapd(dev):
25 """hostapd module tests"""
26 hapd_global = hostapd.HostapdGlobal()
27 if "OK" not in hapd_global.ctrl.request("MODULE_TESTS"):
28 raise Exception("Module tests failed")