aboutsummaryrefslogtreecommitdiffstats
path: root/csc/testing.csc
diff options
context:
space:
mode:
Diffstat (limited to 'csc/testing.csc')
-rw-r--r--csc/testing.csc10
1 files changed, 6 insertions, 4 deletions
diff --git a/csc/testing.csc b/csc/testing.csc
index a0180e6..aad2a63 100644
--- a/csc/testing.csc
+++ b/csc/testing.csc
@@ -59,11 +59,13 @@
(define-syntax assert-equal
(syntax-rules ()
+ ((assert-equal cmp left right)
+ (let ((x left)
+ (y right))
+ (unless (cmp x y)
+ (fatalf "Fatal: {} is not equal to {}.\nleft is {}\nright is {}" 'left 'right x y))))
((assert-equal left right)
- (let ((x left)
- (y right))
- (unless (equal? x y)
- (fatalf "Fatal: {} is not equal to {}.\nleft is {}\nright is {}" 'left 'right x y))))))
+ (assert-equal equal? left right))))
(define-syntax assert-raises