Merge pull request #11895 from AriParkkila/cell-ignore-linklocal

TESTS: Allow ipv6_link_local_address() as unsupported
pull/11915/head
Martin Kojtal 2019-11-21 09:19:59 +01:00 committed by GitHub
commit e638486be1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 4 deletions

View File

@ -158,11 +158,13 @@ void NETWORKINTERFACE_STATUS_GET()
#if MBED_CONF_LWIP_IPV6_ENABLED
/* if IPv6 is enabled, validate ipv6_link_local_address API*/
SocketAddress ipv6_link_local_address = NULL;
SocketAddress ipv6_link_local_address(NULL);
err = net->get_ipv6_link_local_address(&ipv6_link_local_address);
TEST_ASSERT_EQUAL(NSAPI_ERROR_OK, err);
TEST_ASSERT_NOT_NULL(ipv6_link_local_address.get_ip_address());
TEST_ASSERT_EQUAL(NSAPI_IPv6, ipv6_link_local_address.get_ip_version());
if (err != NSAPI_ERROR_UNSUPPORTED) {
TEST_ASSERT_EQUAL(NSAPI_ERROR_OK, err);
TEST_ASSERT_NOT_NULL(ipv6_link_local_address.get_ip_address());
TEST_ASSERT_EQUAL(NSAPI_IPv6, ipv6_link_local_address.get_ip_version());
}
#endif
err = net->disconnect();