aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/helpers.h
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-02-07 09:25:17 +0900
committernsfisis <nsfisis@gmail.com>2026-02-07 09:25:17 +0900
commit107c517b22e88d760c375a4b9da6dffd6da26d85 (patch)
tree641106293c27c77aed9d2e4173d63d0c2ec225a6 /tests/helpers.h
parent3633f9a1f4f7638355beba85c53a2bb2ab0e3976 (diff)
downloadducc-107c517b22e88d760c375a4b9da6dffd6da26d85.tar.gz
ducc-107c517b22e88d760c375a4b9da6dffd6da26d85.tar.zst
ducc-107c517b22e88d760c375a4b9da6dffd6da26d85.zip
refactor: add ASSERT_EQ_STR() to tests/helpers.h
Diffstat (limited to 'tests/helpers.h')
-rw-r--r--tests/helpers.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/helpers.h b/tests/helpers.h
index 39274e4..c9d9819 100644
--- a/tests/helpers.h
+++ b/tests/helpers.h
@@ -6,6 +6,7 @@ struct FILE;
typedef struct FILE FILE;
int fprintf(FILE*, const char*, ...);
extern FILE* stderr;
+int strcmp(const char*, const char*);
#define ASSERT(a, file, line) \
do { \
@@ -16,5 +17,6 @@ extern FILE* stderr;
} while (0)
#define ASSERT_EQ(a, b) ASSERT((a) == (b), __FILE__, __LINE__)
+#define ASSERT_EQ_STR(a, b) ASSERT(strcmp((a), (b)) == 0, __FILE__, __LINE__)
#endif