Skip to content

Commit

Permalink
Add list-with-head tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jackfirth committed Feb 19, 2015
1 parent 447e6a9 commit 4725b71
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion predicates/list.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@
(check-pred-domain (second? string?) '(6 "faz" c) '(2 #\a))
(check-pred-domain (rest? empty?) '(blah) '(blah foo))
(check-pred-domain (all? char?) '(#\a #\b #\c) '(#\a 5 #\c))
(check-pred-domain (listof? string? char? char?) '("blah" #\a #\b) '("foo" #\a 8)))
(check-pred-domain (listof? string? char? char?) '("blah" #\a #\b) '("foo" #\a 8))
(check-pred-domain (list-with-head? string? char?) '("blah" #\a 'any) '("blah" 'not-char 'any)))

(define not-null? (not? null?))
(define nonempty-list? (and? list? not-null?))
Expand Down

0 comments on commit 4725b71

Please sign in to comment.