summaryrefslogtreecommitdiffstats
path: root/tools/test/h5dump/testh5dump.sh.in
diff options
context:
space:
mode:
Diffstat (limited to 'tools/test/h5dump/testh5dump.sh.in')
-rw-r--r--tools/test/h5dump/testh5dump.sh.in30
1 files changed, 30 insertions, 0 deletions
diff --git a/tools/test/h5dump/testh5dump.sh.in b/tools/test/h5dump/testh5dump.sh.in
index e5680cf..f920b9c 100644
--- a/tools/test/h5dump/testh5dump.sh.in
+++ b/tools/test/h5dump/testh5dump.sh.in
@@ -935,6 +935,36 @@ GREPTEST()
fi
}
+# Call the h5dump tool and grep for an error string
+#
+GREPERRTEST()
+{
+ expectdata=$1
+ actual=$TESTDIR/$2
+ actual_err="$TESTDIR/`basename $2 .ddl`.oerr"
+ shift
+ shift
+
+ # Run test.
+ TESTING $DUMPER -p $@
+ (
+ cd $TESTDIR
+ $ENVCMD $RUNSERIAL $DUMPER_BIN -p "$@"
+ ) >$actual 2>$actual_err
+ $GREP "$expectdata" $actual_err > /dev/null
+ if [ $? -eq 0 ]; then
+ echo " PASSED"
+ else
+ echo " FAILED"
+ nerrors="`expr $nerrors + 1`"
+ fi
+
+ # Clean up output file
+ if test -z "$HDF5_NOCLEANUP"; then
+ rm -f $actual $actual_err
+ fi
+}
+
# Print a "SKIP" message
SKIP() {
TESTING $DUMPER $@