diff options
Diffstat (limited to 'tests/math.lisp')
| -rw-r--r-- | tests/math.lisp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/math.lisp b/tests/math.lisp index 53e4668..cbd5298 100644 --- a/tests/math.lisp +++ b/tests/math.lisp @@ -1,7 +1,8 @@ -(defun ~~ (a b) - (if (< (abs (- a b)) 0.01) - nil - (error "failed"))) +(defun ~~f (a b) + (< (abs (- a b)) 0.01)) + +(defmacro ~~ (a b) + `(assert (~~f ,a ,b))) (assert (= 1 (abs -1))) (assert (= 1.1 (abs -1.1))) |
