svn: r17109
This commit is contained in:
parent
2bb3403f88
commit
bd0f694803
|
@ -8,6 +8,9 @@
|
|||
(define tool-names (list "How to Design Programs"))
|
||||
(define tool-urls (list "http://www.htdp.org/"))
|
||||
|
||||
(define compile-omit-paths
|
||||
'("test-error.ss"))
|
||||
|
||||
(define textbook-pls
|
||||
(list (list '("htdp-icon.gif" "icons")
|
||||
"How to Design Programs"
|
||||
|
|
|
@ -38,4 +38,3 @@ string-ref : String Nat -> Char
|
|||
|
||||
NOTE:
|
||||
substring consumes 2 or 3 arguments
|
||||
|
||||
|
|
16
collects/lang/test-error.ss
Normal file
16
collects/lang/test-error.ss
Normal file
|
@ -0,0 +1,16 @@
|
|||
;; The first three lines of this file were inserted by DrScheme. They record metadata
|
||||
;; about the language level of this file in a form that our tools can easily process.
|
||||
#reader(lib "htdp-beginner-reader.ss" "lang")((modname bar) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f ())))
|
||||
(check-error (error) "")
|
||||
(check-error (error 1) "1")
|
||||
(check-error (error 'a) "a: ")
|
||||
(check-error (error 'a "bad input") "a: bad input")
|
||||
(check-error (error 'a "bad input: " 1) "a: bad input: 1")
|
||||
(check-error (error 'a "bad input: " 1 " and " "hello") "a: bad input: 1 and hello")
|
||||
(check-error (error 'a "bad input: " 1 " and " false) "a: bad input: 1 and false")
|
||||
(check-error (error 'a "uhoh " (list 1 2 3)) "a: uhoh (cons 1 (cons 2 (cons 3 empty)))")
|
||||
|
||||
(define-struct err (str))
|
||||
|
||||
(check-error (error 'a "bad input: " 1 " and " (make-err "hello"))
|
||||
"a: bad input: 1 and (make-err \"hello\")")
|
Loading…
Reference in New Issue
Block a user