aboutsummaryrefslogtreecommitdiffstats
path: root/csc/compare-test.csc
diff options
context:
space:
mode:
Diffstat (limited to 'csc/compare-test.csc')
-rw-r--r--csc/compare-test.csc40
1 files changed, 27 insertions, 13 deletions
diff --git a/csc/compare-test.csc b/csc/compare-test.csc
index 8791e1d..379f21b 100644
--- a/csc/compare-test.csc
+++ b/csc/compare-test.csc
@@ -2,14 +2,15 @@
(only (csc match)
define-match-record-type)
(only (csc testing)
- assert-equal
+ assert
test)
(csc compare))
(test diff-list
- (assert-equal
- " (
+ (assert
+ (string=?
+ " (
1
- 2
3
@@ -17,7 +18,7 @@
4
)
"
- (diff '(1 2 3 4) '(1 3 3.5 4))))
+ (diff '(1 2 3 4) '(1 3 3.5 4)))))
(define-match-record-type <test-type>
@@ -29,8 +30,9 @@
(test diff-record
- (assert-equal
- " (
+ (assert
+ (string=?
+ " (
(!type .
<test-type>
)
@@ -43,12 +45,13 @@
)
)
"
- (diff (make-test-type 5 5) (make-test-type 5 6) (cons test-type? %test-type))))
+ (diff (make-test-type 5 5) (make-test-type 5 6) (cons test-type? %test-type)))))
(test diff-multiline-string
- (assert-equal
- " (
+ (assert
+ (string=?
+ " (
(!type .
string
)
@@ -61,12 +64,13 @@
)
)
"
- (diff "line-one\nline-two\nline-three" "line-one\nline-three")))
+ (diff "line-one\nline-two\nline-three" "line-one\nline-three"))))
(test diff-vector
- (assert-equal
- " (
+ (assert
+ (string=?
+ " (
(!type .
vector
)
@@ -79,4 +83,14 @@
)
)
"
- (diff #(1 2 3) #(1 3))))
+ (diff #(1 2 3) #(1 3)))))
+
+
+(test diff-symbol-list
+ (assert
+ (string=?
+ "- symbol
++ (
++ )
+"
+ (diff 'symbol '()))))