From a0559aa5babbd137c25cfa1b333d1115daee6a65 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Fri, 28 Nov 2014 16:00:24 +0200 Subject: [PATCH] tests: Make go_neg_forced_freq_diff_than_bss_freq more robust It was possible for this test case to fail due to PBC overlap that was detected based on previous test case having used PBC. Make that false positive less likely to happen by explicitly clearing the scan cache on the device. Signed-off-by: Jouni Malinen --- tests/hwsim/test_p2p_channel.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/hwsim/test_p2p_channel.py b/tests/hwsim/test_p2p_channel.py index c8c1d6327..3e2f275b5 100644 --- a/tests/hwsim/test_p2p_channel.py +++ b/tests/hwsim/test_p2p_channel.py @@ -337,6 +337,10 @@ def test_go_neg_forced_freq_diff_than_bss_freq(dev, apdev): if wpas.get_mcc() < 2: raise Exception("New radio does not support MCC") + # Clear possible PBC session overlap from previous test case + dev[1].request("BSS_FLUSH 0") + dev[1].request("SCAN freq=2412 only_new=1") + wpas.request("SET p2p_no_group_iface 0") hapd = hostapd.add_ap(apdev[0]['ifname'],