aboutsummaryrefslogtreecommitdiff
path: root/testing.h
diff options
context:
space:
mode:
authorMartin Kagamino Lehoux <martin@lehoux.net>2025-07-23 19:39:13 +0200
committerMartin Kagamino Lehoux <martin@lehoux.net>2025-07-23 19:39:26 +0200
commit421300c27123ca647772dc6d9bd0cabf7f5f9c99 (patch)
treed916b62056b2440aef374b21373d16272bb709ee /testing.h
parent53e9e371a16ae2d167f1fc2577dff2c2426eed68 (diff)
refactor: src & pragma once
Diffstat (limited to 'testing.h')
-rw-r--r--testing.h24
1 files changed, 0 insertions, 24 deletions
diff --git a/testing.h b/testing.h
deleted file mode 100644
index 9e0c022..0000000
--- a/testing.h
+++ /dev/null
@@ -1,24 +0,0 @@
-#include <stdio.h>
-
-#define t_assert(fact) \
- if (!(fact)) { \
- fprintf(stderr, "Assertion failed: %s at %s:%d in %s()\n", #fact, \
- __FILE__, __LINE__, __func__); \
- return 1; \
- }
-
-#define t_assert_equal(a, b) \
- if (!(a == b)) { \
- fprintf(stderr, \
- "Assertion failed: %d (%s) != %d (%s) at %s:%d in %s()\n", \
- (i32)a, #a, (i32)b, #b, __FILE__, __LINE__, __func__); \
- return 1; \
- }
-
-#define t_assert_fequal(a, b) \
- if ((a - b) > 1e-6 || (b - a) > 1e-6) { \
- fprintf(stderr, \
- "Assertion failed: %f (%s) != %f (%s) at %s:%d in %s()\n", a, \
- #a, b, #b, __FILE__, __LINE__, __func__); \
- return 1; \
- }