6 #if !LWIP_STATS || !MEM_STATS
7 #error "This tests needs MEM-statistics enabled"
39 fail(
"This test needs DNS turned off (as it mallocs on init)");
42 fail_unless(lwip_stats.mem.used == 0);
45 fail_unless(p1 !=
NULL);
46 fail_unless(lwip_stats.mem.used >=
SIZE1);
47 s1 = lwip_stats.mem.used;
50 fail_unless(p2 !=
NULL);
51 fail_unless(lwip_stats.mem.used >=
SIZE2 + s1);
52 s2 = lwip_stats.mem.used;
57 fail_unless(lwip_stats.mem.used <= s2 -
SIZE2);
60 fail_unless(lwip_stats.mem.used == 0);
72 return create_suite(
"MEM", tests,
sizeof(tests)/
sizeof(TFun), mem_setup, mem_teardown);