aboutsummaryrefslogtreecommitdiff
path: root/test_mini/libft/test/src/mem/test_ft_memswap.c
diff options
context:
space:
mode:
authornass1pro <nass1pro@gmail.com>2020-06-12 13:52:58 +0200
committernass1pro <nass1pro@gmail.com>2020-06-13 11:45:50 +0200
commitd971bd8d16608f316396aba7a579d0b1f1af5aeb (patch)
tree98ec558582ed20a120e13b4a376fd206fb620da0 /test_mini/libft/test/src/mem/test_ft_memswap.c
parent3136f59540a8dd29e2f096be5a8943e2ddd28431 (diff)
downloadminishell-d971bd8d16608f316396aba7a579d0b1f1af5aeb.tar.gz
minishell-d971bd8d16608f316396aba7a579d0b1f1af5aeb.tar.bz2
minishell-d971bd8d16608f316396aba7a579d0b1f1af5aeb.zip
Added e_token enum
Diffstat (limited to 'test_mini/libft/test/src/mem/test_ft_memswap.c')
-rw-r--r--test_mini/libft/test/src/mem/test_ft_memswap.c41
1 files changed, 0 insertions, 41 deletions
diff --git a/test_mini/libft/test/src/mem/test_ft_memswap.c b/test_mini/libft/test/src/mem/test_ft_memswap.c
deleted file mode 100644
index 72c3402..0000000
--- a/test_mini/libft/test/src/mem/test_ft_memswap.c
+++ /dev/null
@@ -1,41 +0,0 @@
-/* ************************************************************************** */
-/* */
-/* ::: :::::::: */
-/* test_ft_memswap.c :+: :+: :+: */
-/* +:+ +:+ +:+ */
-/* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */
-/* +#+#+#+#+#+ +#+ */
-/* Created: 2020/02/13 03:38:27 by cacharle #+# #+# */
-/* Updated: 2020/02/13 04:18:14 by cacharle ### ########.fr */
-/* */
-/* ************************************************************************** */
-
-#include "libft_test.h"
-
-TEST_GROUP(ft_memswap);
-
-TEST_SETUP(ft_memswap)
-{}
-
-TEST_TEAR_DOWN(ft_memswap)
-{}
-
-TEST(ft_memswap, basic)
-{
- char buf1[32] = "bonjour";
- char buf2[32] = "aurevoir";
- ft_memswap(buf1, buf2, 32);
- TEST_ASSERT_EQUAL_STRING("bonjour", buf2);
- TEST_ASSERT_EQUAL_STRING("aurevoir", buf1);
- ft_memswap(buf1, buf2, 3);
- TEST_ASSERT_EQUAL_STRING("aurjour", buf2);
- TEST_ASSERT_EQUAL_STRING("bonevoir", buf1);
- ft_memswap(buf1, buf2, 0);
- TEST_ASSERT_EQUAL_STRING("aurjour", buf2);
- TEST_ASSERT_EQUAL_STRING("bonevoir", buf1);
- int a = 1234567;
- int b = 7654321;
- ft_memswap(&a, &b, sizeof(int));
- TEST_ASSERT_EQUAL(7654321, a);
- TEST_ASSERT_EQUAL(1234567, b);
-}