]> Untitled Git - axy/ft/ft_printf.git/commitdiff
valgrind tests
author= <=>
Sun, 2 Nov 2025 13:16:05 +0000 (14:16 +0100)
committer= <=>
Sun, 2 Nov 2025 13:16:05 +0000 (14:16 +0100)
test.c
test.sh

diff --git a/test.c b/test.c
index 98319fcfae132233b81dc06f1a0af2ca8b0f5f56..a506bceb82de04334d4561e396c68d55b3468819 100644 (file)
--- a/test.c
+++ b/test.c
@@ -6,17 +6,10 @@
 /*   By: agilliar <agilliar@student.42mulhouse.fr>  +#+  +:+       +#+        */
 /*                                                +#+#+#+#+#+   +#+           */
 /*   Created: 2025/10/31 23:55:18 by agilliar          #+#    #+#             */
-/*   Updated: 2025/11/01 00:07:17 by agilliar         ###   ########.fr       */
+/*   Updated: 2025/11/02 14:15:59 by agilliar         ###   ########.fr       */
 /*                                                                            */
 /* ************************************************************************** */
 
-/*
-       cc test.c libftprintf.a && ./a.out > test.out && [ \
-       "$(awk "NR % 2 == 1 { print; }" test.out)" \
-       == "$(awk "NR % 2 == 0 { print; }" test.out)" ] \
-       || echo "TEST FAILED"
-*/
-
 #include <stdio.h>
 #include <limits.h>
 #include "libftprintf.h"
diff --git a/test.sh b/test.sh
index c5a80101848e95b78c4e10759bbaa755c4860999..e9a144ea79a597f613eb884a46b64f6129e47aeb 100755 (executable)
--- a/test.sh
+++ b/test.sh
@@ -2,7 +2,7 @@
 
 make
 
-cc test.c libftprintf.a && ./a.out > test.out && [ \
+cc test.c libftprintf.a && valgrind ./a.out > test.out && [ \
        "$(awk "NR % 2 == 1 { print; }" test.out)" \
        == "$(awk "NR % 2 == 0 { print; }" test.out)" ] \
        || echo "TEST FAILED"