579 for (int i = 0; i < 5; i++) cxListAdd(expected, &data[i]); |
579 for (int i = 0; i < 5; i++) cxListAdd(expected, &data[i]); |
580 |
580 |
581 CxList list = cxLinkedListFromArray(cxTestingAllocator, (CxListComparator) cmp_int, sizeof(int), 5, data); |
581 CxList list = cxLinkedListFromArray(cxTestingAllocator, (CxListComparator) cmp_int, sizeof(int), 5, data); |
582 |
582 |
583 CU_ASSERT_TRUE(0 == cxListCompare(list, expected)) |
583 CU_ASSERT_TRUE(0 == cxListCompare(list, expected)) |
|
584 |
|
585 cxLinkedListDestroy(list); |
|
586 cxLinkedListDestroy(expected); |
|
587 CU_ASSERT_TRUE(cxTestingAllocatorVerify()) |
584 } |
588 } |
585 |
589 |
586 void test_hl_linked_list_add(void) { |
590 void test_hl_linked_list_add(void) { |
587 cxTestingAllocatorReset(); |
591 cxTestingAllocatorReset(); |
588 |
592 |