summaryrefslogtreecommitdiff
path: root/tests/check_all.c
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2019-12-23 21:49:29 -0600
committerMatt Turner <mattst88@gmail.com>2020-02-22 11:02:09 -0800
commit59e271e15bcecf0c461cd5c6c59081fb86b96c22 (patch)
treebd0657081305efc42ac087b2f83f38cf16e5fdf9 /tests/check_all.c
parent21324989b7e121c008a2c4fdf98547541cbf7b83 (diff)
tests: Support Check 0.13.0 API
[mattst88]: Keep compatibility with old API via preprocessor Fixes: #43
Diffstat (limited to 'tests/check_all.c')
-rw-r--r--tests/check_all.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/check_all.c b/tests/check_all.c
index 4393422..f4c909c 100644
--- a/tests/check_all.c
+++ b/tests/check_all.c
@@ -1,10 +1,19 @@
#include <stdlib.h>
#include "check_suites.h"
+#if CHECK_MAJOR_VERSION == 0 && CHECK_MINOR_VERSION < 13
void suite_add_test(Suite *s, TFun tf, const char *name)
+#else
+void suite_add_test(Suite *s, const TTest *tt, const char *name)
+#endif
{
TCase *tc = tcase_create(name);
+
+#if CHECK_MAJOR_VERSION == 0 && CHECK_MINOR_VERSION < 13
tcase_add_test(tc, tf);
+#else
+ tcase_add_test(tc, tt);
+#endif
suite_add_tcase(s, tc);
}