summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAlbert Cheng <acheng@hdfgroup.org>2011-10-04 08:16:00 (GMT)
committerAlbert Cheng <acheng@hdfgroup.org>2011-10-04 08:16:00 (GMT)
commit082a3ce442d90cc9c7cb04c50b48690de4e67ee9 (patch)
tree91ed0df03d01b8af55b07d395004725f2b7a5642 /tools
parent9d793e7e5ee3ac189ee07e6701fafaaeacd96c9a (diff)
downloadhdf5-082a3ce442d90cc9c7cb04c50b48690de4e67ee9.zip
hdf5-082a3ce442d90cc9c7cb04c50b48690de4e67ee9.tar.gz
hdf5-082a3ce442d90cc9c7cb04c50b48690de4e67ee9.tar.bz2
[svn-r21457] Problem:
Function TOOLTEST_OUTPUT does not filter the extra system messages sent to stdout or stderr, thus causing output mismatched with expected output. Solution: Added STDOUT_FILTER and STDERR_FILTER to filter them out. Tested: Tested LLNL uDawn (Blue-Gene cluster), for serial mode only.
Diffstat (limited to 'tools')
-rw-r--r--tools/h5jam/testh5jam.sh.in10
1 files changed, 10 insertions, 0 deletions
diff --git a/tools/h5jam/testh5jam.sh.in b/tools/h5jam/testh5jam.sh.in
index 14b381c..f359926 100644
--- a/tools/h5jam/testh5jam.sh.in
+++ b/tools/h5jam/testh5jam.sh.in
@@ -86,6 +86,9 @@ $SRC_H5JAM_TESTFILES/h5unjam-help.txt
$SRC_H5JAM_TESTFILES/h5jam-ub-nohdf5.txt
"
+# Source in the output filter function definitions.
+. $srcdir/../../bin/output_filter.sh
+
#
# copy test files and expected output files from source dirs to test dir
#
@@ -462,6 +465,8 @@ TOOLTEST_OUTPUT() {
expect="$TESTDIR/$1"
actual="$TESTDIR/`basename $1 .ls`.out"
actual_err="$TESTDIR/`basename $1 .ls`.err"
+ actual_sav=${actual}-sav
+ actual_err_sav=${actual_err}-sav
shift
retvalexpect=$1
shift
@@ -472,6 +477,11 @@ TOOLTEST_OUTPUT() {
$TOOLCMD "$@"
) >$actual 2>$actual_err
+ # save actual and actual_err in case they are needed later.
+ cp $actual $actual_sav
+ STDOUT_FILTER $actual
+ cp $actual_err $actual_err_sav
+ STDERR_FILTER $actual_err
# combine stderr to stdout for output compare
cat $actual_err >> $actual