From d53d3c3528ff6cc2ebf90c3602f0275a3a7b2efc Mon Sep 17 00:00:00 2001 From: Robby Findler Date: Fri, 4 Jan 2013 16:58:13 -0600 Subject: [PATCH] try to make this test's timing better behaved --- collects/tests/future/random-future.rkt | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/collects/tests/future/random-future.rkt b/collects/tests/future/random-future.rkt index 517bab206e..144f4abf57 100644 --- a/collects/tests/future/random-future.rkt +++ b/collects/tests/future/random-future.rkt @@ -186,11 +186,13 @@ Errors/exceptions and other kinds of control? (printf "DrDr Ignore! random-seed ~s\n" seed) (random-seed seed)) +(define start-time (current-seconds)) (let loop ([n 32]) (unless (zero? n) - (printf ".") (flush-output) - (let ([p (gen-prog)]) - ;(pretty-print p) - (eval p (namespace-anchor->namespace ns-here))) - (loop (- n 1)))) + (when (< (- (current-seconds) start-time) 120) + (printf ".") (flush-output) + (let ([p (gen-prog)]) + ;(pretty-print p) + (eval p (namespace-anchor->namespace ns-here))) + (loop (- n 1))))) (newline)