From b29b18178b40eb0a362183d44217b358845923c1 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Mon, 30 Dec 2013 09:48:59 -0700 Subject: [PATCH] raco test: fix error summary in direct mode Also, fix a doc typo original commit: 58d425c00ca70a5eed9cc86f5215de3b2754a2f5 --- .../compiler-lib/compiler/commands/test.rkt | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/pkgs/compiler-pkgs/compiler-lib/compiler/commands/test.rkt b/pkgs/compiler-pkgs/compiler-lib/compiler/commands/test.rkt index d50a71f8d0..064aa735fe 100644 --- a/pkgs/compiler-pkgs/compiler-lib/compiler/commands/test.rkt +++ b/pkgs/compiler-pkgs/compiler-lib/compiler/commands/test.rkt @@ -714,13 +714,15 @@ #:sema (make-semaphore))) (when table? (display-summary sum)) - ;; Re-log failures and successes, and then report using `test-log`. - ;; (This is awkward; is it better to not try to use `test-log`?) - (for ([s (in-list sum)]) - (for ([i (in-range (summary-failed s))]) - (test-log! #f)) - (for ([i (in-range (- (summary-total s) - (summary-failed s)))]) - (test-log! #t))) + (unless (or (eq? default-mode 'direct) + (and (not default-mode) single-file?)) + ;; Re-log failures and successes, and then report using `test-log`. + ;; (This is awkward; is it better to not try to use `test-log`?) + (for ([s (in-list sum)]) + (for ([i (in-range (summary-failed s))]) + (test-log! #f)) + (for ([i (in-range (- (summary-total s) + (summary-failed s)))]) + (test-log! #t)))) (define r (test-log #:display? #t #:exit? #t)) (exit (if (zero? (car r)) 0 1))))