]> git.ipfire.org Git - pakfire.git/commitdiff
tests: Show received string as well as expected string
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 25 Feb 2021 11:43:12 +0000 (11:43 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 25 Feb 2021 11:43:12 +0000 (11:43 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
tests/testsuite.h

index f48b438e5ae735f9b004c2d04ec7b6fd200a1b3b..cbd10df303dfc171d3613f7f550296e90b446be1 100644 (file)
@@ -66,8 +66,8 @@ int testsuite_run();
 #define ASSERT_STRING_EQUALS(string, value) \
        do { \
                if (strcmp(string, value) != 0) { \
-                       LOG_ERROR("Failed assertion: " #string " != " #value " %s:%d %s\n", \
-                               __FILE__, __LINE__, __PRETTY_FUNCTION__); \
+                       LOG_ERROR("Failed assertion: " #string " (%s) != " #value " %s:%d %s\n", \
+                               string, __FILE__, __LINE__, __PRETTY_FUNCTION__); \
                        return EXIT_FAILURE; \
                } \
        } while (0)