diff options
author | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2021-01-16 22:32:20 -0500 |
---|---|---|
committer | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2021-01-31 22:23:41 -0500 |
commit | 346210b1b2130112dd5f894c1d40afb37c1c51a5 (patch) | |
tree | e4173962485a0bc14425f58b121573d305e58f83 /build-aux | |
parent | 13f299b2c98cce0ede3a8a37dd11832fdb3827bb (diff) | |
download | guix-346210b1b2130112dd5f894c1d40afb37c1c51a5.tar.gz |
build: test-driver.scm: Enable colored test results by default.
The Automake parallel test harness does its own smart detection of the terminal color capability and always provides the --color-tests argument to the driver. This change defaults the --color-tests argument to true when the test driver is run on its own (not via Automake). * build-aux/test-driver.scm (main): Set the default value of the --color-tests argument to true when it's not explicitly provided.
Diffstat (limited to 'build-aux')
-rw-r--r-- | build-aux/test-driver.scm | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/build-aux/test-driver.scm b/build-aux/test-driver.scm index eee3f1e08c..fe7e9c8807 100644 --- a/build-aux/test-driver.scm +++ b/build-aux/test-driver.scm @@ -163,14 +163,17 @@ void port, which means no TRS output is logged." (let ((log (and=> (option 'log-file #f) (cut open-file <> "w0"))) (trs (and=> (option 'trs-file #f) (cut open-file <> "wl"))) (out (duplicate-port (current-output-port) "wl")) - (test-name (option 'test-name #f))) + (test-name (option 'test-name #f)) + (color-tests (if (assoc 'color-tests opts) + (option->boolean opts 'color-tests) + #t))) (when log (redirect-port log (current-output-port)) (redirect-port log (current-warning-port)) (redirect-port log (current-error-port))) (test-with-runner (test-runner-gnu test-name - #:color? (option->boolean opts 'color-tests) + #:color? color-tests #:brief? (option->boolean opts 'brief) #:out-port out #:trs-port trs) (load-from-path test-name)) |