svn: r13939
This commit is contained in:
John Clements 2009-03-04 06:46:00 +00:00
parent b4f6c524a1
commit 7a701cef2c

View File

@ -702,6 +702,17 @@
-> ,@defs (+ {-9} 10)
:: ,@defs {(+ -9 10)}
-> ,@defs {1}))
;; loops; I should add a mechanism to stop testing after n steps...
#;(let ([defs '((define (f x) (cond (else (f x))))
(define (g x) x))])
(t pnkfelix test-intermediate/lambda-sequence
,@defs (f (g empty))
:: ,@defs ({f} (g empty))
-> ,@defs ({(lambda (x) (cond (else (f x))))} (g empty))
:: ,@defs ((lambda (x) (cond (else (f x)))) ({g} empty))
-> ,@defs ((lambda (x) (cond (else (f x)))) ({(lambda (x) x)} empty))))
(t bad-cons test-upto-int/lam
(cons 1 2)
@ -1355,7 +1366,7 @@
))
(t check-expect test-bwla-to-int/lam
(t check-expect test-upto-int/lam
(check-expect (+ 3 4) (+ 8 9)) (check-expect (+ 1 1) 2) (check-expect (+ 2 2) 4) (+ 4 5)
:: {(+ 4 5)} -> {9}
:: 9 (check-expect (+ 3 4) {(+ 8 9)}) -> 9 (check-expect (+ 3 4) {17})
@ -1364,7 +1375,7 @@
:: 9 false true (check-expect {(+ 2 2)} 4) -> 9 false true (check-expect {4} 4))
(t1 check-within
(test-bwla-to-int/lam
(test-upto-int/lam
"(check-within (+ 3 4) (+ 8 10) (+ 10 90)) (check-expect (+ 1 1) 2)(+ 4 5)"
`((before-after ((hilite (+ 4 5)))
((hilite 9)))
@ -1379,7 +1390,7 @@
(t1 check-within-bad
(test-bwla-to-int/lam
(test-upto-int/lam
"(check-within (+ 3 4) (+ 8 10) 0.01) (+ 4 5) (check-expect (+ 1 1) 2)"
`((before-after ((hilite (+ 4 5)))
((hilite 9)))
@ -1392,7 +1403,7 @@
(let ([errmsg "rest: expected argument of type <non-empty list>; given ()"])
(t1 check-error
(test-bwla-to-int/lam
(test-upto-int/lam
"(check-error (+ (+ 3 4) (rest empty)) (string-append \"rest: \" \"expected argument of type <non-empty list>; given ()\")) (check-expect (+ 3 1) 4) (+ 4 5)"
`((before-after ((hilite (+ 4 5)))
((hilite 9)))
@ -1404,7 +1415,7 @@
(9 true (check-expect (hilite 4) 4)))))))
(t1 check-error-bad
(test-bwla-to-int/lam
(test-upto-int/lam
"(check-error (+ (+ 3 4) (rest empty)) (string-append \"b\" \"ogus\")) (check-expect (+ 3 1) 4) (+ 4 5)"
`((before-after ((hilite (+ 4 5)))
((hilite 9)))
@ -1681,6 +1692,7 @@
"(define (f2c x) x) (convert-gui f2c)" `() ; placeholder
))
;; run whatever tests are enabled (intended for interactive use):
(define (ggg)
(parameterize (#;[disable-stepper-error-handling #t]
@ -1688,8 +1700,8 @@
#;[store-steps #f]
#;[show-all-steps #t])
#;(run-tests '(check-expect check-within check-within-bad check-error) #;'(#;check-expect #;check-expect-2 check-within check-within-bad check-error))
(run-tests '(check-expect check-within check-error check-error-bad))
#;(run-all-tests)))
#;(run-tests '(check-expect check-within check-error check-error-bad))
(run-all-tests)))