diff options
Diffstat (limited to 'test/src/algo/test_ft_heapsort.c')
| -rw-r--r-- | test/src/algo/test_ft_heapsort.c | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/test/src/algo/test_ft_heapsort.c b/test/src/algo/test_ft_heapsort.c deleted file mode 100644 index 6c2c3fb..0000000 --- a/test/src/algo/test_ft_heapsort.c +++ /dev/null @@ -1,27 +0,0 @@ -#include "libft_test.h" - -TEST_GROUP(ft_heapsort); - -TEST_SETUP(ft_heapsort) -{} - -TEST_TEAR_DOWN(ft_heapsort) -{} - -static int compar(const void *a, const void *b) -{ - return *(int*)a - *(int*)b; -} - -TEST(ft_heapsort, basic) -{ - TEST_IGNORE(); - int arr[] = {3, 4, 1, 2, 7, 189, -1, -134, 7, 1, 34}; - int sorted_arr[sizeof(arr)]; - - memcpy(sorted_arr, arr, sizeof(arr)); - qsort(sorted_arr, sizeof(arr) / sizeof(int), sizeof(int), compar); - - ft_heapsort(arr, sizeof(arr) / sizeof(int), sizeof(int), compar); - TEST_ASSERT_EQUAL_INT_ARRAY(sorted_arr, arr, sizeof(arr) / sizeof(int)); -} |
