HEAP_DEFINE(iheap, int, int_lt);
/** @brief Tests for @ref heap.h */
-void test_heap(void) {
+static void test_heap(void) {
struct iheap h[1];
int n;
int last = -1;
- fprintf(stderr, "test_heap\n");
-
iheap_init(h);
for(n = 0; n < 1000; ++n)
iheap_insert(h, random() % 100);
insist(last <= latest);
last = latest;
}
- putchar('\n');
}
+TEST(heap);
+
/*
Local Variables:
c-basic-offset:2