diff --git a/tests/test-parse-bytecode-on-collects.rkt b/tests/test-parse-bytecode-on-collects.rkt index aa0d481..496a21a 100644 --- a/tests/test-parse-bytecode-on-collects.rkt +++ b/tests/test-parse-bytecode-on-collects.rkt @@ -7,6 +7,7 @@ ;; read-syntax: cannot load snip-class reader (require "../parse-bytecode.rkt" + racket/list racket/path) (define collects-dir @@ -19,12 +20,19 @@ [else p])))) +(define failures '()) (for ([path (in-directory collects-dir)]) (when (regexp-match? #rx"[.]rkt$" path) (printf "parsing file: ~a... " path) (flush-output) (let ([start-time (current-inexact-milliseconds)]) - (void (parse-bytecode path)) - (let ([end-time (current-inexact-milliseconds)]) - (printf "~a msecs\n" (inexact->exact (floor (- end-time start-time)))))))) \ No newline at end of file + (with-handlers ((exn:fail? (lambda (exn) + (set! failures (cons path failures)) + (printf "FAILED! ~a" (exn-message exn))))) + (void (parse-bytecode path)) + (let ([end-time (current-inexact-milliseconds)]) + (printf "~a msecs\n" (inexact->exact (floor (- end-time start-time))))))))) + +(unless (empty? failures) + (printf "Failed on: ~s" failures)) \ No newline at end of file