diff --git a/autotests/testAP/failure_test.py b/autotests/testAP/failure_test.py index 2c1e14b3..9944abaa 100644 --- a/autotests/testAP/failure_test.py +++ b/autotests/testAP/failure_test.py @@ -14,17 +14,8 @@ import testutil class Test(unittest.TestCase): def client_connect(self, wd, dev): - condition = 'not obj.scanning' - wd.wait_for_object_condition(dev, condition) - if not dev.get_ordered_networks(): - dev.scan() - condition = 'obj.scanning' - wd.wait_for_object_condition(dev, condition) - condition = 'not obj.scanning' - wd.wait_for_object_condition(dev, condition) - - ordered_network = dev.get_ordered_network('TestAP1') + ordered_network = dev.get_ordered_network('TestAP1', True) self.assertEqual(ordered_network.type, NetworkType.psk) diff --git a/autotests/testAP/test.py b/autotests/testAP/test.py index 455c9916..4cacf9ad 100644 --- a/autotests/testAP/test.py +++ b/autotests/testAP/test.py @@ -14,17 +14,8 @@ import testutil class Test(unittest.TestCase): def client_connect(self, wd, dev): - condition = 'not obj.scanning' - wd.wait_for_object_condition(dev, condition) - if not dev.get_ordered_networks(): - dev.scan() - condition = 'obj.scanning' - wd.wait_for_object_condition(dev, condition) - condition = 'not obj.scanning' - wd.wait_for_object_condition(dev, condition) - - ordered_network = dev.get_ordered_network('TestAP1') + ordered_network = dev.get_ordered_network('TestAP1', True) self.assertEqual(ordered_network.type, NetworkType.psk)