subunit.sh: Properly capture and pass on the command output.
authorAndrew Kroeger <andrew@sprocks.gotdns.com>
Wed, 21 May 2008 07:07:45 +0000 (02:07 -0500)
committerAndrew Kroeger <andrew@sprocks.gotdns.com>
Thu, 22 May 2008 01:46:14 +0000 (20:46 -0500)
commitc0234d13192c1871971b45121249395ef15c5ae5
tree39d0c1b3875045dee92b263997dc9868639c0f78
parent96501be38da947f02ad57217e0bc23f7a66d36f9
subunit.sh: Properly capture and pass on the command output.

Previously, the output from $cmdline was never captured.  In case of a
failure, there was no output being passed to the subunit_fail_test() function,
but that function contains a call to "cat -".  This caused the script to hang
indefinitely waiting for input.

We now capture $cmdline output (including mapping stderr to stdout) using
backticks, and then pipe that output to the subunit_fail_test() if there is
a failure.
testprogs/blackbox/subunit.sh