From: Jouni Malinen Date: Thu, 27 Nov 2014 19:44:01 +0000 (+0200) Subject: tests: Make p2p_messages tests more robust under load X-Git-Tag: hostap_2_4~1004 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=54fe526ac462f00df1248729da464e363f2c2218;p=thirdparty%2Fhostap.git tests: Make p2p_messages tests more robust under load The 50 ms wait time for Action frame response was not sufficient when the tests are run under heavy load (e.g., multiple VMs in parallel). Signed-off-by: Jouni Malinen --- diff --git a/tests/hwsim/test_p2p_messages.py b/tests/hwsim/test_p2p_messages.py index dc56b7c19..a0a22c9b5 100644 --- a/tests/hwsim/test_p2p_messages.py +++ b/tests/hwsim/test_p2p_messages.py @@ -751,7 +751,7 @@ def test_p2p_msg_invitation_req_to_go(dev, apdev): attrs += p2p_attr_device_info(addr1, config_methods=0x0108) msg['payload'] += ie_p2p(attrs) - mgmt_tx(dev[1], "MGMT_TX {} {} freq={} wait_time=50 no_cck=1 action={}".format(addr0, addr0, peer['listen_freq'], binascii.hexlify(msg['payload']))) + mgmt_tx(dev[1], "MGMT_TX {} {} freq={} wait_time=200 no_cck=1 action={}".format(addr0, addr0, peer['listen_freq'], binascii.hexlify(msg['payload']))) rx_msg = dev[1].mgmt_rx() if rx_msg is None: @@ -777,7 +777,7 @@ def test_p2p_msg_invitation_req_to_go(dev, apdev): attrs += p2p_attr_device_info(addr1, config_methods=0x0108) msg['payload'] += ie_p2p(attrs) - mgmt_tx(dev[1], "MGMT_TX {} {} freq={} wait_time=50 no_cck=1 action={}".format(addr0, addr0, peer['listen_freq'], binascii.hexlify(msg['payload']))) + mgmt_tx(dev[1], "MGMT_TX {} {} freq={} wait_time=200 no_cck=1 action={}".format(addr0, addr0, peer['listen_freq'], binascii.hexlify(msg['payload']))) rx_msg = dev[1].mgmt_rx() if rx_msg is None: @@ -856,8 +856,8 @@ def test_p2p_msg_invitation_resp(dev, apdev): msg = p2p_hdr(dst, src, type=P2P_INVITATION_RESP, dialog_token=2) attrs = p2p_attr_status() msg['payload'] += ie_p2p(attrs) - mgmt_tx(dev[1], "MGMT_TX {} {} freq={} wait_time=50 no_cck=1 action={}".format(addr0, addr0, peer['listen_freq'], binascii.hexlify(msg['payload']))) - time.sleep(0.1) + mgmt_tx(dev[1], "MGMT_TX {} {} freq={} wait_time=200 no_cck=1 action={}".format(addr0, addr0, peer['listen_freq'], binascii.hexlify(msg['payload']))) + time.sleep(0.25) if "FAIL" in dev[1].request("SET ext_mgmt_frame_handling 1"): raise Exception("Failed to enable external management frame handling") @@ -876,7 +876,7 @@ def test_p2p_msg_invitation_resp(dev, apdev): msg = p2p_hdr(dst, src, type=P2P_INVITATION_RESP, dialog_token=p2p['dialog_token']) attrs = struct.pack("