Updating tests

This commit is contained in:
Leonardo committed 2020-03-29 17:44:33 -03:00
1 parent 2c732dbadf
commit 0d665c46d0
10 files changed
+75 -5

No files matched your search

+6
View File
@@ -597,5 +597,11 @@ CMC_CREATE_UNIT(bidimap_test, true, {
cmc_assert_equals(ptr, NULL, map->callbacks);
bm_free(map);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+6
View File
@@ -811,5 +811,11 @@ CMC_CREATE_UNIT(deque_test, true, {
cmc_assert_equals(ptr, NULL, d->callbacks);
d_free(d);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+7 -5
View File
@@ -607,11 +607,7 @@ CMC_CREATE_UNIT(hashmap_test, true, {
struct hashmap *map =
hm_new_custom(100, 0.6, hm_ftab_key, hm_ftab_val, NULL, callbacks);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
cmc_assert_not_equals(ptr, NULL, map);
cmc_assert(hm_insert(map, 1, 2));
cmc_assert_equals(int32_t, 1, total_create);
@@ -678,5 +674,11 @@ CMC_CREATE_UNIT(hashmap_test, true, {
cmc_assert_equals(ptr, NULL, map->callbacks);
hm_free(map);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+8
View File
@@ -486,6 +486,8 @@ CMC_CREATE_UNIT(hashset_test, true, {
struct hashset *set =
hs_new_custom(100, 0.6, hs_ftab_val, NULL, callbacks);
cmc_assert_not_equals(ptr, NULL, set);
total_create = 0;
total_read = 0;
total_update = 0;
@@ -545,5 +547,11 @@ CMC_CREATE_UNIT(hashset_test, true, {
cmc_assert_equals(ptr, NULL, set->callbacks);
hs_free(set);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+8
View File
@@ -228,6 +228,8 @@ CMC_CREATE_UNIT(heap_test, true, {
struct heap *h =
h_new_custom(100, cmc_max_heap, h_ftab_val, NULL, callbacks);
cmc_assert_not_equals(ptr, NULL, h);
total_create = 0;
total_read = 0;
total_update = 0;
@@ -283,5 +285,11 @@ CMC_CREATE_UNIT(heap_test, true, {
cmc_assert_equals(ptr, NULL, h->callbacks);
h_free(h);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+8
View File
@@ -265,6 +265,8 @@ CMC_CREATE_UNIT(intervalheap_test, true, {
struct intervalheap *ih =
ih_new_custom(100, ih_ftab_val, NULL, callbacks);
cmc_assert_not_equals(ptr, NULL, ih);
total_create = 0;
total_read = 0;
total_update = 0;
@@ -342,5 +344,11 @@ CMC_CREATE_UNIT(intervalheap_test, true, {
cmc_assert_equals(ptr, NULL, ih->callbacks);
ih_free(ih);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+8
View File
@@ -260,6 +260,8 @@ CMC_CREATE_UNIT(linkedlist_test, true, {
CMC_CREATE_TEST(callbacks, {
struct linkedlist *ll = ll_new_custom(ll_ftab_val, NULL, callbacks);
cmc_assert_not_equals(ptr, NULL, ll);
total_create = 0;
total_read = 0;
total_update = 0;
@@ -335,5 +337,11 @@ CMC_CREATE_UNIT(linkedlist_test, true, {
cmc_assert_equals(ptr, NULL, ll->callbacks);
ll_free(ll);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+8
View File
@@ -500,6 +500,8 @@ CMC_CREATE_UNIT(list_test, true, {
CMC_CREATE_TEST(callbacks, {
struct list *l = l_new_custom(100, l_ftab_val, NULL, callbacks);
cmc_assert_not_equals(ptr, NULL, l);
total_create = 0;
total_read = 0;
total_update = 0;
@@ -605,5 +607,11 @@ CMC_CREATE_UNIT(list_test, true, {
l_free(l);
l_free(l2);
l_free(l3);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
})
+8
View File
@@ -277,6 +277,8 @@ CMC_CREATE_UNIT(multimap_test, true, {
struct multimap *map =
mm_new_custom(100, 0.8, mm_ftab_key, mm_ftab_val, NULL, callbacks);
cmc_assert_not_equals(ptr, NULL, map);
total_create = 0;
total_read = 0;
total_update = 0;
@@ -364,5 +366,11 @@ CMC_CREATE_UNIT(multimap_test, true, {
cmc_assert_equals(ptr, NULL, map->callbacks);
mm_free(map);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});
+8
View File
@@ -267,6 +267,8 @@ CMC_CREATE_UNIT(multiset_test, true, {
struct multiset *set =
ms_new_custom(100, 0.8, ms_ftab_val, NULL, callbacks);
cmc_assert_not_equals(ptr, NULL, set);
total_create = 0;
total_read = 0;
total_update = 0;
@@ -342,5 +344,11 @@ CMC_CREATE_UNIT(multiset_test, true, {
cmc_assert_equals(ptr, NULL, set->callbacks);
ms_free(set);
total_create = 0;
total_read = 0;
total_update = 0;
total_delete = 0;
total_resize = 0;
});
});