From ea3a3a25f11dff8794418ef747ea8061473d13bb Mon Sep 17 00:00:00 2001 From: Allen Byrne <50328838+byrnHDF@users.noreply.github.com> Date: Mon, 6 May 2024 08:31:39 -0500 Subject: [PATCH] Remove use of err files in autotools test scripts (#4461) --- .gitattributes | 1 - config/cmake/ZLIB/CMakeLists.txt | 2 +- tools/test/h5copy/expected/h5copy_misc1.err | 1 - tools/test/h5copy/testh5copy.sh.in | 136 +++------ tools/test/h5diff/expected/dangling_link.err | 4 - tools/test/h5diff/expected/h5diff_601_ERR.err | 4 - tools/test/h5diff/expected/h5diff_udfail.err | 12 - tools/test/h5diff/h5diff_plugin.sh.in | 88 ------ tools/test/h5diff/testh5diff.sh.in | 5 +- tools/test/h5dump/CMakeTestsVDS.cmake | 5 - tools/test/h5dump/errfiles/filter_fail.err | 33 --- tools/test/h5dump/errfiles/infinite_loop.err | 1 - tools/test/h5dump/errfiles/non_existing.err | 1 - .../pbits/tnofilename-with-packed-bits.err | 1 - .../pbits/tpbitsCharLengthExceeded.err | 1 - .../pbits/tpbitsCharOffsetExceeded.err | 1 - .../errfiles/pbits/tpbitsIncomplete.err | 1 - .../pbits/tpbitsIntLengthExceeded.err | 1 - .../pbits/tpbitsIntOffsetExceeded.err | 1 - .../errfiles/pbits/tpbitsLengthExceeded.err | 1 - .../errfiles/pbits/tpbitsLengthPositive.err | 1 - .../pbits/tpbitsLongLengthExceeded.err | 1 - .../pbits/tpbitsLongOffsetExceeded.err | 1 - .../errfiles/pbits/tpbitsMaxExceeded.err | 1 - .../errfiles/pbits/tpbitsOffsetExceeded.err | 1 - .../errfiles/pbits/tpbitsOffsetNegative.err | 1 - tools/test/h5dump/errfiles/tall-1.err | 37 --- tools/test/h5dump/errfiles/tall-2A.err | 37 --- tools/test/h5dump/errfiles/tall-2A0.err | 37 --- tools/test/h5dump/errfiles/tall-2B.err | 37 --- tools/test/h5dump/errfiles/tarray1_big.err | 31 -- tools/test/h5dump/errfiles/tattr-3.err | 26 -- tools/test/h5dump/errfiles/tattrregR.err | 21 -- tools/test/h5dump/errfiles/tcomp-3.err | 31 -- tools/test/h5dump/errfiles/tdataregR.err | 21 -- tools/test/h5dump/errfiles/tdset-2.err | 57 ---- .../test/h5dump/errfiles/texceedsubblock.err | 1 - .../test/h5dump/errfiles/texceedsubcount.err | 1 - .../test/h5dump/errfiles/texceedsubstart.err | 1 - .../test/h5dump/errfiles/texceedsubstride.err | 1 - tools/test/h5dump/errfiles/textlink.err | 74 ----- tools/test/h5dump/errfiles/textlinkfar.err | 255 ---------------- tools/test/h5dump/errfiles/textlinksrc.err | 255 ---------------- tools/test/h5dump/errfiles/tgroup-2.err | 32 -- tools/test/h5dump/errfiles/torderlinks1.err | 37 --- tools/test/h5dump/errfiles/torderlinks2.err | 37 --- tools/test/h5dump/errfiles/tperror.err | 57 ---- tools/test/h5dump/errfiles/tqmarkfile.err | 33 --- tools/test/h5dump/errfiles/tslink-D.err | 40 --- tools/test/h5dump/testh5dump.sh.in | 259 +++++------------ tools/test/h5dump/testh5dumppbits.sh.in | 274 ++---------------- tools/test/h5dump/testh5dumpvds.sh.in | 240 +-------------- tools/test/h5format_convert/testh5fc.sh.in | 39 ++- tools/test/h5ls/errfiles/nosuchfile.err | 1 - .../h5ls/errfiles/textlinksrc-nodangle-1.err | 2 - tools/test/h5ls/errfiles/tgroup-1.err | 2 - tools/test/h5ls/testh5ls.sh.in | 8 - .../test/h5stat/expected/h5stat_err1_dims.err | 1 - .../h5stat/expected/h5stat_err1_links.err | 1 - .../h5stat/expected/h5stat_err1_numattrs.err | 1 - .../h5stat/expected/h5stat_err2_numattrs.err | 1 - .../h5stat/expected/h5stat_err_old_fill.err | 1 - .../h5stat/expected/h5stat_err_old_layout.err | 1 - .../h5stat/expected/h5stat_err_refcount.err | 1 - tools/test/h5stat/expected/h5stat_nofile.err | 1 - .../test/h5stat/expected/h5stat_notexist.err | 1 - tools/test/h5stat/testh5stat.sh.in | 82 ++++-- .../misc/expected/h5clear_missing_file.err | 1 - .../misc/expected/h5clear_no_mdc_image.err | 1 - .../test/misc/expected/h5clear_open_fail.err | 1 - tools/test/misc/testh5clear.sh.in | 46 +-- 71 files changed, 264 insertions(+), 2166 deletions(-) delete mode 100644 tools/test/h5copy/expected/h5copy_misc1.err delete mode 100644 tools/test/h5diff/expected/dangling_link.err delete mode 100644 tools/test/h5diff/expected/h5diff_601_ERR.err delete mode 100644 tools/test/h5diff/expected/h5diff_udfail.err delete mode 100644 tools/test/h5dump/errfiles/filter_fail.err delete mode 100644 tools/test/h5dump/errfiles/infinite_loop.err delete mode 100644 tools/test/h5dump/errfiles/non_existing.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tnofilename-with-packed-bits.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsCharLengthExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsCharOffsetExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsIncomplete.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsIntLengthExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsIntOffsetExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsLengthExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsLengthPositive.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsLongLengthExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsLongOffsetExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsMaxExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsOffsetExceeded.err delete mode 100644 tools/test/h5dump/errfiles/pbits/tpbitsOffsetNegative.err delete mode 100644 tools/test/h5dump/errfiles/tall-1.err delete mode 100644 tools/test/h5dump/errfiles/tall-2A.err delete mode 100644 tools/test/h5dump/errfiles/tall-2A0.err delete mode 100644 tools/test/h5dump/errfiles/tall-2B.err delete mode 100644 tools/test/h5dump/errfiles/tarray1_big.err delete mode 100644 tools/test/h5dump/errfiles/tattr-3.err delete mode 100644 tools/test/h5dump/errfiles/tattrregR.err delete mode 100644 tools/test/h5dump/errfiles/tcomp-3.err delete mode 100644 tools/test/h5dump/errfiles/tdataregR.err delete mode 100644 tools/test/h5dump/errfiles/tdset-2.err delete mode 100644 tools/test/h5dump/errfiles/texceedsubblock.err delete mode 100644 tools/test/h5dump/errfiles/texceedsubcount.err delete mode 100644 tools/test/h5dump/errfiles/texceedsubstart.err delete mode 100644 tools/test/h5dump/errfiles/texceedsubstride.err delete mode 100644 tools/test/h5dump/errfiles/textlink.err delete mode 100644 tools/test/h5dump/errfiles/textlinkfar.err delete mode 100644 tools/test/h5dump/errfiles/textlinksrc.err delete mode 100644 tools/test/h5dump/errfiles/tgroup-2.err delete mode 100644 tools/test/h5dump/errfiles/torderlinks1.err delete mode 100644 tools/test/h5dump/errfiles/torderlinks2.err delete mode 100644 tools/test/h5dump/errfiles/tperror.err delete mode 100644 tools/test/h5dump/errfiles/tqmarkfile.err delete mode 100644 tools/test/h5dump/errfiles/tslink-D.err delete mode 100644 tools/test/h5ls/errfiles/nosuchfile.err delete mode 100644 tools/test/h5ls/errfiles/textlinksrc-nodangle-1.err delete mode 100644 tools/test/h5ls/errfiles/tgroup-1.err delete mode 100644 tools/test/h5stat/expected/h5stat_err1_dims.err delete mode 100644 tools/test/h5stat/expected/h5stat_err1_links.err delete mode 100644 tools/test/h5stat/expected/h5stat_err1_numattrs.err delete mode 100644 tools/test/h5stat/expected/h5stat_err2_numattrs.err delete mode 100644 tools/test/h5stat/expected/h5stat_err_old_fill.err delete mode 100644 tools/test/h5stat/expected/h5stat_err_old_layout.err delete mode 100644 tools/test/h5stat/expected/h5stat_err_refcount.err delete mode 100644 tools/test/h5stat/expected/h5stat_nofile.err delete mode 100644 tools/test/h5stat/expected/h5stat_notexist.err delete mode 100644 tools/test/misc/expected/h5clear_missing_file.err delete mode 100644 tools/test/misc/expected/h5clear_no_mdc_image.err delete mode 100644 tools/test/misc/expected/h5clear_open_fail.err diff --git a/.gitattributes b/.gitattributes index 084de90778c..b03dddfc95d 100644 --- a/.gitattributes +++ b/.gitattributes @@ -573,7 +573,6 @@ tools/h5diff/testfiles/tmpSingleSiteBethe.output.h5 -text tools/h5diff/testfiles/tmpSingleSiteBethe.reference.h5 -text tools/h5diff/testfiles/tmptest.he5 -text tools/h5diff/testfiles/tmptest2.he5 -text -tools/h5dump/errfiles/non_existing.err -text tools/h5format_convert/CMakeLists.txt -text tools/h5format_convert/CMakeTests.cmake -text tools/h5format_convert/Makefile.am -text diff --git a/config/cmake/ZLIB/CMakeLists.txt b/config/cmake/ZLIB/CMakeLists.txt index 7b5d0cf62dd..e3c90b609d7 100644 --- a/config/cmake/ZLIB/CMakeLists.txt +++ b/config/cmake/ZLIB/CMakeLists.txt @@ -129,7 +129,7 @@ endif () # Compiler specific flags : Shouldn't there be compiler tests for these #----------------------------------------------------------------------------- if (CMAKE_C_COMPILER_ID STREQUAL "GNU") - set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -Wno-strict-prototypes") + set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -Wno-strict-prototypes -Wno-implicit-function-declaration") endif () if (CMAKE_C_COMPILER_ID MATCHES "IntelLLVM" OR CMAKE_C_COMPILER_ID MATCHES "[Cc]lang") set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -Wno-implicit-function-declaration") diff --git a/tools/test/h5copy/expected/h5copy_misc1.err b/tools/test/h5copy/expected/h5copy_misc1.err deleted file mode 100644 index 2c2c867290b..00000000000 --- a/tools/test/h5copy/expected/h5copy_misc1.err +++ /dev/null @@ -1 +0,0 @@ -h5copy error: group doesn't exist. Use -p to create parent groups. diff --git a/tools/test/h5copy/testh5copy.sh.in b/tools/test/h5copy/testh5copy.sh.in index 916e2bec3e9..84a746c23b4 100644 --- a/tools/test/h5copy/testh5copy.sh.in +++ b/tools/test/h5copy/testh5copy.sh.in @@ -59,7 +59,6 @@ $SRC_H5COPY_TESTFILES/h5copy_extlinks_trg.h5 # List of expect files that will be copied over to local test dir LIST_OTHER_TEST_FILES=" $SRC_H5COPY_OUTFILES/h5copy_misc1.out -$SRC_H5COPY_OUTFILES/h5copy_misc1.err $SRC_H5COPY_OUTFILES/h5copy_help1.ddl $SRC_H5COPY_OUTFILES/h5copy_help2.ddl " @@ -79,6 +78,7 @@ CP='cp' DIRNAME='dirname' LS='ls' AWK='awk' +GREP='grep' nerrors=0 verbose=yes @@ -188,8 +188,8 @@ VERIFY_OUTPUT() TOOLTEST() { - actualout="$TESTDIR/tooltest.actualout" - actualerr="$TESTDIR/tooltest.actualerr" + actual="$TESTDIR/tooltest.actual" + actual_err="$TESTDIR/tooltest.actual_err" runh5diff=yes if [ "$1" = -i ]; then inputfile=$2 @@ -219,13 +219,13 @@ TOOLTEST() echo " output for '$H5COPY $@'" echo "#############################" $RUNSERIAL $H5COPY_BIN $@ - ) > $actualout 2> $actualerr + ) > $actual 2> $actual_err RET=$? if [ $RET != 0 ]; then echo "*FAILED*" echo "failed result is:" - cat $actualout + cat $actual nerrors="`expr $nerrors + 1`" else echo " PASSED" @@ -236,7 +236,7 @@ TOOLTEST() # Clean up output file if test -z "$HDF5_NOCLEANUP"; then - rm -f $actualout $actualerr $outputfile + rm -f $actual $actual_err $outputfile fi fi } @@ -244,8 +244,8 @@ TOOLTEST() # TOOLTEST back-to-back TOOLTEST_PREFILL() { - actualout="$TESTDIR/tooltest.actualout" - actualerr="$TESTDIR/tooltest.actualerr" + actual="$TESTDIR/tooltest.actual" + actual_err="$TESTDIR/tooltest.actual_err" runh5diff=yes if [ "$1" = -i ]; then inputfile=$2 @@ -269,13 +269,13 @@ TOOLTEST_PREFILL() echo " output for '$H5COPY $@'" echo "#############################" $RUNSERIAL $H5COPY_BIN -i $inputfile -o $outputfile -v -s $grp_name -d $grp_name2 - ) > $actualout 2> $actualerr + ) > $actual 2> $actual_err RET=$? if [ $RET != 0 ]; then echo "*FAILED*" echo "failed result is:" - cat $actualout + cat $actual nerrors="`expr $nerrors + 1`" else TESTING $H5COPY $@ @@ -284,13 +284,13 @@ TOOLTEST_PREFILL() echo " output for '$H5COPY $@'" echo "#############################" $RUNSERIAL $H5COPY_BIN -i $inputfile -o $outputfile -v -s $obj_name -d $obj_name2 - ) > $actualout 2> $actualerr + ) > $actual 2> $actual_err RET=$? if [ $RET != 0 ]; then echo "*FAILED*" echo "failed result is:" - cat $actualout + cat $actual nerrors="`expr $nerrors + 1`" else echo " PASSED" @@ -301,7 +301,7 @@ TOOLTEST_PREFILL() # Clean up output file if test -z "$HDF5_NOCLEANUP"; then - rm -f $actualout $actualerr $outputfile + rm -f $actual $actual_err $outputfile fi fi fi @@ -310,8 +310,8 @@ TOOLTEST_PREFILL() # TOOLTEST back-to-back TOOLTEST_SAME() { - actualout="$TESTDIR/tooltest.actualout" - actualerr="$TESTDIR/tooltest.actualerr" + actual="$TESTDIR/tooltest.actual" + actual_err="$TESTDIR/tooltest.actual_err" runh5diff=yes if [ "$1" = -i ]; then inputfile=$2 @@ -334,13 +334,13 @@ TOOLTEST_SAME() echo " output for '$H5COPY $@'" echo "#############################" $RUNSERIAL $H5COPY_BIN -i $inputfile -o $outputfile -v -s $grp_name -d $grp_name - ) > $actualout 2> $actualerr + ) > $actual 2> $actual_err RET=$? if [ $RET != 0 ]; then echo "*FAILED*" echo "failed result is:" - cat $actualout + cat $actual nerrors="`expr $nerrors + 1`" else TESTING $H5COPY $@ @@ -349,13 +349,13 @@ TOOLTEST_SAME() echo " output for '$H5COPY $@'" echo "#############################" $RUNSERIAL $H5COPY_BIN -i $outputfile -o $outputfile -v -s $grp_name -d $grp_name2 - ) > $actualout 2> $actualerr + ) > $actual 2> $actual_err RET=$? if [ $RET != 0 ]; then echo "*FAILED*" echo "failed result is:" - cat $actualout + cat $actual nerrors="`expr $nerrors + 1`" else echo " PASSED" @@ -366,50 +366,25 @@ TOOLTEST_SAME() # Clean up output file if test -z "$HDF5_NOCLEANUP"; then - rm -f $actualout $actualerr $outputfile + rm -f $actual $actual_err $outputfile fi fi fi } -# Compare the two text files -# PASS if same -# FAIL if different, and show the diff -# -# Assumed arguments: -# $1 is text file1 (expected output) -# $2 is text file2 (actual output) -CMP_OUTPUT() -{ - expect=$1 - actual=$2 - - VERIFY_OUTPUT $@ - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected output differs from actual output" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi -} - -TOOLTEST_FAIL() +# Call the h5copy tool and grep for a value +# txttype ERRTXT greps test error output, otherwise greps test output +GREPTEST() { - expectout="$TESTDIR/$1" - expecterr="$TESTDIR/`basename $1 .out`.err" - actualout="$TESTDIR/$1.actualout" - actualerr="$TESTDIR/$1.actualerr" - actualout_sav=${actualout}-sav - actualerr_sav=${actualerr}-sav + txttype=$1 + expectdata=$2 + expectout="$TESTDIR/$3" + expecterr="$TESTDIR/`basename $3 .out`.err" + actual="$TESTDIR/$3.actual" + actual_err="$TESTDIR/$3.actual_err" + shift + shift shift if [ "$1" = -i ]; then inputfile=$2 @@ -419,41 +394,32 @@ TOOLTEST_FAIL() outputfile=$4 fi + # Run test. TESTING $H5COPY $@ ( - #echo "#############################" - #echo " output for '$H5COPY $@'" - #echo "#############################" $RUNSERIAL $H5COPY_BIN $@ - ) > $actualout 2> $actualerr + ) > $actual 2> $actual_err RET=$? - # save actualout and actualerr in case they are needed later. - cp $actualout $actualout_sav - STDOUT_FILTER $actualout - cp $actualerr $actualerr_sav - STDERR_FILTER $actualerr - if [ $RET != 0 ]; then + if [ "$txttype" = "ERRTXT" ]; then + $GREP "$expectdata" $actual_err > /dev/null + else + $GREP "$expectdata" $actual > /dev/null + fi + + if [ $? -eq 0 ]; then echo " PASSED" - # Verifying output text from h5copy - if [ "$expectout" != "SKIP" ]; then - CMP_OUTPUT $expecterr $actualerr - fi else - echo "*FAILED*" - echo "failed result is:" - cat $actualout + echo " FAILED" nerrors="`expr $nerrors + 1`" fi - # Clean up output file if test -z "$HDF5_NOCLEANUP"; then - rm -f $actualout $actualerr $actualout_sav $actualerr_sav $outputfile + rm -f $actual $actual_err fi } - # Call the h5diff tool # H5DIFFTEST() @@ -469,22 +435,6 @@ H5DIFFTEST() fi } -# Call the h5diff tool with a call that is expected to fail -# -H5DIFFTEST_FAIL() -{ - VERIFY $@ - $RUNSERIAL $H5DIFF_BIN -q "$@" - RET=$? - - if [ $h5haveexitcode = 'yes' -a $RET != 1 ] ; then - echo "*FAILED*" - nerrors="`expr $nerrors + 1`" - else - echo " PASSED" - fi -} - # ADD_HELP_TEST TOOLTEST_HELP() { @@ -630,7 +580,7 @@ TEST_MISC() TESTFILE="$TESTDIR/h5copytst.h5" echo "Test copying object into group which doesn't exist, without -p" - TOOLTEST_FAIL h5copy_misc1.out -i $TESTFILE -o $TESTDIR/h5copy_misc1.out.h5 -v -s /simple -d /g1/g2/simple + GREPTEST ERRTXT "h5copy error" h5copy_misc1.out -i $TESTFILE -o $TESTDIR/h5copy_misc1.out.h5 -v -s /simple -d /g1/g2/simple echo "Test copying objects to the same file " TOOLTEST_SAME -i $TESTFILE -o $TESTDIR/samefile1.out.h5 /simple /simple_cp diff --git a/tools/test/h5diff/expected/dangling_link.err b/tools/test/h5diff/expected/dangling_link.err deleted file mode 100644 index 82802a1f23e..00000000000 --- a/tools/test/h5diff/expected/dangling_link.err +++ /dev/null @@ -1,4 +0,0 @@ -H5tools-DIAG: Error detected in HDF5:tools (version (number)) thread (IDs): - #000: (file name) line (number) in h5diff(): treat dangling link as error - major: Failure in tools library - minor: error in function diff --git a/tools/test/h5diff/expected/h5diff_601_ERR.err b/tools/test/h5diff/expected/h5diff_601_ERR.err deleted file mode 100644 index f9a7212dbd2..00000000000 --- a/tools/test/h5diff/expected/h5diff_601_ERR.err +++ /dev/null @@ -1,4 +0,0 @@ -H5tools-DIAG: Error detected in HDF5:tools (version (number)) thread (IDs): - #000: (file name) line (number) in h5diff(): Error: Object could not be found - major: Failure in tools library - minor: error in function diff --git a/tools/test/h5diff/expected/h5diff_udfail.err b/tools/test/h5diff/expected/h5diff_udfail.err deleted file mode 100644 index d51de38833a..00000000000 --- a/tools/test/h5diff/expected/h5diff_udfail.err +++ /dev/null @@ -1,12 +0,0 @@ - -file1 file2 ---------------------------------------- - x x / - x x /dynlibud - -group : and -0 differences found -dataset: and -0 differences found -Warning: dataset cannot be read, user defined filter is not available -EXIT CODE: 2 diff --git a/tools/test/h5diff/h5diff_plugin.sh.in b/tools/test/h5diff/h5diff_plugin.sh.in index f6783af8ff9..98ccf639d8c 100644 --- a/tools/test/h5diff/h5diff_plugin.sh.in +++ b/tools/test/h5diff/h5diff_plugin.sh.in @@ -63,7 +63,6 @@ LIST_HDF5_TEST_FILES=" $SRC_H5DIFF_TESTFILES/tudfilter.h5 $SRC_H5DIFF_TESTFILES/tudfilter2.h5 $SRC_H5DIFF_OUTFILES/h5diff_ud.txt -$SRC_H5DIFF_OUTFILES/h5diff_udfail.err $SRC_H5DIFF_OUTFILES/h5diff_udfail.txt " @@ -293,93 +292,6 @@ TOOLTEST() { rm -f $actual_sorted $expect_sorted fi } -# Same as TOOLSET except only err file checked -TOOLTEST_ERR() { - expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .txt`.err" - actual="$TESTDIR/`basename $1 .txt`.out" - actual_err="$TESTDIR/`basename $1 .txt`.out.err" - actual_sav=${actual}-sav - actual_err_sav=${actual_err}-sav - shift - if test -n "$pmode"; then - RUNCMD=$RUNPARALLEL - else - RUNCMD=$RUNSERIAL - fi - - # Run test. - TESTING $H5DIFF $@ - ( - #echo "#############################" - #echo "Expected output for '$H5DIFF $@'" - #echo "#############################" - cd $TESTDIR - eval $ENVCMD $RUNCMD $H5DIFF_BIN "$@" - ) >$actual 2>$actual_err - EXIT_CODE=$? - - # 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 - - # don't add exit code check in pmode, as it causes failure. (exit code - # is from mpirun not tool) - # if any problem occurs relate to an exit code, it will be caught in - # serial mode, so the test is fulfilled. - if test $h5haveexitcode = 'yes' -a -z "$pmode"; then - echo "EXIT CODE: $EXIT_CODE" >> $actual - fi - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect_err $actual_err; then - echo " PASSED" - elif test $h5haveexitcode = 'yes' -a -z "$pmode"; then - echo "*FAILED*" - echo " Expected result ($expect_err) differs from actual result ($actual_err)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect_err $actual_err |sed 's/^/ /' - else - # parallel mode output are often of different ordering from serial - # output. If the sorted expect_err and actual_err files compare the same, - # it is safe to assume the actual output match the expected file. - expect_sorted=expect_sorted - actual_sorted=actual_sorted - sort $expect_err -o $expect_sorted - sort $actual_err -o $actual_sorted - mv $expect_sorted.noexit $expect_sorted - - if $CMP $expect_sorted $actual_sorted; then - echo " PASSED" - else - echo "*FAILED*" - nerrors="`expr $nerrors + 1`" - if test yes = "$verbose"; then - echo "====Expected result ($expect_sorted) differs from actual result ($actual_sorted)" - $DIFF $expect_sorted $actual_sorted |sed 's/^/ /' - echo "====The actual output ($actual_sav)" - sed 's/^/ /' < $actual_sav - echo "====The actual stderr ($actual_err_sav)" - sed 's/^/ /' < $actual_err_sav - echo "====End of actual stderr ($actual_err_sav)" - echo "" - fi - fi - fi - - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav - rm -f $actual_sorted $expect_sorted - fi -} ############################################################################## ### T H E T E S T S diff --git a/tools/test/h5diff/testh5diff.sh.in b/tools/test/h5diff/testh5diff.sh.in index 1378f07cf34..2cde4571982 100644 --- a/tools/test/h5diff/testh5diff.sh.in +++ b/tools/test/h5diff/testh5diff.sh.in @@ -234,7 +234,6 @@ $SRC_H5DIFF_OUTFILES/h5diff_451.txt $SRC_H5DIFF_OUTFILES/h5diff_452.txt $SRC_H5DIFF_OUTFILES/h5diff_453.txt $SRC_H5DIFF_OUTFILES/h5diff_454.txt -$SRC_H5DIFF_OUTFILES/dangling_link.err $SRC_H5DIFF_OUTFILES/h5diff_455.txt $SRC_H5DIFF_OUTFILES/h5diff_456.txt $SRC_H5DIFF_OUTFILES/h5diff_457.txt @@ -296,7 +295,6 @@ $SRC_H5DIFF_OUTFILES/h5diff_62.txt $SRC_H5DIFF_OUTFILES/h5diff_63.txt $SRC_H5DIFF_OUTFILES/h5diff_600.txt $SRC_H5DIFF_OUTFILES/h5diff_601.txt -$SRC_H5DIFF_OUTFILES/h5diff_601_ERR.err $SRC_H5DIFF_OUTFILES/h5diff_603.txt $SRC_H5DIFF_OUTFILES/h5diff_604.txt $SRC_H5DIFF_OUTFILES/h5diff_605.txt @@ -364,7 +362,7 @@ $SRC_H5DIFF_OUTFILES/h5diff_eps.txt # # copy test files and expected output files from source dirs to test dir # -COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_HDF5_VDS_TEST_FILES $LIST_HDF5_STD_REF_OBJ_TEST_FILES $LIST_OTHER_TEST_FILES $LIST_HDF5_TEST_FILES_XML $LIST_OTHER_TEST_FILES_XML" +COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_HDF5_VDS_TEST_FILES $LIST_HDF5_STD_REF_OBJ_TEST_FILES $LIST_OTHER_TEST_FILES" COPY_TESTFILES_TO_TESTDIR() { @@ -481,7 +479,6 @@ TESTING() { # TOOLTEST() { expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .txt`.err" actual="$TESTDIR/`basename $1 .txt`.out" actual_err="$TESTDIR/`basename $1 .txt`.out.err" actual_sav=${actual}-sav diff --git a/tools/test/h5dump/CMakeTestsVDS.cmake b/tools/test/h5dump/CMakeTestsVDS.cmake index d1dc5411a28..12cf07b4a37 100644 --- a/tools/test/h5dump/CMakeTestsVDS.cmake +++ b/tools/test/h5dump/CMakeTestsVDS.cmake @@ -80,8 +80,6 @@ vds-percival-unlim-maxmin.h5 vds-eiger.h5 ) - set (HDF5_ERROR_REFERENCE_VDS - ) foreach (vds_h5_file ${HDF5_REFERENCE_TEST_VDS}) HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/testfiles/vds/${vds_h5_file}" "${PROJECT_BINARY_DIR}/testfiles/vds/${vds_h5_file}" "h5dump_vds_files") @@ -95,9 +93,6 @@ HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/expected/vds/${ddl_vds}" "${PROJECT_BINARY_DIR}/testfiles/vds/prefix/${ddl_vds}" "h5dump_vds_files") endforeach () - foreach (ddl_vds ${HDF5_ERROR_REFERENCE_VDS}) - HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/errfiles/${ddl_vds}" "${PROJECT_BINARY_DIR}/testfiles/vds/${ddl_vds}" "h5dump_vds_files") - endforeach () add_custom_target(h5dump_vds_files ALL COMMENT "Copying files needed by h5dump_vds tests" DEPENDS ${h5dump_vds_files_list}) ############################################################################## diff --git a/tools/test/h5dump/errfiles/filter_fail.err b/tools/test/h5dump/errfiles/filter_fail.err deleted file mode 100644 index 07b0aa02193..00000000000 --- a/tools/test/h5dump/errfiles/filter_fail.err +++ /dev/null @@ -1,33 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)) thread (IDs): - #000: (file name) line (number) in H5Dread(): can't read data - major: Dataset - minor: Read failed - #001: (file name) line (number) in H5VL_dataset_read(): dataset read failed - major: Virtual Object Layer - minor: Read failed - #002: (file name) line (number) in H5VL__dataset_read(): dataset read failed - major: Virtual Object Layer - minor: Read failed - #003: (file name) line (number) in H5VL__native_dataset_read(): can't read data - major: Dataset - minor: Read failed - #004: (file name) line (number) in H5D__read(): can't read data - major: Dataset - minor: Read failed - #005: (file name) line (number) in H5D__chunk_read(): unable to read raw data chunk - major: Low-level I/O - minor: Read failed - #006: (file name) line (number) in H5D__chunk_lock(): data pipeline read failed - major: Dataset - minor: Filter operation failed - #007: (file name) line (number) in H5Z_pipeline(): required filter 'filter_fail_test' is not registered - major: Data filters - minor: Read failed - #008: (file name) line (number) in H5PL_load(): filter plugins disabled - major: Plugin for dynamically loaded library - minor: Unable to load metadata into cache -h5dump error: unable to print data -H5tools-DIAG: Error detected in HDF5:tools (version (number)) thread (IDs): - #000: (file name) line (number) in h5tools_dump_simple_dset(): H5Dread failed - major: Failure in tools library - minor: error in function diff --git a/tools/test/h5dump/errfiles/infinite_loop.err b/tools/test/h5dump/errfiles/infinite_loop.err deleted file mode 100644 index c89e1551d3b..00000000000 --- a/tools/test/h5dump/errfiles/infinite_loop.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: unable to open file "3790_infinite_loop.h5" diff --git a/tools/test/h5dump/errfiles/non_existing.err b/tools/test/h5dump/errfiles/non_existing.err deleted file mode 100644 index f7e3afa4f68..00000000000 --- a/tools/test/h5dump/errfiles/non_existing.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: unable to open file "non_existing.h5" diff --git a/tools/test/h5dump/errfiles/pbits/tnofilename-with-packed-bits.err b/tools/test/h5dump/errfiles/pbits/tnofilename-with-packed-bits.err deleted file mode 100644 index 84a701100a6..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tnofilename-with-packed-bits.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: missing file name diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsCharLengthExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsCharLengthExceeded.err deleted file mode 100644 index e5854ea23df..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsCharLengthExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset+length value(9) too large. Max is 8 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsCharOffsetExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsCharOffsetExceeded.err deleted file mode 100644 index e5854ea23df..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsCharOffsetExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset+length value(9) too large. Max is 8 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsIncomplete.err b/tools/test/h5dump/errfiles/pbits/tpbitsIncomplete.err deleted file mode 100644 index e0abee535be..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsIncomplete.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Bad mask list(0,2,2,1,0,2,2,) diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsIntLengthExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsIntLengthExceeded.err deleted file mode 100644 index 7dd88edce5d..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsIntLengthExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset+length value(17) too large. Max is 16 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsIntOffsetExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsIntOffsetExceeded.err deleted file mode 100644 index 7dd88edce5d..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsIntOffsetExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset+length value(17) too large. Max is 16 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsLengthExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsLengthExceeded.err deleted file mode 100644 index d4673f25dde..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsLengthExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset+length value(65) too large. Max is 64 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsLengthPositive.err b/tools/test/h5dump/errfiles/pbits/tpbitsLengthPositive.err deleted file mode 100644 index 49280074802..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsLengthPositive.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit length value(0) must be positive. diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsLongLengthExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsLongLengthExceeded.err deleted file mode 100644 index 0318f79c977..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsLongLengthExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset+length value(33) too large. Max is 32 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsLongOffsetExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsLongOffsetExceeded.err deleted file mode 100644 index 0318f79c977..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsLongOffsetExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset+length value(33) too large. Max is 32 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsMaxExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsMaxExceeded.err deleted file mode 100644 index a8d12fc180b..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsMaxExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Too many masks requested (max. 8). Mask list(0,1,0,1,1,1,2,1,3,1,4,1,5,1,6,1,7,1) diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsOffsetExceeded.err b/tools/test/h5dump/errfiles/pbits/tpbitsOffsetExceeded.err deleted file mode 100644 index b7d6dad259d..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsOffsetExceeded.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Packed Bit offset value(64) must be between 0 and 63 diff --git a/tools/test/h5dump/errfiles/pbits/tpbitsOffsetNegative.err b/tools/test/h5dump/errfiles/pbits/tpbitsOffsetNegative.err deleted file mode 100644 index 8a027c18545..00000000000 --- a/tools/test/h5dump/errfiles/pbits/tpbitsOffsetNegative.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: Bad mask list(-1,1) diff --git a/tools/test/h5dump/errfiles/tall-1.err b/tools/test/h5dump/errfiles/tall-1.err deleted file mode 100644 index 74ccb51f21a..00000000000 --- a/tools/test/h5dump/errfiles/tall-1.err +++ /dev/null @@ -1,37 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'somefile' - major: Links - minor: Unable to open file diff --git a/tools/test/h5dump/errfiles/tall-2A.err b/tools/test/h5dump/errfiles/tall-2A.err deleted file mode 100644 index 74ccb51f21a..00000000000 --- a/tools/test/h5dump/errfiles/tall-2A.err +++ /dev/null @@ -1,37 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'somefile' - major: Links - minor: Unable to open file diff --git a/tools/test/h5dump/errfiles/tall-2A0.err b/tools/test/h5dump/errfiles/tall-2A0.err deleted file mode 100644 index 74ccb51f21a..00000000000 --- a/tools/test/h5dump/errfiles/tall-2A0.err +++ /dev/null @@ -1,37 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'somefile' - major: Links - minor: Unable to open file diff --git a/tools/test/h5dump/errfiles/tall-2B.err b/tools/test/h5dump/errfiles/tall-2B.err deleted file mode 100644 index 74ccb51f21a..00000000000 --- a/tools/test/h5dump/errfiles/tall-2B.err +++ /dev/null @@ -1,37 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'somefile' - major: Links - minor: Unable to open file diff --git a/tools/test/h5dump/errfiles/tarray1_big.err b/tools/test/h5dump/errfiles/tarray1_big.err deleted file mode 100644 index dd6e1b40860..00000000000 --- a/tools/test/h5dump/errfiles/tarray1_big.err +++ /dev/null @@ -1,31 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Rget_obj_type3(): unable to get object token - major: References - minor: Can't get value - #001: (file name) line (number) in H5R__get_obj_token(): NULL token size - major: References - minor: Unable to copy object -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Rget_obj_type3(): unable to get object token - major: References - minor: Can't get value - #001: (file name) line (number) in H5R__get_obj_token(): NULL token size - major: References - minor: Unable to copy object -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Rget_obj_type3(): unable to get object token - major: References - minor: Can't get value - #001: (file name) line (number) in H5R__get_obj_token(): NULL token size - major: References - minor: Unable to copy object -H5tools-DIAG: Error detected in HDF5:tools (version (number)): - #000: (file name) line (number) in h5tools_dump_data(): H5Rget_obj_type3 H5R_OBJECT1 failed - major: Failure in tools library - minor: error in function - #001: (file name) line (number) in h5tools_dump_data(): H5Rget_obj_type3 H5R_OBJECT1 failed - major: Failure in tools library - minor: error in function - #002: (file name) line (number) in h5tools_dump_data(): H5Rget_obj_type3 H5R_OBJECT1 failed - major: Failure in tools library - minor: error in function diff --git a/tools/test/h5dump/errfiles/tattr-3.err b/tools/test/h5dump/errfiles/tattr-3.err deleted file mode 100644 index 86db5943f3c..00000000000 --- a/tools/test/h5dump/errfiles/tattr-3.err +++ /dev/null @@ -1,26 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Aopen(): unable to synchronously open attribute - major: Attribute - minor: Unable to create file - #001: (file name) line (number) in H5A__open_api_common(): unable to open attribute: 'attr' - major: Attribute - minor: Can't open object - #002: (file name) line (number) in H5A__open_common(): unable to open attribute: 'attr' - major: Attribute - minor: Can't open object - #003: (file name) line (number) in H5VL_attr_open(): attribute open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__attr_open(): attribute open failed - major: Virtual Object Layer - minor: Can't open object - #005: (file name) line (number) in H5VL__native_attr_open(): unable to open attribute: 'attr' - major: Attribute - minor: Can't open object - #006: (file name) line (number) in H5A__open(): unable to load attribute info from object header for attribute: 'attr' - major: Attribute - minor: Can't open object - #007: (file name) line (number) in H5O__attr_open_by_name(): can't locate attribute: 'attr' - major: Attribute - minor: Object not found -h5dump error: unable to open attribute "attr" diff --git a/tools/test/h5dump/errfiles/tattrregR.err b/tools/test/h5dump/errfiles/tattrregR.err deleted file mode 100644 index 0f4a88eb117..00000000000 --- a/tools/test/h5dump/errfiles/tattrregR.err +++ /dev/null @@ -1,21 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Rget_obj_type3(): unable to get object token - major: References - minor: Can't get value - #001: (file name) line (number) in H5R__get_obj_token(): NULL token size - major: References - minor: Unable to copy object -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Rget_obj_type3(): unable to get object token - major: References - minor: Can't get value - #001: (file name) line (number) in H5R__get_obj_token(): NULL token size - major: References - minor: Unable to copy object -H5tools-DIAG: Error detected in HDF5:tools (version (number)): - #000: (file name) line (number) in h5tools_dump_data(): H5Rget_obj_type3 H5R_OBJECT1 failed - major: Failure in tools library - minor: error in function - #001: (file name) line (number) in h5tools_dump_data(): H5Rget_obj_type3 H5R_OBJECT1 failed - major: Failure in tools library - minor: error in function diff --git a/tools/test/h5dump/errfiles/tcomp-3.err b/tools/test/h5dump/errfiles/tcomp-3.err deleted file mode 100644 index 8d8c9ee373c..00000000000 --- a/tools/test/h5dump/errfiles/tcomp-3.err +++ /dev/null @@ -1,31 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Topen2(): unable to open named datatype synchronously - major: Datatype - minor: Can't open object - #001: (file name) line (number) in H5T__open_api_common(): unable to open named datatype - major: Datatype - minor: Can't open object - #002: (file name) line (number) in H5VL_datatype_open(): datatype open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__datatype_open(): datatype open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_datatype_open(): unable to open named datatype - major: Datatype - minor: Can't open object - #005: (file name) line (number) in H5T__open_name(): not found - major: Datatype - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #009: (file name) line (number) in H5G__loc_find_cb(): object '#6632' doesn't exist - major: Symbol table - minor: Object not found diff --git a/tools/test/h5dump/errfiles/tdataregR.err b/tools/test/h5dump/errfiles/tdataregR.err deleted file mode 100644 index 0f4a88eb117..00000000000 --- a/tools/test/h5dump/errfiles/tdataregR.err +++ /dev/null @@ -1,21 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Rget_obj_type3(): unable to get object token - major: References - minor: Can't get value - #001: (file name) line (number) in H5R__get_obj_token(): NULL token size - major: References - minor: Unable to copy object -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Rget_obj_type3(): unable to get object token - major: References - minor: Can't get value - #001: (file name) line (number) in H5R__get_obj_token(): NULL token size - major: References - minor: Unable to copy object -H5tools-DIAG: Error detected in HDF5:tools (version (number)): - #000: (file name) line (number) in h5tools_dump_data(): H5Rget_obj_type3 H5R_OBJECT1 failed - major: Failure in tools library - minor: error in function - #001: (file name) line (number) in h5tools_dump_data(): H5Rget_obj_type3 H5R_OBJECT1 failed - major: Failure in tools library - minor: error in function diff --git a/tools/test/h5dump/errfiles/tdset-2.err b/tools/test/h5dump/errfiles/tdset-2.err deleted file mode 100644 index 07080d229d6..00000000000 --- a/tools/test/h5dump/errfiles/tdset-2.err +++ /dev/null @@ -1,57 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Dopen2(): unable to synchronously open dataset - major: Dataset - minor: Can't open object - #001: (file name) line (number) in H5D__open_api_common(): unable to open dataset - major: Dataset - minor: Can't open object - #002: (file name) line (number) in H5VL_dataset_open(): dataset open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__dataset_open(): dataset open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_dataset_open(): unable to open dataset - major: Dataset - minor: Can't open object - #005: (file name) line (number) in H5D__open_name(): not found - major: Dataset - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #009: (file name) line (number) in H5G__loc_find_cb(): object 'dset3' doesn't exist - major: Symbol table - minor: Object not found -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Lget_info2(): unable to get link info - major: Links - minor: Can't get value - #001: (file name) line (number) in H5VL_link_get(): link get failed - major: Virtual Object Layer - minor: Can't get value - #002: (file name) line (number) in H5VL__link_get(): link get failed - major: Virtual Object Layer - minor: Can't get value - #003: (file name) line (number) in H5VL__native_link_get(): unable to get link info - major: Links - minor: Object not found - #004: (file name) line (number) in H5L_get_info(): name doesn't exist - major: Links - minor: Object already exists - #005: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #006: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #007: (file name) line (number) in H5L__get_info_cb(): name doesn't exist - major: Links - minor: Object not found -h5dump error: unable to get link info from "dset3" diff --git a/tools/test/h5dump/errfiles/texceedsubblock.err b/tools/test/h5dump/errfiles/texceedsubblock.err deleted file mode 100644 index 4c87ab90f38..00000000000 --- a/tools/test/h5dump/errfiles/texceedsubblock.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: number of block dims (2) exceed dataset dims (1) diff --git a/tools/test/h5dump/errfiles/texceedsubcount.err b/tools/test/h5dump/errfiles/texceedsubcount.err deleted file mode 100644 index de1c9d1874e..00000000000 --- a/tools/test/h5dump/errfiles/texceedsubcount.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: number of count dims (2) exceed dataset dims (1) diff --git a/tools/test/h5dump/errfiles/texceedsubstart.err b/tools/test/h5dump/errfiles/texceedsubstart.err deleted file mode 100644 index 4555224a0f9..00000000000 --- a/tools/test/h5dump/errfiles/texceedsubstart.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: number of start dims (2) exceed dataset dims (1) diff --git a/tools/test/h5dump/errfiles/texceedsubstride.err b/tools/test/h5dump/errfiles/texceedsubstride.err deleted file mode 100644 index 32d57253879..00000000000 --- a/tools/test/h5dump/errfiles/texceedsubstride.err +++ /dev/null @@ -1 +0,0 @@ -h5dump error: number of stride dims (2) exceed dataset dims (1) diff --git a/tools/test/h5dump/errfiles/textlink.err b/tools/test/h5dump/errfiles/textlink.err deleted file mode 100644 index bad1dd32d62..00000000000 --- a/tools/test/h5dump/errfiles/textlink.err +++ /dev/null @@ -1,74 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'filename' - major: Links - minor: Unable to open file -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'anotherfile' - major: Links - minor: Unable to open file diff --git a/tools/test/h5dump/errfiles/textlinkfar.err b/tools/test/h5dump/errfiles/textlinkfar.err deleted file mode 100644 index cfa2ef970c6..00000000000 --- a/tools/test/h5dump/errfiles/textlinkfar.err +++ /dev/null @@ -1,255 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #012: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #013: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #014: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #015: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #016: (file name) line (number) in H5G__traverse_special(): symbolic link traversal failed - major: Links - minor: Link traversal failure - #017: (file name) line (number) in H5G__traverse_slink(): unable to follow symbolic link - major: Symbol table - minor: Object not found - #018: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #019: (file name) line (number) in H5G__traverse_slink_cb(): component not found - major: Symbol table - minor: Object not found -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #001: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #002: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #003: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #004: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #005: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #006: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #007: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #009: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #011: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #012: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #013: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #014: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #015: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #016: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #017: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #018: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #019: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #020: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #021: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #022: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #023: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #024: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #025: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #026: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #027: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #028: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #029: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #030: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #031: (file name) line (number) in H5G__traverse_special(): too many links - major: Links - minor: Too many soft links in path -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #001: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #002: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #003: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #004: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #005: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #006: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #007: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #009: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #011: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #012: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #013: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #014: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #015: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #016: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #017: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #018: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #019: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #020: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #021: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #022: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #023: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #024: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #025: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #026: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #027: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #028: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #029: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #030: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #031: (file name) line (number) in H5G__traverse_special(): too many links - major: Links - minor: Too many soft links in path diff --git a/tools/test/h5dump/errfiles/textlinksrc.err b/tools/test/h5dump/errfiles/textlinksrc.err deleted file mode 100644 index cfa2ef970c6..00000000000 --- a/tools/test/h5dump/errfiles/textlinksrc.err +++ /dev/null @@ -1,255 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #012: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #013: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #014: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #015: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #016: (file name) line (number) in H5G__traverse_special(): symbolic link traversal failed - major: Links - minor: Link traversal failure - #017: (file name) line (number) in H5G__traverse_slink(): unable to follow symbolic link - major: Symbol table - minor: Object not found - #018: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #019: (file name) line (number) in H5G__traverse_slink_cb(): component not found - major: Symbol table - minor: Object not found -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #001: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #002: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #003: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #004: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #005: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #006: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #007: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #009: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #011: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #012: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #013: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #014: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #015: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #016: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #017: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #018: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #019: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #020: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #021: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #022: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #023: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #024: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #025: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #026: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #027: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #028: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #029: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #030: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #031: (file name) line (number) in H5G__traverse_special(): too many links - major: Links - minor: Too many soft links in path -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #001: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #002: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #003: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #004: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #005: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #006: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #007: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #009: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #011: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #012: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #013: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #014: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #015: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #016: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #017: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #018: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #019: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #020: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #021: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #022: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #023: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #024: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #025: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #026: (file name) line (number) in H5L__extern_traverse(): unable to open object - major: Links - minor: Can't open object - #027: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #028: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #029: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #030: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #031: (file name) line (number) in H5G__traverse_special(): too many links - major: Links - minor: Too many soft links in path diff --git a/tools/test/h5dump/errfiles/tgroup-2.err b/tools/test/h5dump/errfiles/tgroup-2.err deleted file mode 100644 index 518bc695e06..00000000000 --- a/tools/test/h5dump/errfiles/tgroup-2.err +++ /dev/null @@ -1,32 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Gopen2(): unable to synchronously open group - major: Symbol table - minor: Unable to create file - #001: (file name) line (number) in H5G__open_api_common(): unable to open group - major: Symbol table - minor: Can't open object - #002: (file name) line (number) in H5VL_group_open(): group open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__group_open(): group open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_group_open(): unable to open group - major: Symbol table - minor: Can't open object - #005: (file name) line (number) in H5G__open_name(): group not found - major: Symbol table - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #009: (file name) line (number) in H5G__loc_find_cb(): object 'y' doesn't exist - major: Symbol table - minor: Object not found -h5dump error: unable to open group "/y" diff --git a/tools/test/h5dump/errfiles/torderlinks1.err b/tools/test/h5dump/errfiles/torderlinks1.err deleted file mode 100644 index d715aa158b1..00000000000 --- a/tools/test/h5dump/errfiles/torderlinks1.err +++ /dev/null @@ -1,37 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'fname' - major: Links - minor: Unable to open file diff --git a/tools/test/h5dump/errfiles/torderlinks2.err b/tools/test/h5dump/errfiles/torderlinks2.err deleted file mode 100644 index d715aa158b1..00000000000 --- a/tools/test/h5dump/errfiles/torderlinks2.err +++ /dev/null @@ -1,37 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Oopen(): unable to synchronously open object - major: Object header - minor: Can't open object - #001: (file name) line (number) in H5O__open_api_common(): unable to open object - major: Object header - minor: Can't open object - #002: (file name) line (number) in H5VL_object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__object_open(): object open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_object_open(): unable to open object by name - major: Object header - minor: Can't open object - #005: (file name) line (number) in H5O_open_name(): object not found - major: Object header - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): user-defined link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_ud(): traversal callback returned invalid ID - major: Symbol table - minor: Unable to find ID information (already closed?) - #011: (file name) line (number) in H5L__extern_traverse(): unable to open external file, external link file name = 'fname' - major: Links - minor: Unable to open file diff --git a/tools/test/h5dump/errfiles/tperror.err b/tools/test/h5dump/errfiles/tperror.err deleted file mode 100644 index 83757923dbb..00000000000 --- a/tools/test/h5dump/errfiles/tperror.err +++ /dev/null @@ -1,57 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Dopen2(): unable to synchronously open dataset - major: Dataset - minor: Can't open object - #001: (file name) line (number) in H5D__open_api_common(): unable to open dataset - major: Dataset - minor: Can't open object - #002: (file name) line (number) in H5VL_dataset_open(): dataset open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__dataset_open(): dataset open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_dataset_open(): unable to open dataset - major: Dataset - minor: Can't open object - #005: (file name) line (number) in H5D__open_name(): not found - major: Dataset - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #009: (file name) line (number) in H5G__loc_find_cb(): object 'bogus' doesn't exist - major: Symbol table - minor: Object not found -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Lget_info2(): unable to get link info - major: Links - minor: Can't get value - #001: (file name) line (number) in H5VL_link_get(): link get failed - major: Virtual Object Layer - minor: Can't get value - #002: (file name) line (number) in H5VL__link_get(): link get failed - major: Virtual Object Layer - minor: Can't get value - #003: (file name) line (number) in H5VL__native_link_get(): unable to get link info - major: Links - minor: Object not found - #004: (file name) line (number) in H5L_get_info(): name doesn't exist - major: Links - minor: Object already exists - #005: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #006: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #007: (file name) line (number) in H5L__get_info_cb(): name doesn't exist - major: Links - minor: Object not found -h5dump error: unable to get link info from "bogus" diff --git a/tools/test/h5dump/errfiles/tqmarkfile.err b/tools/test/h5dump/errfiles/tqmarkfile.err deleted file mode 100644 index aef14cb6d4b..00000000000 --- a/tools/test/h5dump/errfiles/tqmarkfile.err +++ /dev/null @@ -1,33 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Dopen2(): not found - major: Dataset - minor: Object not found - #001: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #002: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #003: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #004: (file name) line (number) in H5G_loc_find_cb(): object 'Dataset1' doesn't exist - major: Symbol table - minor: Object not found -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Lget_info2(): unable to get link info - major: Symbol table - minor: Object not found - #001: (file name) line (number) in H5L_get_info(): name doesn't exist - major: Symbol table - minor: Object already exists - #002: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #003: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #004: (file name) line (number) in H5L_get_info_cb(): name doesn't exist - major: Symbol table - minor: Object not found -h5dump error: unable to get link info from "Dataset1" diff --git a/tools/test/h5dump/errfiles/tslink-D.err b/tools/test/h5dump/errfiles/tslink-D.err deleted file mode 100644 index 1c5cc23e8fb..00000000000 --- a/tools/test/h5dump/errfiles/tslink-D.err +++ /dev/null @@ -1,40 +0,0 @@ -HDF5-DIAG: Error detected in HDF5 (version (number)): - #000: (file name) line (number) in H5Dopen2(): unable to synchronously open dataset - major: Dataset - minor: Can't open object - #001: (file name) line (number) in H5D__open_api_common(): unable to open dataset - major: Dataset - minor: Can't open object - #002: (file name) line (number) in H5VL_dataset_open(): dataset open failed - major: Virtual Object Layer - minor: Can't open object - #003: (file name) line (number) in H5VL__dataset_open(): dataset open failed - major: Virtual Object Layer - minor: Can't open object - #004: (file name) line (number) in H5VL__native_dataset_open(): unable to open dataset - major: Dataset - minor: Can't open object - #005: (file name) line (number) in H5D__open_name(): not found - major: Dataset - minor: Object not found - #006: (file name) line (number) in H5G_loc_find(): can't find object - major: Symbol table - minor: Object not found - #007: (file name) line (number) in H5G_traverse(): internal path traversal failed - major: Symbol table - minor: Object not found - #008: (file name) line (number) in H5G__traverse_real(): special link traversal failed - major: Links - minor: Link traversal failure - #009: (file name) line (number) in H5G__traverse_special(): symbolic link traversal failed - major: Links - minor: Link traversal failure - #010: (file name) line (number) in H5G__traverse_slink(): unable to follow symbolic link - major: Symbol table - minor: Object not found - #011: (file name) line (number) in H5G__traverse_real(): traversal operator failed - major: Symbol table - minor: Callback failed - #012: (file name) line (number) in H5G__traverse_slink_cb(): component not found - major: Symbol table - minor: Object not found diff --git a/tools/test/h5dump/testh5dump.sh.in b/tools/test/h5dump/testh5dump.sh.in index 007f93c07e3..efada14934f 100644 --- a/tools/test/h5dump/testh5dump.sh.in +++ b/tools/test/h5dump/testh5dump.sh.in @@ -56,7 +56,6 @@ SRC_TOOLS="$srcdir/../.." SRC_H5LS_TESTFILES="$SRC_TOOLS/test/h5ls/testfiles" SRC_H5DUMP_TESTFILES="$SRC_TOOLS/test/h5dump/testfiles" SRC_H5DUMP_OUTFILES="$SRC_TOOLS/test/h5dump/expected" -SRC_H5DUMP_ERRORFILES="$SRC_TOOLS/test/h5dump/errfiles" SRC_H5DUMP_EXPFILES="$SRC_TOOLS/test/h5dump/exportfiles" SRC_H5DIFF_TESTFILES="$SRC_TOOLS/test/h5diff/testfiles" SRC_H5COPY_TESTFILES="$SRC_TOOLS/test/h5copy/testfiles" @@ -394,39 +393,10 @@ $SRC_H5DUMP_EXPFILES/twithddl.exp $SRC_H5DUMP_EXPFILES/twithddlfile.exp " -LIST_ERROR_TEST_FILES=" -${SRC_H5DUMP_ERRORFILES}/filter_fail.err -${SRC_H5DUMP_ERRORFILES}/non_existing.err -${SRC_H5DUMP_ERRORFILES}/infinite_loop.err -${SRC_H5DUMP_ERRORFILES}/tall-1.err -${SRC_H5DUMP_ERRORFILES}/tall-2A.err -${SRC_H5DUMP_ERRORFILES}/tall-2A0.err -${SRC_H5DUMP_ERRORFILES}/tall-2B.err -${SRC_H5DUMP_ERRORFILES}/tarray1_big.err -${SRC_H5DUMP_ERRORFILES}/tattr-3.err -${SRC_H5DUMP_ERRORFILES}/tattrregR.err -${SRC_H5DUMP_ERRORFILES}/tcomp-3.err -${SRC_H5DUMP_ERRORFILES}/tdataregR.err -${SRC_H5DUMP_ERRORFILES}/tdset-2.err -${SRC_H5DUMP_ERRORFILES}/texceedsubblock.err -${SRC_H5DUMP_ERRORFILES}/texceedsubcount.err -${SRC_H5DUMP_ERRORFILES}/texceedsubstart.err -${SRC_H5DUMP_ERRORFILES}/texceedsubstride.err -${SRC_H5DUMP_ERRORFILES}/textlink.err -${SRC_H5DUMP_ERRORFILES}/textlinkfar.err -${SRC_H5DUMP_ERRORFILES}/textlinksrc.err -${SRC_H5DUMP_ERRORFILES}/tgroup-2.err -${SRC_H5DUMP_ERRORFILES}/torderlinks1.err -${SRC_H5DUMP_ERRORFILES}/torderlinks2.err -${SRC_H5DUMP_ERRORFILES}/tperror.err -${SRC_H5DUMP_ERRORFILES}/tqmarkfile.err -${SRC_H5DUMP_ERRORFILES}/tslink-D.err -" - # # copy test files and expected output files from source dirs to test dir # -COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_OTHER_TEST_FILES $LIST_EXPORT_TEST_FILES $LIST_ERROR_TEST_FILES" +COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_OTHER_TEST_FILES $LIST_EXPORT_TEST_FILES" COPY_TESTFILES_TO_TESTDIR() { @@ -822,136 +792,6 @@ TOOLTEST3() { test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' fi - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav - fi - -} - -# same as TOOLTEST3 but filters error stack output and compares to an error file -# Extract file name, line number, version and thread IDs because they may be different -# ADD_H5ERR_MASK_TEST -TOOLTEST4() { - - expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .ddl`.err" - actual="$TESTDIR/`basename $1 .ddl`.out" - actual_err="$TESTDIR/`basename $1 .ddl`.oerr" - actual_ext="$TESTDIR/`basename $1 .ddl`.ext" - actual_sav=${actual}-sav - actual_err_sav=${actual_err}-sav - shift - - # Run test. - TESTING $DUMPER $@ - ( - cd $TESTDIR - $ENVCMD $RUNSERIAL $DUMPER_BIN "$@" - ) >$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 - - # Extract file name, line number, version and thread IDs because they may be different - sed -e 's/ thread [0-9]*//' -e 's/: .*\.c /: (file name) /' \ - -e 's/line [0-9]*/line (number)/' \ - -e 's/v[1-9]*\.[0-9]*\./version (number)\./' \ - -e 's/[1-9]*\.[0-9]*\.[0-9]*[^)]*/version (number)/' \ - -e 's/H5Eget_auto[1-2]*/H5Eget_auto(1 or 2)/' \ - -e 's/H5Eset_auto[1-2]*/H5Eset_auto(1 or 2)/' \ - $actual_err > $actual_ext - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - if $CMP $expect_err $actual_ext; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected result (*.err) differs from actual result (*.oerr)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect_err $actual_ext |sed 's/^/ /' - fi - else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi - - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav - fi - -} - -# same as TOOLTEST4 but disables plugin filter loading -# silences extra error output on some platforms -# ADD_H5ERR_MASK_TEST -TOOLTEST5() { - - expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .ddl`.err" - actual="$TESTDIR/`basename $1 .ddl`.out" - actual_err="$TESTDIR/`basename $1 .ddl`.oerr" - actual_ext="$TESTDIR/`basename $1 .ddl`.ext" - actual_sav=${actual}-sav - actual_err_sav=${actual_err}-sav - shift - - # Run test. - TESTING $DUMPER $@ - ( - cd $TESTDIR - $ENVCMD $RUNSERIAL $DUMPER_BIN "$@" - ) >$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 - - # Extract file name, line number, version and thread IDs because they may be different - sed -e 's/ thread [0-9]*//' -e 's/: .*\.c /: (file name) /' \ - -e 's/line [0-9]*/line (number)/' \ - -e 's/v[1-9]*\.[0-9]*\./version (number)\./' \ - -e 's/[1-9]*\.[0-9]*\.[0-9]*[^)]*/version (number)/' \ - -e 's/H5Eget_auto[1-2]*/H5Eget_auto(1 or 2)/' \ - -e 's/H5Eset_auto[1-2]*/H5Eset_auto(1 or 2)/' \ - $actual_err > $actual_ext - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - if $CMP $expect_err $actual_ext; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected result (*.err) differs from actual result (*.oerr)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect_err $actual_ext |sed 's/^/ /' - fi - else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi - # Clean up output file if test -z "$HDF5_NOCLEANUP"; then rm -f $actual $actual_err $actual_sav $actual_err_sav @@ -1099,6 +939,54 @@ GREPTEST2() fi } +# Call the h5dump tool and grep for a value but also compares the ddl output +# txttype ERRTXT greps test error output, otherwise greps test output +GREPTEST3() +{ + txttype=$1 + expectdata=$2 + expect="$TESTDIR/$3" + actual="$TESTDIR/`basename $3 .txt`.out" + actual_err="$TESTDIR/`basename $3 .ddl`.oerr" + actual_ext="$TESTDIR/`basename $3 .ddl`.ext" + shift + shift + shift + + # Run test. + TESTING $DUMPER $@ + ( + cd $TESTDIR + $ENVCMD $RUNSERIAL $DUMPER_BIN "$@" + ) >$actual 2>$actual_err + + if [ "$txttype" = "ERRTXT" ]; then + if $CMP $expect $actual; then + echo " PASSED" + else + echo "*FAILED*" + echo " Expected result (*.ddl) differs from actual result (*.out)" + nerrors="`expr $nerrors + 1`" + test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' + fi + $GREP "$expectdata" $actual_err > /dev/null + else + $GREP "$expectdata" $actual > /dev/null + fi + + 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 $@ @@ -1212,12 +1100,12 @@ TOOLTEST tscalarstring.ddl --enable-error-stack tscalarstring.h5 # test for displaying groups TOOLTEST tgroup-1.ddl --enable-error-stack tgroup.h5 # test for displaying the selected groups -TOOLTEST4 tgroup-2.ddl --enable-error-stack --group=/g2 --group / -g /y tgroup.h5 +GREPTEST ERRTXT "h5dump error: unable to open group" tgroup-2.ddl --enable-error-stack --group=/g2 --group / -g /y tgroup.h5 # test for displaying simple space datasets TOOLTEST tdset-1.ddl --enable-error-stack tdset.h5 # test for displaying selected datasets -TOOLTEST4 tdset-2.ddl --enable-error-stack -H -d dset1 -d /dset2 --dataset=dset3 tdset.h5 +GREPTEST ERRTXT "h5dump error: unable to get link info from" tdset-2.ddl --enable-error-stack -H -d dset1 -d /dset2 --dataset=dset3 tdset.h5 # test for displaying attributes TOOLTEST tattr-1.ddl --enable-error-stack tattr.h5 @@ -1225,7 +1113,7 @@ TOOLTEST tattr-1.ddl --enable-error-stack tattr.h5 TOOLTEST tattr-2.ddl --enable-error-stack -a "/\/attr1" --attribute /attr4 --attribute=/attr5 tattr.h5 TOOLTEST tattr-2.ddl --enable-error-stack -N "/\/attr1" --any_path /attr4 --any_path=/attr5 tattr.h5 # test for header and error messages -TOOLTEST4 tattr-3.ddl --enable-error-stack --header -a /attr2 --attribute=/attr tattr.h5 +GREPTEST ERRTXT "h5dump error: unable to open attribute" tattr-3.ddl --enable-error-stack --header -a /attr2 --attribute=/attr tattr.h5 # test for displaying at least 9 attributes on root from a BE machine TOOLTEST tattr-4_be.ddl --enable-error-stack tattr4_be.h5 # test for displaying attributes in shared datatype (also in group and dataset) @@ -1239,7 +1127,7 @@ TOOLTEST tslink-2.ddl --enable-error-stack -l slink2 tslink.h5 TOOLTEST tslink-2.ddl --enable-error-stack -N slink2 tslink.h5 TOOLTEST tudlink-2.ddl --enable-error-stack -l udlink2 tudlink.h5 # test for displaying dangling soft links -TOOLTEST4 tslink-D.ddl --enable-error-stack -d /slink1 tslink.h5 +GREPTEST ERRTXT "component not found" tslink-D.ddl --enable-error-stack -d /slink1 tslink.h5 # tests for hard links TOOLTEST thlink-1.ddl --enable-error-stack thlink.h5 @@ -1256,7 +1144,7 @@ TOOLTEST tcomp-1.ddl --enable-error-stack tcompound.h5 TOOLTEST tcomp-2.ddl --enable-error-stack -t /type1 --datatype /type2 --datatype=/group1/type3 tcompound.h5 TOOLTEST tcomp-2.ddl --enable-error-stack -N /type1 --any_path /type2 --any_path=/group1/type3 tcompound.h5 # test for unnamed type -TOOLTEST4 tcomp-3.ddl --enable-error-stack -t /#6632 -g /group2 tcompound.h5 +GREPTEST ERRTXT "object '#6632' doesn't exist" tcomp-3.ddl --enable-error-stack -t /#6632 -g /group2 tcompound.h5 # test complicated compound datatype TOOLTEST tcomp-4.ddl --enable-error-stack tcompound_complex.h5 TOOLTEST tcompound_complex2.ddl --enable-error-stack tcompound_complex2.h5 @@ -1272,7 +1160,7 @@ TOOLTEST tnestcomp-1.ddl --enable-error-stack tnestedcomp.h5 TOOLTEST tnestedcmpddt.ddl --enable-error-stack tnestedcmpddt.h5 # test for options -TOOLTEST4 tall-1.ddl --enable-error-stack tall.h5 +GREPTEST ERRTXT "unable to open external file, external link file name" tall-1.ddl --enable-error-stack tall.h5 TOOLTEST tall-2.ddl --enable-error-stack --header -g /g1/g1.1 -a attr2 tall.h5 TOOLTEST tall-3.ddl --enable-error-stack -d /g2/dset2.1 -l /g1/g1.2/g1.2.1/slink tall.h5 TOOLTEST tall-3.ddl --enable-error-stack -N /g2/dset2.1 -N /g1/g1.2/g1.2.1/slink tall.h5 @@ -1314,7 +1202,7 @@ TOOLTEST tarray8.ddl --enable-error-stack tarray8.h5 # test for wildcards in filename (does not work with cmake) # inconsistent across platforms TOOLTEST3 tstarfile.ddl --enable-error-stack -H -d Dataset1 tarr*.h5 -#TOOLTEST4 tqmarkfile.ddl --enable-error-stack -H -d Dataset1 tarray?.h5 +#GREPTEST ERRTXT "unable to get link info from" tqmarkfile.ddl --enable-error-stack -H -d Dataset1 tarray?.h5 TOOLTEST tmultifile.ddl --enable-error-stack -H -d Dataset1 tarray2.h5 tarray3.h5 tarray4.h5 tarray5.h5 tarray6.h5 tarray7.h5 # test for files with empty data @@ -1332,13 +1220,13 @@ TOOLTEST tmulti.ddl --enable-error-stack --filedriver=multi tmulti TOOLTEST tlarge_objname.ddl --enable-error-stack -w157 tlarge_objname.h5 # test '-A' to suppress data but print attr's -TOOLTEST4 tall-2A.ddl --enable-error-stack -A tall.h5 +GREPTEST ERRTXT "unable to open external file, external link file name" tall-2A.ddl --enable-error-stack -A tall.h5 # test '-A' to suppress attr's but print data -TOOLTEST4 tall-2A0.ddl --enable-error-stack -A 0 tall.h5 +GREPTEST ERRTXT "unable to open external file, external link file name" tall-2A0.ddl --enable-error-stack -A 0 tall.h5 # test '-r' to print attributes in ASCII instead of decimal -TOOLTEST4 tall-2B.ddl --enable-error-stack -A -r tall.h5 +GREPTEST ERRTXT "unable to open external file, external link file name" tall-2B.ddl --enable-error-stack -A -r tall.h5 # test Subsetting TOOLTEST tall-4s.ddl --enable-error-stack --dataset=/g1/g1.1/dset1.1.1 --start=1,1 --stride=2,3 --count=3,2 --block=1,1 tall.h5 @@ -1368,7 +1256,7 @@ TOOLTEST tboot2B.ddl --enable-error-stack --superblock tfcontents2.h5 TOOLTEST file_space.ddl --enable-error-stack -B file_space.h5 # test -p with a non existing dataset -TOOLTEST4 tperror.ddl --enable-error-stack -p -d bogus tfcontents1.h5 +GREPTEST ERRTXT "h5dump error: unable to get link info from" tperror.ddl --enable-error-stack -p -d bogus tfcontents1.h5 # test for file contents TOOLTEST tcontents.ddl --enable-error-stack -n tfcontents1.h5 @@ -1417,10 +1305,10 @@ TOOLTEST tindicessub3.ddl --enable-error-stack -d 3d -s 0,1,2 -S 1,3,3 -c 2,2,2 TOOLTEST tindicessub4.ddl --enable-error-stack -d 4d -s 0,0,1,2 -c 2,2,3,2 -S 1,1,3,3 -k 1,1,2,2 taindices.h5 #Exceed the dimensions for subsetting -TOOLTEST texceedsubstart.ddl --enable-error-stack -d 1d -s 1,3 taindices.h5 -TOOLTEST texceedsubcount.ddl --enable-error-stack -d 1d -c 1,3 taindices.h5 -TOOLTEST texceedsubstride.ddl --enable-error-stack -d 1d -S 1,3 taindices.h5 -TOOLTEST texceedsubblock.ddl --enable-error-stack -d 1d -k 1,3 taindices.h5 +GREPTEST ERRTXT "exceed dataset dims" texceedsubstart.ddl --enable-error-stack -d 1d -s 1,3 taindices.h5 +GREPTEST ERRTXT "exceed dataset dims" texceedsubcount.ddl --enable-error-stack -d 1d -c 1,3 taindices.h5 +GREPTEST ERRTXT "exceed dataset dims" texceedsubstride.ddl --enable-error-stack -d 1d -S 1,3 taindices.h5 +GREPTEST ERRTXT "exceed dataset dims" texceedsubblock.ddl --enable-error-stack -d 1d -k 1,3 taindices.h5 # tests for filters @@ -1459,9 +1347,6 @@ TOOLTEST tbigdims.ddl --enable-error-stack -d dset4gb -s 4294967284 -c 22 tbigdi # hyperslab read TOOLTEST thyperslab.ddl --enable-error-stack thyperslab.h5 - -# - # test for displaying dataset and attribute of null space TOOLTEST tnullspace.ddl --enable-error-stack tnullspace.h5 TOOLTEST tgrpnullspace.ddl -p --enable-error-stack tgrpnullspace.h5 @@ -1542,18 +1427,18 @@ TOOLTEST torderattr3.ddl --enable-error-stack -H --sort_by=creation_order --sort TOOLTEST torderattr4.ddl --enable-error-stack -H --sort_by=creation_order --sort_order=descending torderattr.h5 # tests for link references and order -TOOLTEST4 torderlinks1.ddl --enable-error-stack --sort_by=name --sort_order=ascending tfcontents1.h5 -TOOLTEST4 torderlinks2.ddl --enable-error-stack --sort_by=name --sort_order=descending tfcontents1.h5 +GREPTEST3 ERRTXT "unable to open external file, external link file name = 'fname'" torderlinks1.ddl --enable-error-stack --sort_by=name --sort_order=ascending tfcontents1.h5 +GREPTEST3 ERRTXT "unable to open external file, external link file name = 'fname'" torderlinks2.ddl --enable-error-stack --sort_by=name --sort_order=descending tfcontents1.h5 # tests for floating point user defined printf format TOOLTEST tfpformat.ddl --enable-error-stack -m %.7f tfpformat.h5 # tests for traversal of external links -TOOLTEST4 textlinksrc.ddl --enable-error-stack textlinksrc.h5 -TOOLTEST4 textlinkfar.ddl --enable-error-stack textlinkfar.h5 +GREPTEST3 ERRTXT "Too many soft links in path" textlinksrc.ddl --enable-error-stack textlinksrc.h5 +GREPTEST3 ERRTXT "Too many soft links in path" textlinkfar.ddl --enable-error-stack textlinkfar.h5 # test for dangling external links -TOOLTEST4 textlink.ddl --enable-error-stack textlink.h5 +GREPTEST3 ERRTXT "unable to open external file, external link file name = 'anotherfile'" textlink.ddl --enable-error-stack textlink.h5 # test for error stack display (BZ2048) GREPTEST2 ERRTXT "filter plugins disabled" filter_fail.ddl --enable-error-stack filter_fail.h5 @@ -1562,13 +1447,13 @@ GREPTEST2 ERRTXT "filter plugins disabled" filter_fail.ddl --enable-error-stack TOOLTEST2 tall-6.exp --enable-error-stack -y -o tall-6.txt -d /g1/g1.1/dset1.1.1 tall.h5 # test for non-existing file -TOOLTEST3 non_existing.ddl --enable-error-stack tgroup.h5 non_existing.h5 +GREPTEST ERRTXT "unable to open file" non_existing.ddl --enable-error-stack tgroup.h5 non_existing.h5 # test to verify github issue #3790: infinite loop closing library -TOOLTEST4 infinite_loop.ddl 3790_infinite_loop.h5 +GREPTEST ERRTXT "unable to open file" infinite_loop.ddl 3790_infinite_loop.h5 # test to verify HDFFV-10333: error similar to H5O_attr_decode in the jira issue -TOOLTEST err_attr_dspace.ddl err_attr_dspace.h5 +GREPTEST ERRTXT "error getting attribute information" err_attr_dspace.ddl err_attr_dspace.h5 # test to verify HDFFV-9407: long double full precision #GREPTEST OUTTXT "1.123456789012345" t128bit_float.ddl -m %.35Lf t128bit_float.h5 diff --git a/tools/test/h5dump/testh5dumppbits.sh.in b/tools/test/h5dump/testh5dumppbits.sh.in index 66ff231ed79..181dfb1b978 100644 --- a/tools/test/h5dump/testh5dumppbits.sh.in +++ b/tools/test/h5dump/testh5dumppbits.sh.in @@ -34,6 +34,7 @@ H5IMPORT_BIN=`pwd`/$H5IMPORT # The path of the h5import tool binary RM='rm -rf' CMP='cmp -s' DIFF='diff -c' +GREP='grep' CP='cp' DIRNAME='dirname' LS='ls' @@ -49,7 +50,6 @@ SRC_TOOLS="$srcdir/../.." SRC_H5LS_TESTFILES="$SRC_TOOLS/test/h5ls/testfiles" SRC_H5DUMP_TESTFILES="$SRC_TOOLS/test/h5dump/testfiles" SRC_H5DUMP_OUTFILES="$SRC_TOOLS/test/h5dump/expected" -SRC_H5DUMP_ERRORFILES="$SRC_TOOLS/test/h5dump/errfiles" SRC_H5DIFF_TESTFILES="$SRC_TOOLS/test/h5diff/testfiles" SRC_H5COPY_TESTFILES="$SRC_TOOLS/test/h5copy/testfiles" SRC_H5REPACK_TESTFILES="$SRC_TOOLS/test/h5repack/testfiles" @@ -133,26 +133,10 @@ $SRC_H5DUMP_OUTFILES/pbits/tpbitsSignedLongLong16.ddl $SRC_H5DUMP_OUTFILES/pbits/tpbitsUnsignedLongLong16.ddl " -LIST_ERROR_TEST_FILES=" -${SRC_H5DUMP_ERRORFILES}/pbits/tnofilename-with-packed-bits.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsCharLengthExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsCharOffsetExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsIncomplete.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsIntLengthExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsIntOffsetExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsLengthExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsLengthPositive.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsLongLengthExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsLongOffsetExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsMaxExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsOffsetExceeded.err -${SRC_H5DUMP_ERRORFILES}/pbits/tpbitsOffsetNegative.err -" - # # copy test files and expected output files from source dirs to test dir # -COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_OTHER_TEST_FILES $LIST_ERROR_TEST_FILES" +COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_OTHER_TEST_FILES" COPY_TESTFILES_TO_TESTDIR() { @@ -170,7 +154,7 @@ COPY_TESTFILES_TO_TESTDIR() INODE_SDIR=`$LS -i -d $SDIR | $AWK -F' ' '{print $1}'` INODE_DDIR=`$LS -i -d $TESTDIR | $AWK -F' ' '{print $1}'` if [ "$INODE_SDIR" != "$INODE_DDIR" ]; then - $CP -f $tstfile $TESTDIR + $CP -f $tstfile $TESTDIR if [ $? -ne 0 ]; then echo "Error: FAILED to copy $tstfile ." @@ -225,8 +209,8 @@ TOOLTEST() { # Run test. TESTING $DUMPER $@ ( - cd $TESTDIR - $RUNSERIAL $DUMPER_BIN "$@" + cd $TESTDIR + $RUNSERIAL $DUMPER_BIN "$@" ) >$actual 2>$actual_err # save actual and actual_err in case they are needed later. @@ -257,70 +241,17 @@ TOOLTEST() { } -# same as TOOLTEST1 but compares generated file to expected output -# and compares the generated data file to the expected data file -# used for the binary tests that expect a full path in -o without -b -TOOLTEST2() { - - expectdata="$TESTDIR/$1" - expect="$TESTDIR/`basename $1 .exp`.ddl" - actualdata="$TESTDIR/`basename $1 .exp`.txt" - actual="$TESTDIR/`basename $1 .exp`.out" - actual_err="$TESTDIR/`basename $1 .exp`.err" +# Call the h5dump tool and grep for a value +# txttype ERRTXT greps test error output, otherwise greps test output +GREPTEST() +{ + txttype=$1 + expectdata=$2 + expect="$TESTDIR/$3" + actual="$TESTDIR/`basename $3 .ddl`.out" + actual_err="$TESTDIR/`basename $3 .ddl`.oerr" + shift shift - - # Run test. - TESTING $DUMPER $@ - ( - cd $TESTDIR - $RUNSERIAL $DUMPER_BIN "$@" - ) >$actual 2>$actual_err - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - if [ ! -f $expectdata ]; then - # Create the expect data file if it doesn't yet exist. - echo " CREATED" - cp $actualdata $expectdata - echo " Expected data (*.exp) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expectdata $actualdata; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected datafile (*.exp) differs from actual datafile (*.txt)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expectdata $actualdata |sed 's/^/ /' - fi - else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi - - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actualdata $actual_err - fi - -} - -# same as TOOLTEST but filters error stack outp -# Extract file name, line number, version and thread IDs because they may be different -TOOLTEST3() { - - expect="$TESTDIR/$1" - actual="$TESTDIR/`basename $1 .ddl`.out" - actual_err="$TESTDIR/`basename $1 .ddl`.err" - actual_ext="$TESTDIR/`basename $1 .ddl`.ext" - actual_sav=${actual}-sav - actual_err_sav=${actual_err}-sav shift # Run test. @@ -330,178 +261,35 @@ TOOLTEST3() { $RUNSERIAL $DUMPER_BIN "$@" ) >$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 - - # Extract file name, line number, version and thread IDs because they may be different - sed -e 's/ thread [0-9]*//' -e 's/: .*\.c /: (file name) /' \ - -e 's/line [0-9]*/line (number)/' \ - -e 's/v[1-9]*\.[0-9]*\./version (number)\./' \ - -e 's/[1-9]*\.[0-9]*\.[0-9]*[^)]*/version (number)/' \ - -e 's/H5Eget_auto[1-2]*/H5Eget_auto(1 or 2)/' \ - -e 's/H5Eset_auto[1-2]*/H5Eset_auto(1 or 2)/' \ - $actual_err > $actual_ext - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - echo " PASSED" + if [ "$txttype" = "ERRTXT" ]; then + $GREP "$expectdata" $actual_err > /dev/null else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi - - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav + $GREP "$expectdata" $actual > /dev/null fi -} - -# same as TOOLTEST3 but filters error stack output and compares to an error file -# Extract file name, line number, version and thread IDs because they may be different -TOOLTEST4() { - - expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .ddl`.err" - actual="$TESTDIR/`basename $1 .ddl`.out" - actual_err="$TESTDIR/`basename $1 .ddl`.oerr" - actual_ext="$TESTDIR/`basename $1 .ddl`.ext" - actual_sav=${actual}-sav - actual_err_sav=${actual_err}-sav - shift - - # Run test. - TESTING $DUMPER $@ - ( - cd $TESTDIR - $RUNSERIAL $DUMPER_BIN "$@" - ) >$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 - - # Extract file name, line number, version and thread IDs because they may be different - sed -e 's/ thread [0-9]*//' -e 's/: .*\.c /: (file name) /' \ - -e 's/line [0-9]*/line (number)/' \ - -e 's/v[1-9]*\.[0-9]*\./version (number)\./' \ - -e 's/[1-9]*\.[0-9]*\.[0-9]*[^)]*/version (number)/' \ - -e 's/H5Eget_auto[1-2]*/H5Eget_auto(1 or 2)/' \ - -e 's/H5Eset_auto[1-2]*/H5Eset_auto(1 or 2)/' \ - $actual_err > $actual_ext - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - if $CMP $expect_err $actual_ext; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected result (*.err) differs from actual result (*.oerr)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect_err $actual_ext |sed 's/^/ /' - fi + if [ $? -eq 0 ]; then + echo " PASSED" else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" + echo " FAILED" nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' fi # Clean up output file if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav + rm -f $actual $actual_err fi - } # Print a "SKIP" message SKIP() { - TESTING $DUMPER $@ + TESTING $DUMPER $@ echo " -SKIP-" } -# Print a line-line message left justified in a field of 70 characters -# -PRINT_H5DIFF() { - SPACES=" " - echo " Running h5diff $* $SPACES" | cut -c1-70 | tr -d '\012' -} - - -# Call the h5diff tool -# -DIFFTEST() -{ - PRINT_H5DIFF $@ - ( - cd $TESTDIR - $RUNSERIAL $H5DIFF_BIN "$@" -q - ) - RET=$? - - if [ $RET != 0 ] ; then - echo "*FAILED*" - nerrors="`expr $nerrors + 1`" - else - echo " PASSED" - fi - -} - -# Print a line-line message left justified in a field of 70 characters -# beginning with the word "Verifying". -# -PRINT_H5IMPORT() { - SPACES=" " - echo " Running h5import $* $SPACES" | cut -c1-70 | tr -d '\012' -} - -# Call the h5import tool -# -IMPORTTEST() -{ - # remove the output hdf5 file if it exists - hdf5_file="$TESTDIR/$5" - if [ -f $hdf5_file ]; then - rm -f $hdf5_file - fi - - PRINT_H5IMPORT $@ - ( - cd $TESTDIR - $RUNSERIAL $H5IMPORT_BIN "$@" - ) - RET=$? - - if [ $RET != 0 ] ; then - echo "*FAILED*" - nerrors="`expr $nerrors + 1`" - else - echo " PASSED" - fi -} - ############################################################################## ############################################################################## -### T H E T E S T S ### +### T H E T E S T S ### ############################################################################## ############################################################################## # prepare for test @@ -511,7 +299,7 @@ COPY_TESTFILES_TO_TESTDIR # test failure handling # Missing file name -TOOLTEST tnofilename-with-packed-bits.ddl --enable-error-stack +GREPTEST ERRTXT "missing file name" tnofilename-with-packed-bits.ddl --enable-error-stack # Limits: # Maximum number of packed bits is 8 (for now). # Maximum integer size is 64 (for now). @@ -570,23 +358,23 @@ TOOLTEST tpbitsCompound.ddl --enable-error-stack -d /dset1 -M 0,1,1,1 tcompound. TOOLTEST tpbitsArray.ddl --enable-error-stack -d /Dataset1 -M 0,1,1,1 tarray1.h5 # Test Error handling. # Too many packed bits requested. Max is 8 for now. -TOOLTEST tpbitsMaxExceeded.ddl --enable-error-stack -d /DS08BITS -M 0,1,0,1,1,1,2,1,3,1,4,1,5,1,6,1,7,1 packedbits.h5 +GREPTEST ERRTXT "Too many masks requested" tpbitsMaxExceeded.ddl --enable-error-stack -d /DS08BITS -M 0,1,0,1,1,1,2,1,3,1,4,1,5,1,6,1,7,1 packedbits.h5 # Offset too large. Max is 7 (8-1) for now. -TOOLTEST tpbitsOffsetExceeded.ddl --enable-error-stack -d /DS08BITS -M 64,1 packedbits.h5 +GREPTEST ERRTXT "must be between 0 and 63" tpbitsOffsetExceeded.ddl --enable-error-stack -d /DS08BITS -M 64,1 packedbits.h5 TOOLTEST tpbitsCharOffsetExceeded.ddl --enable-error-stack -d /DS08BITS -M 8,1 packedbits.h5 TOOLTEST tpbitsIntOffsetExceeded.ddl --enable-error-stack -d /DS16BITS -M 16,1 packedbits.h5 TOOLTEST tpbitsLongOffsetExceeded.ddl --enable-error-stack -d /DS32BITS -M 32,1 packedbits.h5 # Bad offset, must not be negative. -TOOLTEST tpbitsOffsetNegative.ddl --enable-error-stack -d /DS08BITS -M -1,1 packedbits.h5 +GREPTEST ERRTXT "Bad mask list" tpbitsOffsetNegative.ddl --enable-error-stack -d /DS08BITS -M -1,1 packedbits.h5 # Bad length, must not be positive. -TOOLTEST tpbitsLengthPositive.ddl --enable-error-stack -d /DS08BITS -M 4,0 packedbits.h5 +GREPTEST ERRTXT "must be positive" tpbitsLengthPositive.ddl --enable-error-stack -d /DS08BITS -M 4,0 packedbits.h5 # Offset+Length is too large. Max is 8 for now. -TOOLTEST tpbitsLengthExceeded.ddl --enable-error-stack -d /DS08BITS -M 37,28 packedbits.h5 +GREPTEST ERRTXT "too large" tpbitsLengthExceeded.ddl --enable-error-stack -d /DS08BITS -M 37,28 packedbits.h5 TOOLTEST tpbitsCharLengthExceeded.ddl --enable-error-stack -d /DS08BITS -M 2,7 packedbits.h5 TOOLTEST tpbitsIntLengthExceeded.ddl --enable-error-stack -d /DS16BITS -M 10,7 packedbits.h5 TOOLTEST tpbitsLongLengthExceeded.ddl --enable-error-stack -d /DS32BITS -M 26,7 packedbits.h5 # Incomplete pair of packed bits request. -TOOLTEST tpbitsIncomplete.ddl --enable-error-stack -d /DS08BITS -M 0,2,2,1,0,2,2, packedbits.h5 +GREPTEST ERRTXT "Bad mask list" tpbitsIncomplete.ddl --enable-error-stack -d /DS08BITS -M 0,2,2,1,0,2,2, packedbits.h5 # Clean up temporary files/directories CLEAN_TESTFILES_AND_TESTDIR diff --git a/tools/test/h5dump/testh5dumpvds.sh.in b/tools/test/h5dump/testh5dumpvds.sh.in index 28727688bd0..9c992303d67 100644 --- a/tools/test/h5dump/testh5dumpvds.sh.in +++ b/tools/test/h5dump/testh5dumpvds.sh.in @@ -49,7 +49,6 @@ SRC_TOOLS="$srcdir/../.." SRC_H5LS_TESTFILES="$SRC_TOOLS/test/h5ls/testfiles" SRC_H5DUMP_TESTFILES="$SRC_TOOLS/test/h5dump/testfiles" SRC_H5DUMP_OUTFILES="$SRC_TOOLS/test/h5dump/expected" -SRC_H5DUMP_ERRORFILES="$srcdir/errfiles" SRC_H5DIFF_TESTFILES="$SRC_TOOLS/test/h5diff/testfiles" SRC_H5COPY_TESTFILES="$SRC_TOOLS/test/h5copy/testfiles" SRC_H5REPACK_TESTFILES="$SRC_TOOLS/test/h5repack/testfiles" @@ -125,13 +124,10 @@ $SRC_H5DUMP_OUTFILES/vds/vds_layout-eiger.ddl $SRC_H5DUMP_OUTFILES/vds/vds_layout-maxmin.ddl " -LIST_ERROR_TEST_FILES=" -" - # # copy test files and expected output files from source dirs to test dir # -COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_OTHER_TEST_FILES $LIST_ERROR_TEST_FILES" +COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_OTHER_TEST_FILES" COPY_TESTFILES_TO_TESTDIR() { @@ -237,246 +233,12 @@ TOOLTEST() { } -# same as TOOLTEST1 but compares generated file to expected output -# and compares the generated data file to the expected data file -# used for the binary tests that expect a full path in -o without -b -TOOLTEST2() { - - expectdata="$TESTDIR/$1" - expect="$TESTDIR/`basename $1 .exp`.ddl" - actualdata="$TESTDIR/`basename $1 .exp`.txt" - actual="$TESTDIR/`basename $1 .exp`.out" - actual_err="$TESTDIR/`basename $1 .exp`.err" - shift - - # Run test. - TESTING $DUMPER $@ - ( - cd $TESTDIR - $RUNSERIAL $DUMPER_BIN "$@" - ) >$actual 2>$actual_err - cat $actual_err >> $actual - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - if [ ! -f $expectdata ]; then - # Create the expect data file if it doesn't yet exist. - echo " CREATED" - cp $actualdata $expectdata - echo " Expected data (*.exp) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expectdata $actualdata; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected datafile (*.exp) differs from actual datafile (*.txt)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expectdata $actualdata |sed 's/^/ /' - fi - else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi - - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actualdata $actual_err - fi - -} - -# same as TOOLTEST but filters error stack outp -# Extract file name, line number, version and thread IDs because they may be different -TOOLTEST3() { - - expect="$TESTDIR/$1" - actual="$TESTDIR/`basename $1 .ddl`.out" - actual_err="$TESTDIR/`basename $1 .ddl`.err" - actual_ext="$TESTDIR/`basename $1 .ddl`.ext" - actual_sav=${actual}-sav - actual_err_sav=${actual_err}-sav - shift - - # Run test. - TESTING $DUMPER $@ - ( - cd $TESTDIR - $RUNSERIAL $DUMPER_BIN "$@" - ) >$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 - - # Extract file name, line number, version and thread IDs because they may be different - sed -e 's/ thread [0-9]*//' -e 's/: .*\.c /: (file name) /' \ - -e 's/line [0-9]*/line (number)/' \ - -e 's/v[1-9]*\.[0-9]*\./version (number)\./' \ - -e 's/[1-9]*\.[0-9]*\.[0-9]*[^)]*/version (number)/' \ - -e 's/H5Eget_auto[1-2]*/H5Eget_auto(1 or 2)/' \ - -e 's/H5Eset_auto[1-2]*/H5Eset_auto(1 or 2)/' \ - $actual_err > $actual_ext - cat $actual_ext >> $actual - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - echo " Expected result (*.ddl) missing" - nerrors="`expr $nerrors + 1`" - elif $CMP $expect $actual; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi - - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav - fi - -} - -# same as TOOLTEST3 but filters error stack output and compares to an error file -# Extract file name, line number, version and thread IDs because they may be different -TOOLTEST4() { - - expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .ddl`.err" - actual="$TESTDIR/`basename $1 .ddl`.out" - actual_err="$TESTDIR/`basename $1 .ddl`.oerr" - actual_ext="$TESTDIR/`basename $1 .ddl`.ext" - actual_sav=${actual}-sav - actual_err_sav=${actual_err}-sav - shift - - # Run test. - TESTING $DUMPER $@ - ( - cd $TESTDIR - $RUNSERIAL $DUMPER_BIN "$@" - ) >$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 - - # Extract file name, line number, version and thread IDs because they may be different - sed -e 's/ thread [0-9]*//' -e 's/: .*\.c /: (file name) /' \ - -e 's/line [0-9]*/line (number)/' \ - -e 's/v[1-9]*\.[0-9]*\./version (number)\./' \ - -e 's/[1-9]*\.[0-9]*\.[0-9]*[^)]*/version (number)/' \ - -e 's/H5Eget_auto[1-2]*/H5Eget_auto(1 or 2)/' \ - -e 's/H5Eset_auto[1-2]*/H5Eset_auto(1 or 2)/' \ - $actual_err > $actual_ext - #cat $actual_ext >> $actual - - if [ ! -f $expect ]; then - # Create the expect file if it doesn't yet exist. - echo " CREATED" - cp $actual $expect - elif $CMP $expect $actual; then - if $CMP $expect_err $actual_ext; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected result (*.err) differs from actual result (*.oerr)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect_err $actual_ext |sed 's/^/ /' - fi - else - echo "*FAILED*" - echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' - fi - - # Clean up output file - if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav - fi -} - # Print a "SKIP" message SKIP() { TESTING $DUMPER $@ echo " -SKIP-" } -# Print a line-line message left justified in a field of 70 characters -# -PRINT_H5DIFF() { - SPACES=" " - echo " Running h5diff $* $SPACES" | cut -c1-70 | tr -d '\012' -} - - -# Call the h5diff tool -# -DIFFTEST() -{ - PRINT_H5DIFF $@ - ( - cd $TESTDIR - $RUNSERIAL $H5DIFF_BIN "$@" -q - ) - RET=$? - - if [ $RET != 0 ] ; then - echo "*FAILED*" - nerrors="`expr $nerrors + 1`" - else - echo " PASSED" - fi -} - -# Print a line-line message left justified in a field of 70 characters -# beginning with the word "Verifying". -# -PRINT_H5IMPORT() { - SPACES=" " - echo " Running h5import $* $SPACES" | cut -c1-70 | tr -d '\012' -} - -# Call the h5import tool -# -IMPORTTEST() -{ - # remove the output hdf5 file if it exists - hdf5_file="$TESTDIR/$5" - if [ -f $hdf5_file ]; then - rm -f $hdf5_file - fi - - PRINT_H5IMPORT $@ - ( - cd $TESTDIR - $RUNSERIAL $H5IMPORT_BIN "$@" - ) - RET=$? - - if [ $RET != 0 ] ; then - echo "*FAILED*" - nerrors="`expr $nerrors + 1`" - else - echo " PASSED" - fi -} - ############################################################################## ############################################################################## diff --git a/tools/test/h5format_convert/testh5fc.sh.in b/tools/test/h5format_convert/testh5fc.sh.in index 94516fb7066..6b75248f3c3 100644 --- a/tools/test/h5format_convert/testh5fc.sh.in +++ b/tools/test/h5format_convert/testh5fc.sh.in @@ -43,6 +43,7 @@ H5DUMP_BIN=`pwd`/$H5DUMP # The path of the h5dump tool binary DIRNAME='dirname' LS='ls' AWK='awk' +GREP='grep' nerrors=0 verbose=yes @@ -219,7 +220,6 @@ TESTING() { TOOLTEST_OUT() { # Prepare expected and actual output expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .ddl`.err" actual="$TESTDIR/`basename $1 .ddl`.out" actual_err="$TESTDIR/`basename $1 .ddl`.out.err" actual_sav=${actual}-sav @@ -351,6 +351,42 @@ TOOLTEST_ERR() { $RM $actual $actual_err $actual_sav $actual_err_sav fi } +# Same as TOOLTEST_OUT except only grep error output +TOOLTEST_GREP() { + # Prepare expected and actual output + expect="$TESTDIR/$1" + expected=$2 + actual="$TESTDIR/`basename $1 .ddl`.out" + actual_err="$TESTDIR/`basename $1 .ddl`.out.err" + actual_sav=${actual}-sav + actual_err_sav=${actual_err}-sav + testfile="`basename $1 .ddl`-tmp.h5" + + # Run test. + TESTING $FORMCONV $3 $4 $5 $6 $2 + ( + cd $TESTDIR + $RUNSERIAL $FORMCONV_BIN $3 $4 $5 $6 $TFILE + ) >$actual 2>$actual_err + cp $actual $actual_sav + cp $actual_err $actual_err_sav + + # Compare output + $GREP "$expectdata" $actual_err > /dev/null + if [ $? -eq 0 ]; then + echo " PASSED" + else + echo "*FAILED*" + echo " Expected error message not found in actual output" + nerrors="`expr $nerrors + 1`" + fi + + # Clean up output file + if test -z "$HDF5_NOCLEANUP"; then + $RM $actual $actual_err + $RM $actual $actual_err $actual_sav $actual_err_sav + fi +} # To check that the tool exits success, no output # Assume all short options @@ -462,6 +498,7 @@ COPY_TESTFILES_TO_TESTDIR TOOLTEST_OUT h5fc_help.ddl '' --help TOOLTEST_OUT h5fc_nooption.ddl '' TOOLTEST_ERR h5fc_nonexistfile.ddl nonexist.h5 +#TOOLTEST_GREP h5fc_nonexistfile.ddl "unable to open file" # # # h5format_convert -d old_h5fc_ext_none.h5 (just -d option, file exists) diff --git a/tools/test/h5ls/errfiles/nosuchfile.err b/tools/test/h5ls/errfiles/nosuchfile.err deleted file mode 100644 index 8c4ee420101..00000000000 --- a/tools/test/h5ls/errfiles/nosuchfile.err +++ /dev/null @@ -1 +0,0 @@ -nosuchfile.h5: unable to open file diff --git a/tools/test/h5ls/errfiles/textlinksrc-nodangle-1.err b/tools/test/h5ls/errfiles/textlinksrc-nodangle-1.err deleted file mode 100644 index 8991fc13ba0..00000000000 --- a/tools/test/h5ls/errfiles/textlinksrc-nodangle-1.err +++ /dev/null @@ -1,2 +0,0 @@ -Error: --no-dangling-links must be used along with --follow-symlinks option! - diff --git a/tools/test/h5ls/errfiles/tgroup-1.err b/tools/test/h5ls/errfiles/tgroup-1.err deleted file mode 100644 index ba4cf078f29..00000000000 --- a/tools/test/h5ls/errfiles/tgroup-1.err +++ /dev/null @@ -1,2 +0,0 @@ -Error: 'recursive' option not compatible with 'group info' option! - diff --git a/tools/test/h5ls/testh5ls.sh.in b/tools/test/h5ls/testh5ls.sh.in index e8ea342fda6..78844cfc654 100644 --- a/tools/test/h5ls/testh5ls.sh.in +++ b/tools/test/h5ls/testh5ls.sh.in @@ -51,7 +51,6 @@ SRC_H5REPACK_TESTFILES="$SRC_TOOLS/test/h5repack/testfiles" SRC_H5JAM_TESTFILES="$SRC_TOOLS/test/h5jam/testfiles" SRC_H5STAT_TESTFILES="$SRC_TOOLS/test/h5stat/testfiles" SRC_H5IMPORT_TESTFILES="$SRC_TOOLS/test/h5import/testfiles" -SRC_H5LS_ERRFILES="$SRC_TOOLS/test/h5ls/errfiles" SRC_H5LS_OUTFILES="$SRC_TOOLS/test/h5ls/expected" TESTDIR=./tmp @@ -95,12 +94,6 @@ $SRC_H5DUMP_TESTFILES/tvldtypes1.h5 $SRC_H5LS_TESTFILES/tdset_idx.h5 " -LIST_ERROR_TEST_FILES=" -$SRC_H5LS_ERRFILES/nosuchfile.err -$SRC_H5LS_ERRFILES/textlinksrc-nodangle-1.err -$SRC_H5LS_ERRFILES/tgroup-1.err -" - LIST_OTHER_TEST_FILES=" $SRC_H5LS_OUTFILES/help-1.ls $SRC_H5LS_OUTFILES/help-2.ls @@ -240,7 +233,6 @@ TESTING() { # $2 and on -- argument for the h5ls tool TOOLTEST() { expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .ls`.err" actual="$TESTDIR/`basename $1 .ls`.out" actual_err="$TESTDIR/`basename $1 .ls`.out.err" actual_sav=${actual}-sav diff --git a/tools/test/h5stat/expected/h5stat_err1_dims.err b/tools/test/h5stat/expected/h5stat_err1_dims.err deleted file mode 100644 index 86d375b6324..00000000000 --- a/tools/test/h5stat/expected/h5stat_err1_dims.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: Invalid threshold for small datasets diff --git a/tools/test/h5stat/expected/h5stat_err1_links.err b/tools/test/h5stat/expected/h5stat_err1_links.err deleted file mode 100644 index d43207c1374..00000000000 --- a/tools/test/h5stat/expected/h5stat_err1_links.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: Invalid threshold for small groups diff --git a/tools/test/h5stat/expected/h5stat_err1_numattrs.err b/tools/test/h5stat/expected/h5stat_err1_numattrs.err deleted file mode 100644 index 01b6c18ed66..00000000000 --- a/tools/test/h5stat/expected/h5stat_err1_numattrs.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: Invalid threshold for small # of attributes diff --git a/tools/test/h5stat/expected/h5stat_err2_numattrs.err b/tools/test/h5stat/expected/h5stat_err2_numattrs.err deleted file mode 100644 index 01b6c18ed66..00000000000 --- a/tools/test/h5stat/expected/h5stat_err2_numattrs.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: Invalid threshold for small # of attributes diff --git a/tools/test/h5stat/expected/h5stat_err_old_fill.err b/tools/test/h5stat/expected/h5stat_err_old_fill.err deleted file mode 100644 index 8b886d29810..00000000000 --- a/tools/test/h5stat/expected/h5stat_err_old_fill.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: unable to traverse objects/links in file "h5stat_err_old_fill.h5" diff --git a/tools/test/h5stat/expected/h5stat_err_old_layout.err b/tools/test/h5stat/expected/h5stat_err_old_layout.err deleted file mode 100644 index 7aa2fa7d000..00000000000 --- a/tools/test/h5stat/expected/h5stat_err_old_layout.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: unable to traverse objects/links in file "h5stat_err_old_layout.h5" diff --git a/tools/test/h5stat/expected/h5stat_err_refcount.err b/tools/test/h5stat/expected/h5stat_err_refcount.err deleted file mode 100644 index d176996a286..00000000000 --- a/tools/test/h5stat/expected/h5stat_err_refcount.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: unable to traverse objects/links in file "h5stat_err_refcount.h5" diff --git a/tools/test/h5stat/expected/h5stat_nofile.err b/tools/test/h5stat/expected/h5stat_nofile.err deleted file mode 100644 index 3b7e97949a4..00000000000 --- a/tools/test/h5stat/expected/h5stat_nofile.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: missing file name diff --git a/tools/test/h5stat/expected/h5stat_notexist.err b/tools/test/h5stat/expected/h5stat_notexist.err deleted file mode 100644 index c1d9e5432cc..00000000000 --- a/tools/test/h5stat/expected/h5stat_notexist.err +++ /dev/null @@ -1 +0,0 @@ -h5stat error: unable to open file "notexist.h5" diff --git a/tools/test/h5stat/testh5stat.sh.in b/tools/test/h5stat/testh5stat.sh.in index 1d732c600ae..bc48494f59b 100644 --- a/tools/test/h5stat/testh5stat.sh.in +++ b/tools/test/h5stat/testh5stat.sh.in @@ -33,6 +33,7 @@ CP='cp' DIRNAME='dirname' LS='ls' AWK='awk' +GREP='grep' nerrors=0 verbose=yes @@ -74,18 +75,6 @@ $SRC_H5STAT_TESTFILES/h5stat_idx.h5 $SRC_H5STAT_TESTFILES/h5stat_threshold.h5 " -LIST_ERR_TEST_FILES=" -$SRC_H5STAT_OUTFILES/h5stat_err_refcount.err -$SRC_H5STAT_OUTFILES/h5stat_err_old_layout.err -$SRC_H5STAT_OUTFILES/h5stat_err_old_fill.err -$SRC_H5STAT_OUTFILES/h5stat_err1_links.err -$SRC_H5STAT_OUTFILES/h5stat_err1_dims.err -$SRC_H5STAT_OUTFILES/h5stat_err1_numattrs.err -$SRC_H5STAT_OUTFILES/h5stat_err2_numattrs.err -$SRC_H5STAT_OUTFILES/h5stat_notexist.err -$SRC_H5STAT_OUTFILES/h5stat_nofile.err -" - LIST_OTHER_TEST_FILES=" $SRC_H5STAT_OUTFILES/h5stat_err_refcount.ddl $SRC_H5STAT_OUTFILES/h5stat_err_old_layout.ddl @@ -123,7 +112,7 @@ $SRC_H5STAT_OUTFILES/h5stat_numattrs4.ddl # # copy test files and expected output files from source dirs to test dir # -COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_ERR_TEST_FILES $LIST_OTHER_TEST_FILES" +COPY_TESTFILES="$LIST_HDF5_TEST_FILES $LIST_OTHER_TEST_FILES" COPY_TESTFILES_TO_TESTDIR() { @@ -187,7 +176,6 @@ TESTING() { # TOOLTEST() { expect="$TESTDIR/$1" - expect_err="$TESTDIR/`basename $1 .ddl`.err" actual="$TESTDIR/`basename $1 .ddl`.out" actual_err="$TESTDIR/`basename $1 .ddl`.out.err" actual_sav=${actual}-sav @@ -207,17 +195,7 @@ TOOLTEST() { cp $actual_err $actual_err_sav STDERR_FILTER $actual_err - if [ ! -f $expect ]; then - # Compare error files if the expect file doesn't exist. - if $CMP $expect_err $actual_err; then - echo " PASSED" - else - echo "*FAILED*" - echo " Expected result (*.err) differs from actual result (*.out.err)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect_err $actual_err |sed 's/^/ /' - fi - elif $CMP $expect $actual; then + if $CMP $expect $actual; then echo " PASSED" else echo "*FAILED*" @@ -233,6 +211,52 @@ TOOLTEST() { } +# Call the h5stat tool and grep for a value +# txttype ERRTXT greps test error output, otherwise greps test output +GREPTEST() +{ + txttype=$1 + expectdata=$2 + expect="$TESTDIR/$3" + actual="$TESTDIR/`basename $1 .ddl`.out" + actual_err="$TESTDIR/`basename $1 .ddl`.out.err" + shift + shift + shift + if [ "$1" = -i ]; then + inputfile=$2 + fi + + if [ "$3" = -o ]; then + outputfile=$4 + fi + + TESTING $STAT $@ + ( + cd $TESTDIR + $RUNSERIAL $STAT_BIN $@ + ) >$actual 2>$actual_err + RET=$? + + if [ "$txttype" = "ERRTXT" ]; then + $GREP "$expectdata" $actual_err > /dev/null + else + $GREP "$expectdata" $actual > /dev/null + fi + + 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 $STAT $@ @@ -282,7 +306,7 @@ TOOLTEST h5stat_idx.ddl h5stat_idx.h5 # -g -l 8 # --links=8 # --links=20 -g -TOOLTEST h5stat_err1_links.ddl -l 0 h5stat_threshold.h5 +GREPTEST ERRTXT "Invalid threshold for small groups" h5stat_err1_links.ddl -l 0 h5stat_threshold.h5 TOOLTEST h5stat_links1.ddl -g -l 8 h5stat_threshold.h5 TOOLTEST h5stat_links2.ddl --links=8 h5stat_threshold.h5 TOOLTEST h5stat_links3.ddl --links=20 -g h5stat_threshold.h5 @@ -297,7 +321,7 @@ TOOLTEST h5stat_links5.ddl -g -l 40000 h5stat_newgrat.h5 # -d --dims=-1 (incorrect threshold value) # -gd -m 5 # -d --di=15 -TOOLTEST h5stat_err1_dims.ddl -d --dims=-1 h5stat_threshold.h5 +GREPTEST ERRTXT "Invalid threshold for small datasets" h5stat_err1_dims.ddl -d --dims=-1 h5stat_threshold.h5 TOOLTEST h5stat_dims1.ddl -gd -m 5 h5stat_threshold.h5 TOOLTEST h5stat_dims2.ddl -d --dims=15 h5stat_threshold.h5 # @@ -307,8 +331,8 @@ TOOLTEST h5stat_dims2.ddl -d --dims=15 h5stat_threshold.h5 # -AS -a 10 # -a 1 # -A --numattrs=25 -TOOLTEST h5stat_err1_numattrs.ddl -a -2 h5stat_threshold.h5 -TOOLTEST h5stat_err2_numattrs.ddl --numattrs h5stat_threshold.h5 +GREPTEST ERRTXT "Invalid threshold for small # of attributes" h5stat_err1_numattrs.ddl -a -2 h5stat_threshold.h5 +GREPTEST ERRTXT "Invalid threshold for small # of attributes" h5stat_err2_numattrs.ddl --numattrs h5stat_threshold.h5 TOOLTEST h5stat_numattrs1.ddl -AS -a 10 h5stat_threshold.h5 TOOLTEST h5stat_numattrs2.ddl -a 1 h5stat_threshold.h5 TOOLTEST h5stat_numattrs3.ddl -A --numattrs=25 h5stat_threshold.h5 diff --git a/tools/test/misc/expected/h5clear_missing_file.err b/tools/test/misc/expected/h5clear_missing_file.err deleted file mode 100644 index ea21b76eee1..00000000000 --- a/tools/test/misc/expected/h5clear_missing_file.err +++ /dev/null @@ -1 +0,0 @@ -h5clear error: missing file name diff --git a/tools/test/misc/expected/h5clear_no_mdc_image.err b/tools/test/misc/expected/h5clear_no_mdc_image.err deleted file mode 100644 index f5acd71b479..00000000000 --- a/tools/test/misc/expected/h5clear_no_mdc_image.err +++ /dev/null @@ -1 +0,0 @@ -h5clear warning: No cache image in the file diff --git a/tools/test/misc/expected/h5clear_open_fail.err b/tools/test/misc/expected/h5clear_open_fail.err deleted file mode 100644 index 895ecd4298b..00000000000 --- a/tools/test/misc/expected/h5clear_open_fail.err +++ /dev/null @@ -1 +0,0 @@ -h5clear error: h5tools_fopen diff --git a/tools/test/misc/testh5clear.sh.in b/tools/test/misc/testh5clear.sh.in index 2306d589938..b97509415e2 100644 --- a/tools/test/misc/testh5clear.sh.in +++ b/tools/test/misc/testh5clear.sh.in @@ -30,6 +30,7 @@ CP='cp' DIRNAME='dirname' LS='ls' AWK='awk' +GREP='grep' SUCCEED=0 FAIL=1 @@ -61,8 +62,6 @@ test -d $TESTDIR || mkdir -p $TESTDIR # copy test files and expected output files from source dirs to test dir # COPY_TESTFILES=" -$SRC_H5CLEAR_OUTFILES/h5clear_open_fail.err -$SRC_H5CLEAR_OUTFILES/h5clear_no_mdc_image.err $SRC_H5CLEAR_OUTFILES/h5clear_usage.ddl $SRC_H5CLEAR_OUTFILES/h5clear_missing_file.ddl $SRC_H5CLEAR_OUTFILES/h5clear_status_noclose_after_size.ddl @@ -178,7 +177,6 @@ TOOLTEST_OUT() { expected=$5 # Prepare expected and actual output expect="$TESTDIR/$expected" - expect_err="$TESTDIR/`basename $expected .ddl`.err" actual="$TESTDIR/`basename $expected .ddl`.out" actual_err="$TESTDIR/`basename $expected .ddl`.out.err" actual_sav=${actual}-sav @@ -201,18 +199,16 @@ TOOLTEST_OUT() { $RM $actual $actual_err $actual_sav $actual_err_sav fi } -# same as TOOLTEST_OUT just compare stderr +# same as TOOLTEST_OUT just grep stderr TOOLTEST_ERR() { fname=$1 - option1=$2 - option2=$3 - option3=$4 - expected=$5 + expected=$2 + option1=$3 + option2=$4 + option3=$5 # Prepare expected and actual output - expect_err="$TESTDIR/$expected" - expect="$TESTDIR/`basename $expected .err`.ddl" - actual="$TESTDIR/`basename $expected .err`.out" - actual_err="$TESTDIR/`basename $expected .err`.out.err" + actual="$TESTDIR/`basename $fname .h5`.out" + actual_err="$TESTDIR/`basename $fname .h5`.out.err" actual_sav=${actual}-sav actual_err_sav=${actual_err}-sav @@ -225,9 +221,15 @@ TOOLTEST_ERR() { cp $actual $actual_sav cp $actual_err $actual_err_sav - # Compare output - COMPARE_OUT $expect_err $actual_err - + # grep output + $GREP "$expected" $actual_err > /dev/null + if test $? -eq 0; then + echo "PASSED" + else + echo "*FAILED*" + echo " Expected text not found in actual result (*.out.err)" + nerrors="`expr $nerrors + 1`" + fi # Clean up output file if test -z "$HDF5_NOCLEANUP"; then $RM $actual $actual_err $actual_sav $actual_err_sav @@ -305,11 +307,11 @@ TOOLTEST_OUT "" "" "" "" h5clear_usage.ddl TOOLTEST_OUT junk.h5 "" "" "" h5clear_usage.ddl TOOLTEST_OUT orig_h5clear_sec2_v3.h5 "" "" "" h5clear_usage.ddl TOOLTEST_OUT "" -m "" "" h5clear_missing_file.ddl -TOOLTEST_ERR junk.h5 -s "" "" h5clear_open_fail.err +TOOLTEST_ERR junk.h5 "h5clear error" -s "" "" TOOLTEST_OUT "" -m -s "" h5clear_missing_file.ddl -TOOLTEST_ERR junk.h5 -m -s "" h5clear_open_fail.err -TOOLTEST_ERR orig_h5clear_sec2_v2.h5 -m "" "" h5clear_no_mdc_image.err -TOOLTEST_ERR orig_h5clear_sec2_v0.h5 -s -m "" h5clear_no_mdc_image.err +TOOLTEST_ERR junk.h5 "h5clear error" -m -s "" +TOOLTEST_ERR orig_h5clear_sec2_v2.h5 "h5clear warning" -m "" "" +TOOLTEST_ERR orig_h5clear_sec2_v0.h5 "h5clear warning" -s -m "" # # # The following are tests to verify the expected exit code from h5clear: @@ -339,8 +341,8 @@ TOOLTEST h5clear_sec2_v0.h5 -l -m $FAIL # # # h5clear_mdc_image.h5 already has cache image removed earlier, verify the expected warning from h5clear: -TOOLTEST_ERR mod_h5clear_mdc_image.h5 -m "" "" h5clear_no_mdc_image.err -TOOLTEST_ERR mod_h5clear_mdc_image.h5 -s -m "" h5clear_no_mdc_image.err +TOOLTEST_ERR mod_h5clear_mdc_image.h5 "h5clear warning" -m "" "" +TOOLTEST_ERR mod_h5clear_mdc_image.h5 "h5clear warning" -s -m "" # # # @@ -378,7 +380,7 @@ OPEN_CHK h5clear_sec2_v2.h5 $SUCCEED # "h5clear -s --increment=0 h5clear_status_noclose.h5" (clear status_flag, EOA = MAX(EOA, EOF) + 0) # (no output, check exit code) # "h5clear --filesize h5clear_status_noclose_user.h5" (print EOA/EOF after the last action) -TOOLTEST_ERR h5clear_status_noclose.h5 --filesize "" "" h5clear_open_fail.err +TOOLTEST_ERR h5clear_status_noclose.h5 "h5clear error:" --filesize "" "" TOOLTEST h5clear_status_noclose.h5 -s --increment=0 $SUCCEED TOOLTEST_OUT h5clear_status_noclose.h5 --filesize "" "" h5clear_status_noclose_after_size.ddl #