diff --git a/collects/tests/typed-racket/tr-random-testing.rkt b/collects/tests/typed-racket/tr-random-testing.rkt index fd79fd73..f8059145 100644 --- a/collects/tests/typed-racket/tr-random-testing.rkt +++ b/collects/tests/typed-racket/tr-random-testing.rkt @@ -4,7 +4,7 @@ (require redex racket/flonum racket/unsafe/ops - racket/sandbox + racket/sandbox racket/cmdline "random-real.rkt") (require (except-in typed-racket/utils/utils infer) @@ -144,11 +144,16 @@ #f) ; go on and check preservation (right-type? sexp))) +(define n-attempts 1000) +(command-line + #:once-each + [("-n") n "Number of attempts" (set! n-attempts (string->number n))]) + (call-with-limits #f 1000 (lambda () (redex-check tr-arith F (check-all-reals (term F)) - #:attempts 1000 + #:attempts n-attempts #:prepare exp->real-exp))) ;(printf "bad tests (usually typechecking failed): ~v~n" num-exceptions)