summaryrefslogtreecommitdiff
path: root/src/scheme/tiny-test/ao_scheme_tiny_test.scheme
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2018-01-10 23:11:40 -0800
committerKeith Packard <keithp@keithp.com>2018-01-10 23:11:40 -0800
commitf26cc1a677f577da533425a15485fcaa24626b23 (patch)
tree2f1e96addf6af39a9013acc76409f9df74a5e561 /src/scheme/tiny-test/ao_scheme_tiny_test.scheme
parent4b52fc6eea9a478cb3dd42dcd32c92838df39734 (diff)
altos/scheme: Move ao-scheme to a separate repository
This way it can be incorporated into multiple operating systems more easily. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/scheme/tiny-test/ao_scheme_tiny_test.scheme')
-rw-r--r--src/scheme/tiny-test/ao_scheme_tiny_test.scheme56
1 files changed, 0 insertions, 56 deletions
diff --git a/src/scheme/tiny-test/ao_scheme_tiny_test.scheme b/src/scheme/tiny-test/ao_scheme_tiny_test.scheme
deleted file mode 100644
index 94c90ffe..00000000
--- a/src/scheme/tiny-test/ao_scheme_tiny_test.scheme
+++ /dev/null
@@ -1,56 +0,0 @@
- ; Basic syntax tests
-
-(define _assert-eq_
- (macro (a b)
- (list cond
- (list (list eq? a b)
- )
- (list 'else
- (list display "failed: ")
- (list write (list quote a))
- (list newline)
- (list exit 1)
- )
- )
- )
- )
-
-(define _assert-equal_
- (macro (a b)
- (list cond
- (list (list equal? a b)
- )
- (list 'else
- (list display "failed: ")
- (list write (list quote a))
- (list newline)
- (list exit 1)
- )
- )
- )
- )
-
-(_assert-eq_ (or #f #t) #t)
-(_assert-eq_ (and #t #f) #f)
-(_assert-eq_ (if (> 3 2) 'yes) 'yes)
-(_assert-eq_ (if (> 3 2) 'yes 'no) 'yes)
-(_assert-eq_ (if (> 2 3) 'no 'yes) 'yes)
-(_assert-eq_ (if (> 2 3) 'no) #f)
-
-(_assert-eq_ (letrec ((a 1) (b a)) (+ a b)) 2)
-
-(_assert-eq_ (equal? '(a b c) '(a b c)) #t)
-(_assert-eq_ (equal? '(a b c) '(a b b)) #f)
-
-(_assert-equal_ (member '(2) '((1) (2) (3))) '((2) (3)))
-(_assert-equal_ (member '(4) '((1) (2) (3))) #f)
-
-(_assert-equal_ (memq 2 '(1 2 3)) '(2 3))
-(_assert-equal_ (memq 4 '(1 2 3)) #f)
-(_assert-equal_ (memq '(2) '((1) (2) (3))) #f)
-
-(_assert-equal_ (assq 'a '((a 1) (b 2) (c 3))) '(a 1))
-(_assert-equal_ (assoc '(c) '((a 1) (b 2) ((c) 3))) '((c) 3))
-
-(_assert-equal_ (map cadr '((a b) (d e) (g h))) '(b e h))
-