Lines Matching refs:CHECK
59 if (CHECK(err != -ENOENT, "hashmap__update", in test_hashmap_generic()
67 if (CHECK(oldk != NULL || oldv != NULL, "check_kv", in test_hashmap_generic()
72 if (CHECK(err, "elem_add", "failed to add k/v %ld = %ld: %d\n", in test_hashmap_generic()
76 if (CHECK(!hashmap__find(map, k, &oldv), "elem_find", in test_hashmap_generic()
79 if (CHECK(oldv != v, "elem_val", in test_hashmap_generic()
84 if (CHECK(hashmap__size(map) != ELEM_CNT, "hashmap__size", in test_hashmap_generic()
87 if (CHECK(hashmap__capacity(map) != exp_cap(hashmap__size(map)), in test_hashmap_generic()
98 if (CHECK(v - k != 1024, "check_kv", in test_hashmap_generic()
102 if (CHECK(found_msk != (1ULL << ELEM_CNT) - 1, "elem_cnt", in test_hashmap_generic()
111 if (CHECK(err != -EEXIST, "hashmap__add", in test_hashmap_generic()
120 if (CHECK(err, "elem_upd", in test_hashmap_generic()
124 if (CHECK(!hashmap__find(map, k, &oldv), "elem_find", in test_hashmap_generic()
127 if (CHECK(oldv != v, "elem_val", in test_hashmap_generic()
132 if (CHECK(hashmap__size(map) != ELEM_CNT, "hashmap__size", in test_hashmap_generic()
135 if (CHECK(hashmap__capacity(map) != exp_cap(hashmap__size(map)), in test_hashmap_generic()
146 if (CHECK(v - k != 256, "elem_check", in test_hashmap_generic()
150 if (CHECK(found_msk != (1ULL << ELEM_CNT) - 1, "elem_cnt", in test_hashmap_generic()
158 if (CHECK(!found_cnt, "found_cnt", in test_hashmap_generic()
174 if (CHECK(!hashmap__delete(map, k, &oldk, &oldv), "elem_del", in test_hashmap_generic()
178 if (CHECK(oldk != k || oldv != v, "check_old", in test_hashmap_generic()
182 if (CHECK(hashmap__delete(map, k, &oldk, &oldv), "elem_del", in test_hashmap_generic()
188 if (CHECK(!found_cnt || !found_msk, "found_entries", in test_hashmap_generic()
191 if (CHECK(hashmap__size(map) != ELEM_CNT - found_cnt, "elem_cnt", in test_hashmap_generic()
195 if (CHECK(hashmap__capacity(map) != exp_cap(hashmap__size(map)), in test_hashmap_generic()
210 if (CHECK(!hashmap__delete(map, k, &oldk, &oldv), "elem_del", in test_hashmap_generic()
214 if (CHECK(oldk != k || oldv != v, "elem_check", in test_hashmap_generic()
218 if (CHECK(hashmap__delete(map, k, &oldk, &oldv), "elem_del", in test_hashmap_generic()
224 if (CHECK(found_cnt != ELEM_CNT || found_msk != (1ULL << ELEM_CNT) - 1, in test_hashmap_generic()
229 if (CHECK(hashmap__size(map) != 0, "hashmap__size", in test_hashmap_generic()
236 CHECK(false, "elem_exists", in test_hashmap_generic()
244 CHECK(false, "elem_exists", in test_hashmap_generic()
277 if (CHECK(err, "elem_add", "failed to add k/v: %d\n", err)) in test_hashmap_multimap()
280 if (CHECK(err, "elem_add", "failed to add k/v: %d\n", err)) in test_hashmap_multimap()
283 if (CHECK(err, "elem_add", "failed to add k/v: %d\n", err)) in test_hashmap_multimap()
287 if (CHECK(err, "elem_add", "failed to add k/v: %d\n", err)) in test_hashmap_multimap()
290 if (CHECK(err, "elem_add", "failed to add k/v: %d\n", err)) in test_hashmap_multimap()
293 if (CHECK(err, "elem_add", "failed to add k/v: %d\n", err)) in test_hashmap_multimap()
296 if (CHECK(hashmap__size(map) != 6, "hashmap_size", in test_hashmap_multimap()
305 if (CHECK(found_msk != (1 << 6) - 1, "found_msk", in test_hashmap_multimap()
314 if (CHECK(found_msk != (1 | 2 | 4), "found_msk", in test_hashmap_multimap()
323 if (CHECK(found_msk != (8 | 16 | 32), "found_msk", in test_hashmap_multimap()
343 if (CHECK(hashmap__size(map) != 0, "hashmap__size", in test_hashmap_empty()
346 if (CHECK(hashmap__capacity(map) != 0, "hashmap__capacity", in test_hashmap_empty()
349 if (CHECK(hashmap__find(map, k, NULL), "elem_find", in test_hashmap_empty()
352 if (CHECK(hashmap__delete(map, k, NULL, NULL), "elem_del", in test_hashmap_empty()
357 CHECK(false, "elem_found", "unexpected iterated entry\n"); in test_hashmap_empty()
361 CHECK(false, "key_found", "unexpected key entry\n"); in test_hashmap_empty()