]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
testsuite: Don't write ANSI escapes to test output files.
authorAndre Noll <maan@systemlinux.org>
Sun, 11 Sep 2011 01:02:41 +0000 (03:02 +0200)
committerAndre Noll <maan@systemlinux.org>
Sat, 15 Oct 2011 19:22:53 +0000 (21:22 +0200)
The say() function adds ANSI escape sequences for colors to the output
if stdout is a tty. However, we don't want colors for output written
to a file, so don't use say() in this case.

t/test-lib.sh

index b7d675ea0def671529e13732c52143bb22290288..f1bb8cf65b66ff3890659f2b6009bae08d3cbd77 100644 (file)
@@ -162,7 +162,7 @@ test_duration()
 test_expect_success()
 {
        (($# != 2)) && error "bug: not 2 parameters to test_expect_success()"
-       say >&3 "expecting success: $2"
+       echo >&3 "expecting success: $2"
        _test_run "$1" "$2" "success"
        echo >&3 ""
 }
@@ -170,7 +170,7 @@ test_expect_success()
 test_expect_failure()
 {
        (($# != 2)) && error "bug: not 2 parameters to test_expect_failure()"
-       say >&3 "expecting failure: $2"
+       echo >&3 "expecting failure: $2"
        _test_run "$1" "$2" "failure"
        echo >&3 ""
 }