]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Concurrent station mode scan and p2p_find with P2P Device
authorJouni Malinen <jouni@qca.qualcomm.com>
Thu, 30 Oct 2014 22:48:12 +0000 (00:48 +0200)
committerJouni Malinen <j@w1.fi>
Thu, 30 Oct 2014 22:50:01 +0000 (00:50 +0200)
This verifies that station mode interface SCAN command gets executed if
P2P Device instance is running p2p_find.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
tests/hwsim/test_p2p_device.py

index a3428f2b19f21f82f1c54797ce9c7c86ae3c3595..e0cfa614bc6aa451cc7fa8488ad04de1ae33b4de 100644 (file)
@@ -52,3 +52,15 @@ def test_p2p_device_group_remove(dev, apdev):
             raise Exception("Group removal event not received")
         if not wpas.global_ping():
             raise Exception("Could not ping global ctrl_iface after group removal")
+
+def test_p2p_device_concurrent_scan(dev, apdev):
+    """Concurrent P2P and station mode scans with driver using cfg80211 P2P Device"""
+    with HWSimRadio(use_p2p_device=True) as (radio, iface):
+        wpas = WpaSupplicant(global_iface='/tmp/wpas-wlan5')
+        wpas.interface_add(iface)
+        wpas.p2p_find()
+        time.sleep(0.1)
+        wpas.request("SCAN")
+        ev = wpas.wait_event(["CTRL-EVENT-SCAN-STARTED"], timeout=15)
+        if ev is None:
+            raise Exception("Station mode scan did not start")