add safe tests

pull/3/head
Matthew Butterick 10 years ago
parent bc37761543
commit fa148d6055

@ -7,7 +7,17 @@
(with-syntax ([sym (generate-temporary)])
#'(begin
(module sym racket
(require rackunit sugar net/url)
(require rackunit "../main.rkt" net/url)
exprs ...)
(require 'sym)))]))
(define-syntax (eval-as-untyped-safe stx)
(syntax-case stx ()
[(_ exprs ...)
(with-syntax ([sym (generate-temporary)])
#'(begin
(module sym racket
(require rackunit (submod "../main.rkt" safe) net/url)
exprs ...)
(require 'sym)))]))
@ -17,14 +27,15 @@
(with-syntax ([sym (generate-temporary)])
#'(begin
(module sym typed/racket
(require typed/rackunit typed/sugar typed/net/url)
(require typed/rackunit "../../typed/sugar.rkt" typed/net/url)
exprs ...)
(require 'sym)))]))
(define-syntax-rule (eval-as-typed-and-untyped exprs ...)
(begin
(eval-as-typed exprs ...)
(eval-as-untyped exprs ...)))
(eval-as-untyped exprs ...)
(eval-as-untyped-safe exprs ...)
(eval-as-typed exprs ...)))
(eval-as-typed-and-untyped

Loading…
Cancel
Save