Browse code

Fix tee statement for catching tempest output

The use of exec and tee doesn't seem to be quite right, and was
unreliable in terms of catching the exit status of the tempest
test as well as not catching the output when things went wrong.

This changes the way we do the redirect and the tee to something
that should be more robust and seems to work reliably in testing.

Change-Id: Ieb9d725839fb8e3f9e2e63a2b7b2e9c7c86713a2

John Griffith authored on 2014/02/14 07:56:29
Showing 1 changed files
... ...
@@ -89,9 +89,8 @@ start_cinder
89 89
 sleep 5
90 90
 
91 91
 # run tempest api/volume/test_*
92
-log_message "Run the actual tempest volume tests (./tools/pretty_tox.sh api.volume_*)...", True
93
-exec 2> >(tee -a $TEMPFILE)
94
-`./tools/pretty_tox.sh api.volume`
92
+log_message "Run the actual tempest volume tests (./tools/pretty_tox.sh api.volume)...", True
93
+./tools/pretty_tox.sh api.volume 2>&1 | tee -a $TEMPFILE
95 94
 if [[ $? = 0 ]]; then
96 95
     log_message "CONGRATULATIONS!!!  Device driver PASSED!", True
97 96
     log_message "Submit output: ($TEMPFILE)"