commit 85259bb51906530f31a78b29c9bb2bf43e63e5ab
parent edac41b1b30f92d142865afa5d92516506624f36
Author: James Prestwood <prestwoj@gmail.com>
Date: Thu, 10 Sep 2020 16:12:25 -0700
auto-t: testutil.py: update to work with test-runner rewrite
Similar to the others, testutil.py was converted to use the global
test context to lookup radios/interfaces rather than the wiphy_map
Diffstat:
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/autotests/util/testutil.py b/autotests/util/testutil.py
@@ -5,8 +5,8 @@ import fcntl
import struct
import select
-import wiphy
import iwd
+from config import ctx
HWSIM_ETHERTYPE = 0x0800
HWSIM_PACKETLEN = 250
@@ -54,8 +54,9 @@ def tx(fromsock, tosock, src, dst):
def test_connected(if0=None, if1=None, group=True):
if if0 is None or if1 is None:
iwd_list = [dev.name for dev in iwd.IWD.get_instance().list_devices()]
- non_iwd_list = [ifname for w in wiphy.wiphy_map.values()
- for ifname in w.interface_map]
+
+ non_iwd_list = [rad.interface.name for rad in ctx.radios if rad.interface is not None]
+
for intf in iwd_list + non_iwd_list:
if if0 is None:
if0 = intf