mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-11-16 17:09:24 +01:00
auto-t: a few random autotest fixes
testEncryptedProfiles: - This would occationally fail because the test is expecting to explicitly connect but after the first failed connection autoconnect takes over and its a race to connect. testPSK-roam: - Several rules were not being cleaned up which could cause tests afterwards to fail - The AP roam test started failing randomly because of the SNR ranking changes. It appears that with hwsim _sometimes_ the SNR is able to be determined which can effect the ranking. This test assumed the two BSS's would be the same ranking but the SNR sometimes causes this to not be true.
This commit is contained in:
parent
b7da34a5d2
commit
06c8080664
@ -1,2 +1,5 @@
|
|||||||
[Security]
|
[Security]
|
||||||
Passphrase=secret123
|
Passphrase=secret123
|
||||||
|
|
||||||
|
[General]
|
||||||
|
AutoConnect=false
|
||||||
|
@ -247,6 +247,9 @@ class Test(unittest.TestCase):
|
|||||||
cls.rule2.remove()
|
cls.rule2.remove()
|
||||||
cls.rule3.remove()
|
cls.rule3.remove()
|
||||||
cls.assoc_rule.remove()
|
cls.assoc_rule.remove()
|
||||||
|
cls.rule_bss0.remove()
|
||||||
|
cls.rule_bss1.remove()
|
||||||
|
cls.rule_bss2.remove()
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
unittest.main(exit=True)
|
unittest.main(exit=True)
|
||||||
|
@ -81,12 +81,21 @@ class Test(unittest.TestCase):
|
|||||||
cls.bss_hostapd[0].set_value('ocv', '0')
|
cls.bss_hostapd[0].set_value('ocv', '0')
|
||||||
cls.bss_hostapd[0].set_value('ieee80211w', '0')
|
cls.bss_hostapd[0].set_value('ieee80211w', '0')
|
||||||
|
|
||||||
|
rad0 = hwsim.get_radio('rad0')
|
||||||
|
rad1 = hwsim.get_radio('rad1')
|
||||||
|
|
||||||
cls.rule0 = hwsim.rules.create()
|
cls.rule0 = hwsim.rules.create()
|
||||||
cls.rule0.source = 'any'
|
cls.rule0.source = rad0.addresses[0]
|
||||||
cls.rule0.bidirectional = True
|
cls.rule0.bidirectional = True
|
||||||
cls.rule0.signal = -8000
|
cls.rule0.signal = -8000
|
||||||
cls.rule0.enabled = True
|
cls.rule0.enabled = True
|
||||||
|
|
||||||
|
cls.rule1 = hwsim.rules.create()
|
||||||
|
cls.rule1.source = rad1.addresses[0]
|
||||||
|
cls.rule1.bidirectional = True
|
||||||
|
cls.rule1.signal = -8500
|
||||||
|
cls.rule1.enabled = True
|
||||||
|
|
||||||
cls.bss_hostapd[0].set_address('12:00:00:00:00:01')
|
cls.bss_hostapd[0].set_address('12:00:00:00:00:01')
|
||||||
cls.bss_hostapd[1].set_address('12:00:00:00:00:02')
|
cls.bss_hostapd[1].set_address('12:00:00:00:00:02')
|
||||||
|
|
||||||
@ -95,6 +104,7 @@ class Test(unittest.TestCase):
|
|||||||
IWD.clear_storage()
|
IWD.clear_storage()
|
||||||
cls.bss_hostapd = None
|
cls.bss_hostapd = None
|
||||||
cls.rule0.remove()
|
cls.rule0.remove()
|
||||||
|
cls.rule1.remove()
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
unittest.main(exit=True)
|
unittest.main(exit=True)
|
||||||
|
Loading…
Reference in New Issue
Block a user