tests: Avoid race condition in WPS ER tests
Wait for hostapd to complete STA authorization before running the connectivity test between two associated STAs. Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
da8a38fecb
commit
fc995d3130
1 changed files with 2 additions and 0 deletions
|
@ -1234,6 +1234,7 @@ def _test_ap_wps_er_add_enrollee(dev, apdev):
|
||||||
if ev is None:
|
if ev is None:
|
||||||
raise Exception("WPS ER did not report success")
|
raise Exception("WPS ER did not report success")
|
||||||
hapd.wait_sta(dev[1].own_addr())
|
hapd.wait_sta(dev[1].own_addr())
|
||||||
|
hapd.wait_4way_hs()
|
||||||
hwsim_utils.test_connectivity_sta(dev[0], dev[1])
|
hwsim_utils.test_connectivity_sta(dev[0], dev[1])
|
||||||
|
|
||||||
logger.info("Add a specific Enrollee using ER")
|
logger.info("Add a specific Enrollee using ER")
|
||||||
|
@ -1517,6 +1518,7 @@ def _test_ap_wps_er_add_enrollee_pbc(dev, apdev):
|
||||||
if ev is None:
|
if ev is None:
|
||||||
raise Exception("WPS ER did not report success")
|
raise Exception("WPS ER did not report success")
|
||||||
hapd.wait_sta(addr=dev[1].own_addr())
|
hapd.wait_sta(addr=dev[1].own_addr())
|
||||||
|
hapd.wait_4way_hs()
|
||||||
hwsim_utils.test_connectivity_sta(dev[0], dev[1])
|
hwsim_utils.test_connectivity_sta(dev[0], dev[1])
|
||||||
|
|
||||||
def test_ap_wps_er_pbc_overlap(dev, apdev):
|
def test_ap_wps_er_pbc_overlap(dev, apdev):
|
||||||
|
|
Loading…
Reference in a new issue