3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-12-22 04:32:37 +01:00

auto-t: add test for scanning in AP mode

This commit is contained in:
James Prestwood 2022-11-04 09:37:57 -07:00 committed by Denis Kenzior
parent 9ef440eb8e
commit 809067c924

View File

@ -0,0 +1,20 @@
#! /usr/bin/python3
import unittest
from iwd import IWD
class Test(unittest.TestCase):
def test_ap_scan(self):
wd = IWD(True)
dev = wd.list_devices(1)[0]
dev.start_ap('TestAP2', 'Password2')
dev.scan()
networks = dev.get_ordered_networks()
self.assertTrue(len(networks) == 1)
self.assertTrue(networks[0]['Name'] == 'TestAP1')