From 84b61fcc2602c39e9dc8cd6390f733d6987ccbfe Mon Sep 17 00:00:00 2001 From: Charles Date: Sun, 3 Nov 2019 05:29:04 +0100 Subject: Added printf_tester tests --- helper.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'helper.c') diff --git a/helper.c b/helper.c index 9fe8d56..4a25772 100644 --- a/helper.c +++ b/helper.c @@ -4,7 +4,7 @@ #include #include "header.h" -#define BUF_SIZE (1 << 10) +#define BUF_SIZE (1 << 16) int pipefd[2]; int saved_stdout = -1; @@ -42,7 +42,7 @@ char *read_stdout_buf(void) void print_buf_ko(char *msg) { print_ko(); - printf("ft_printf(%s) has wrong output\n", msg); + printf("ft_printf(%s): output error\n", msg); printf("actual: \"%s\"\n", user_buf); printf("expected: \"%s\"\n", origin_buf); fflush(stdout); @@ -51,7 +51,7 @@ void print_buf_ko(char *msg) void print_ret_ko(char *msg) { print_ko(); - printf("ft_printf(%s) has wrong return value\n", msg); + printf("ft_printf(%s): return error\n", msg); printf("actual: %d\n", user_ret); printf("expected: %d\n", origin_ret); fflush(stdout); @@ -60,7 +60,7 @@ void print_ret_ko(char *msg) void print_signaled_ko(char *msg) { print_ko(); - printf("ft_printf(\"%s\") has been signaled (segfault and friends)\n", msg); + printf("ft_printf(\"%s\"): segfault)\n", msg); fflush(stdout); } -- cgit