]> git.ipfire.org Git - thirdparty/mdadm.git/commitdiff
test: redirect all output to log file to keep output clean
authorGilles Espinasse <g.esp@free.fr>
Mon, 22 Oct 2012 22:12:15 +0000 (09:12 +1100)
committerNeilBrown <neilb@suse.de>
Mon, 22 Oct 2012 22:12:15 +0000 (09:12 +1100)
If a test sent anything to stdout, it would not get logged, and would
mess up the listing of test status.

Signed-off-by: Gilles Espinasse <g.esp@free.fr>
Signed-off-by: NeilBrown <neilb@suse.de>
test

diff --git a/test b/test
index 48b47d94bb9b76c6f3d53b885e851926e8699a31..e31338503356cb1c9e4c6b6315b7490bc53015a9 100755 (executable)
--- a/test
+++ b/test
@@ -227,7 +227,7 @@ do_test() {
     # source script in a subshell, so it has access to our
     # namespace, but cannot change it.
     echo -ne "$_script... "
-    if ( set -ex ; . $_script )  2> $targetdir/log
+    if ( set -ex ; . $_script ) &> $targetdir/log
     then
       echo "succeeded"
       _fail=0