From dd0c485ac4975b7dd6d2e230213be1da50d0a065 Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Fri, 18 Sep 2020 16:39:52 +0200 Subject: Removing unnecessary stuff --- test/src/mem/test_ft_calloc.c | 33 --------------------------------- 1 file changed, 33 deletions(-) delete mode 100644 test/src/mem/test_ft_calloc.c (limited to 'test/src/mem/test_ft_calloc.c') diff --git a/test/src/mem/test_ft_calloc.c b/test/src/mem/test_ft_calloc.c deleted file mode 100644 index 0df9b95..0000000 --- a/test/src/mem/test_ft_calloc.c +++ /dev/null @@ -1,33 +0,0 @@ -#include "libft_test.h" - -TEST_GROUP(ft_calloc); - -TEST_SETUP(ft_calloc) -{} - -TEST_TEAR_DOWN(ft_calloc) -{} - -TEST(ft_calloc, basic) -{ - char *ptr = NULL; - - ptr = ft_calloc(45, sizeof(char)); - TEST_ASSERT_NOT_NULL(ptr); -#ifdef __APPLE__ - TEST_ASSERT_GREATER_THAN(45 * sizeof(char) - 1, malloc_size(ptr)); -#endif - for (int i = 0; i < 45; i++) - TEST_ASSERT_EQUAL(0x0, ptr[i]); - /* free(ptr); */ - - int *ptrint = NULL; - ptrint = ft_calloc(10, sizeof(int)); - TEST_ASSERT_NOT_NULL(ptr); -#ifdef __APPLE__ - TEST_ASSERT_GREATER_THAN(10 * sizeof(int) - 1, malloc_size(ptrint)); -#endif - for (int i = 0; i < 10; i++) - TEST_ASSERT_EQUAL(0x0, ptrint[i]); - /* free(ptrint); */ -} -- cgit