fix: reject mixed 2.4GHz and radio1 AP requests with clear error

This commit is contained in:
2026-08-18 07:23:25 -05:00
parent cd39833f4b
commit 4fa7f8f855
2 changed files with 17 additions and 2 deletions
+9
View File
@@ -249,6 +249,15 @@ class SetApRadio1Test(unittest.TestCase):
self.assertEqual(self.uci['pineapd.wlan1mon.hop'], '1')
self.assertEqual(self.uci.get('wireless.radio1.channel'), 'auto')
def test_mixed_24g_and_radio1_rejected(self):
status, payload = server.h_pineap_wifi_set_ap(ctx({
'open': {'ssid': 'CorpGuest', 'hidden': False, 'enabled': True,
'channel': 36, 'country': 'US'},
'wpa': {'ssid': 'Office', 'passphrase': 'secret123', 'enctype': 'psk2',
'hidden': False, 'enabled': True, 'channel': 6}}))
self.assertEqual(status, 400)
self.assertIn('2.4GHz', payload['error'])
class GetApRadioChannelFallbackTest(unittest.TestCase):
"""Regression: iface without a channel option inherits the radio channel."""