diff --git a/components/esp_netif/test/test_esp_netif.c b/components/esp_netif/test/test_esp_netif.c index 423c8941dc..1c2aa80a9f 100644 --- a/components/esp_netif/test/test_esp_netif.c +++ b/components/esp_netif/test/test_esp_netif.c @@ -38,6 +38,8 @@ TEST_CASE("esp_netif: get from if_key", "[esp_netif][leaks=0]") } +// This is a private esp-netif API, but include here to test it +bool esp_netif_is_netif_listed(esp_netif_t *esp_netif); TEST_CASE("esp_netif: create and delete multiple netifs", "[esp_netif][leaks=0]") { @@ -54,12 +56,19 @@ TEST_CASE("esp_netif: create and delete multiple netifs", "[esp_netif][leaks=0]" TEST_ASSERT_NOT_NULL(netifs[i]); } - // there's no AP within created stations - TEST_ASSERT_EQUAL(NULL, esp_netif_get_handle_from_ifkey("WIFI_AP_DEF")); + // there's no AP within created netifs + TEST_ASSERT_NULL(esp_netif_get_handle_from_ifkey("WIFI_AP_DEF")); - // destroy + // check that the created netifs are correctly found by their interface keys and globally listed + for (int i=0; i