Skip to content

Commit 15879f5

Browse files
author
Cruz Monrreal
authored
Merge pull request #8241 from SeppoTakalo/fix_wifi_connect_params_fail
Fix WIFI_CONNECT_PARAMS_CHANNEL_FAIL testcase.
2 parents 8aa65fa + e7924a9 commit 15879f5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

TESTS/network/wifi/wifi_connect_params_channel_fail.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ void wifi_connect_params_channel_fail(void)
3434
return;
3535
}
3636

37-
nsapi_error_t error = wifi->connect(MBED_CONF_APP_WIFI_SECURE_SSID, MBED_CONF_APP_WIFI_PASSWORD, get_security(), MBED_CONF_APP_WIFI_CH_UNSECURE);
37+
uint8_t wrong_channel = 1 + (MBED_CONF_APP_WIFI_CH_SECURE%10);
38+
nsapi_error_t error = wifi->connect(MBED_CONF_APP_WIFI_SECURE_SSID, MBED_CONF_APP_WIFI_PASSWORD, get_security(), wrong_channel);
3839
TEST_ASSERT(error == NSAPI_ERROR_CONNECTION_TIMEOUT || error == NSAPI_ERROR_NO_CONNECTION);
3940

4041
wifi->set_channel(0);

0 commit comments

Comments
 (0)