Projects : gscm : gscm_genesis

tests/common.scm

Dir - Raw

1(define interaction-env
2 (interaction-environment)) ; R5RS
3; user-initial-environment) ; MIT
4
5(define (write-line x)
6 (write x) (newline))
7
8(define (assert x . context)
9 (write-line (cons (if x 'pass 'fail) context)))
10
11(define (assert-equal a b . context)
12 (write-line (if (equal? a b)
13 (cons 'pass context)
14 (append (list 'fail a b) context))))