summaryrefslogtreecommitdiff
path: root/build-aux
diff options
context:
space:
mode:
Diffstat (limited to 'build-aux')
-rw-r--r--build-aux/test-driver.scm.in16
1 files changed, 10 insertions, 6 deletions
diff --git a/build-aux/test-driver.scm.in b/build-aux/test-driver.scm.in
index 89b9b68..96d84e0 100644
--- a/build-aux/test-driver.scm.in
+++ b/build-aux/test-driver.scm.in
@@ -17,7 +17,8 @@
;;; License along with guile-email. If not, see
;;; <http://www.gnu.org/licenses/>.
-(use-modules (ice-9 getopt-long)
+(use-modules (ice-9 format)
+ (ice-9 getopt-long)
(srfi srfi-26)
(srfi srfi-64))
@@ -44,11 +45,14 @@
(test-runner-on-group-end! runner (const #f))
(test-runner-on-test-end! runner
(lambda (runner)
- (format trs-port ":test-result: ~A ~A~%"
- (string-upcase
- (symbol->string
- (test-result-kind runner)))
- (test-runner-test-name runner))))
+ (let ((name (test-runner-test-name runner))
+ (result (string-upcase
+ (symbol->string (test-result-kind runner)))))
+ (format trs-port ":test-result: ~a ~a~%" result name)
+ (format (current-error-port)
+ "\x1b[~:[31~;32~]m~a\x1b[0m ~a~%"
+ (eq? (test-result-kind runner) 'pass)
+ result name))))
runner))
(let ((opts (getopt-long (command-line) %options)))