tests: hostapd error path on driver interface initialization failure
Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
015f6a5a0c
commit
1282787878
1 changed files with 16 additions and 0 deletions
16
tests/hwsim/test_hostapd_error.py
Normal file
16
tests/hwsim/test_hostapd_error.py
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
# hostapd error paths
|
||||||
|
# Copyright (c) 2024, Jouni Malinen <j@w1.fi>
|
||||||
|
#
|
||||||
|
# This software may be distributed under the terms of the BSD license.
|
||||||
|
# See README for more details.
|
||||||
|
|
||||||
|
import hostapd
|
||||||
|
from utils import *
|
||||||
|
|
||||||
|
def test_hostapd_error_drv_init(dev, apdev):
|
||||||
|
"""hostapd error path on driver interface initialization failure"""
|
||||||
|
hapd = hostapd.add_ap(apdev[0], {"ssid": "ctrl"})
|
||||||
|
with fail_test(hapd, 1, "nl80211_setup_ap"):
|
||||||
|
hapd1 = hostapd.add_ap(apdev[1], {"ssid": "open"}, no_enable=True)
|
||||||
|
if "FAIL" not in hapd1.request("ENABLE"):
|
||||||
|
raise Exception("ENABLE succeeded unexpectedly")
|
Loading…
Reference in a new issue