1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-18 12:52:44 +01:00

tests/lwip_sock_ip: fix NDEBUG compile problem

This commit is contained in:
Gunar Schorcht 2020-02-25 09:28:59 +01:00
parent 8af912b002
commit 831e2de56c
2 changed files with 285 additions and 283 deletions

File diff suppressed because it is too large Load Diff

View File

@ -23,6 +23,7 @@
#include "net/netdev_test.h"
#include "net/sock.h"
#include "sched.h"
#include "test_utils/expect.h"
#include "xtimer.h"
#include "lwip.h"
@ -74,7 +75,7 @@ static int _get_addr(netdev_t *dev, void *value, size_t max_len)
static const uint8_t _local_ip[] = _TEST_ADDR6_LOCAL;
(void)dev;
assert(max_len >= ETHERNET_ADDR_LEN);
expect(max_len >= ETHERNET_ADDR_LEN);
return l2util_ipv6_iid_to_addr(NETDEV_TYPE_ETHERNET,
(eui64_t *)&_local_ip[8],
value);
@ -154,7 +155,7 @@ void _net_init(void)
netdev_test_set_recv_cb(&netdev, _netdev_recv);
netdev_test_set_isr_cb(&netdev, _netdev_isr);
/* netdev needs to be set-up */
assert(netdev.netdev.driver);
expect(netdev.netdev.driver);
#if LWIP_IPV4
ip4_addr_t local4, mask4, gw4;
local4.addr = _TEST_ADDR4_LOCAL;
@ -198,7 +199,7 @@ void _prepare_send_checks(void)
netdev_test_set_send_cb(&netdev, _netdev_send);
#if LWIP_ARP
const ip4_addr_t remote4 = { .addr = _TEST_ADDR4_REMOTE };
assert(ERR_OK == etharp_add_static_entry(&remote4, (struct eth_addr *)mac));
expect(ERR_OK == etharp_add_static_entry(&remote4, (struct eth_addr *)mac));
#endif
#if LWIP_IPV6
memset(destination_cache, 0,