summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tools/h5copy/CMakeTests.cmake74
-rw-r--r--tools/h5copy/testh5copy.sh.in19
-rw-r--r--tools/h5diff/CMakeTests.cmake13
-rw-r--r--tools/h5import/CMakeTests.cmake18
-rw-r--r--tools/h5import/h5importtestutil.sh.in5
-rw-r--r--tools/h5jam/CMakeTests.cmake35
-rw-r--r--tools/h5jam/testh5jam.sh.in2
-rw-r--r--tools/h5ls/CMakeTests.cmake8
-rw-r--r--tools/h5repack/CMakeTests.cmake20
-rw-r--r--tools/h5repack/h5repack.sh.in4
-rw-r--r--tools/h5stat/CMakeTests.cmake8
-rw-r--r--tools/h5stat/testh5stat.sh.in2
-rw-r--r--tools/misc/CMakeTests.cmake4
-rw-r--r--tools/misc/testh5mkgrp.sh.in2
14 files changed, 115 insertions, 99 deletions
diff --git a/tools/h5copy/CMakeTests.cmake b/tools/h5copy/CMakeTests.cmake
index a2131d1..c429377 100644
--- a/tools/h5copy/CMakeTests.cmake
+++ b/tools/h5copy/CMakeTests.cmake
@@ -108,6 +108,15 @@
endif ()
ENDMACRO ()
+ MACRO (ADD_SKIP_H5_TEST testname skipresultfile)
+ if (NOT HDF5_ENABLE_USING_MEMCHECKER)
+ add_test (
+ NAME H5COPY-${testname}-${skipresultfile}-SKIPPED
+ COMMAND ${CMAKE_COMMAND} -E echo "SKIP ${testname}-${skipresultfile} ${ARGN}"
+ )
+ endif ()
+ ENDMACRO ()
+
MACRO (ADD_H5_TEST2 testname resultcode infile psparam pdparam vparam sparam srcname dparam dstname)
if (NOT HDF5_ENABLE_USING_MEMCHECKER)
# Remove any output file left over from previous test run
@@ -168,7 +177,7 @@
if (NOT "${last_test}" STREQUAL "")
set_tests_properties (H5COPY_SAME-${testname}-prefill PROPERTIES DEPENDS ${last_test})
endif ()
- else ()
+ else (HDF5_ENABLE_USING_MEMCHECKER)
set_tests_properties (H5COPY_SAME-${testname}-prefill PROPERTIES DEPENDS H5COPY_SAME-${testname}-clear-objects)
endif ()
@@ -211,8 +220,6 @@
COMMAND ${CMAKE_COMMAND}
-E remove
./testfiles/${testname}.out.h5
- ./testfiles/${testname}.out.out
- ./testfiles/${testname}.out.out.err
)
add_test (
NAME H5COPY-CMP-${testname}
@@ -292,12 +299,31 @@
set (last_test "H5COPY-clearall-objects")
endif ()
+# See which filters are usable (and skip tests for filters we
+# don't have). Do this by searching H5pubconf.h to see which
+# filters are defined.
+
+# detect whether the encoder is present.
+ if (H5_HAVE_FILTER_DEFLATE)
+ set (USE_FILTER_DEFLATE "true")
+ endif ()
+
+ if (H5_HAVE_FILTER_SZIP)
+ set (USE_FILTER_SZIP "true")
+ endif ()
+
# "Test copying various forms of datasets"
ADD_H5_TEST (simple 0 ${HDF_FILE1}.h5 -v -s simple -d simple)
ADD_H5_TEST (chunk 0 ${HDF_FILE1}.h5 -v -s chunk -d chunk)
ADD_H5_TEST (compact 0 ${HDF_FILE1}.h5 -v -s compact -d compact)
ADD_H5_TEST (compound 0 ${HDF_FILE1}.h5 -v -s compound -d compound)
- ADD_H5_TEST (compressed 0 ${HDF_FILE1}.h5 -v -s compressed -d compressed)
+
+ if (USE_FILTER_DEFLATE)
+ ADD_H5_TEST (compressed 0 ${HDF_FILE1}.h5 -v -s compressed -d compressed)
+ else ()
+ ADD_H5_TEST (compressed 2 ${HDF_FILE1}.h5 -v -s compressed -d compressed)
+ endif ()
+
ADD_H5_TEST (named_vl 0 ${HDF_FILE1}.h5 -v -s named_vl -d named_vl)
ADD_H5_TEST (nested_vl 0 ${HDF_FILE1}.h5 -v -s nested_vl -d nested_vl)
ADD_H5_TEST (dset_attr 0 ${HDF_FILE1}.h5 -v -s dset_attr -d dset_attr)
@@ -310,25 +336,41 @@
# "Test copying empty, 'full' & 'nested' groups"
ADD_H5_TEST (grp_empty 0 ${HDF_FILE1}.h5 -v -s grp_empty -d grp_empty)
- ADD_H5_TEST (grp_dsets 0 ${HDF_FILE1}.h5 -v -s grp_dsets -d grp_dsets)
- ADD_H5_TEST (grp_nested 0 ${HDF_FILE1}.h5 -v -s grp_nested -d grp_nested)
+ if (USE_FILTER_DEFLATE)
+ ADD_H5_TEST (grp_dsets 0 ${HDF_FILE1}.h5 -v -s grp_dsets -d grp_dsets)
+ ADD_H5_TEST (grp_nested 0 ${HDF_FILE1}.h5 -v -s grp_nested -d grp_nested)
+ else ()
+ ADD_H5_TEST (grp_dsets 2 ${HDF_FILE1}.h5 -v -s grp_dsets -d grp_dsets)
+ ADD_H5_TEST (grp_nested 2 ${HDF_FILE1}.h5 -v -s grp_nested -d grp_nested)
+ endif ()
ADD_H5_TEST (grp_attr 0 ${HDF_FILE1}.h5 -v -s grp_attr -d grp_attr)
# "Test copying dataset within group in source file to group in destination"
ADD_H5_TEST2 (simple_group 0 ${HDF_FILE1}.h5 grp_dsets grp_dsets -v -s /grp_dsets/simple -d /grp_dsets/simple_group)
- # "Test copying & renaming group"
- ADD_H5_TEST (grp_rename 0 ${HDF_FILE1}.h5 -v -s grp_dsets -d grp_rename)
-
- # "Test copying 'full' group hierarchy into group in destination file"
- ADD_H5_TEST2 (grp_dsets_rename 0 ${HDF_FILE1}.h5 grp_dsets grp_rename -v -s grp_dsets -d /grp_rename/grp_dsets)
+ if (USE_FILTER_DEFLATE)
+ # "Test copying & renaming group"
+ ADD_H5_TEST (grp_rename 0 ${HDF_FILE1}.h5 -v -s grp_dsets -d grp_rename)
+ # "Test copying 'full' group hierarchy into group in destination file"
+ ADD_H5_TEST2 (grp_dsets_rename 0 ${HDF_FILE1}.h5 grp_dsets grp_rename -v -s grp_dsets -d /grp_rename/grp_dsets)
+ else ()
+ # "Test copying & renaming group"
+ ADD_H5_TEST (grp_rename 2 ${HDF_FILE1}.h5 -v -s grp_dsets -d grp_rename)
+ # "Test copying 'full' group hierarchy into group in destination file"
+ ADD_H5_TEST2 (grp_dsets_rename 2 ${HDF_FILE1}.h5 grp_dsets grp_rename -v -s grp_dsets -d /grp_rename/grp_dsets)
+ endif ()
# "Test copying objects into group hier. that doesn't exist yet in destination file"
ADD_H5_TEST (A_B1_simple 0 ${HDF_FILE1}.h5 -vp -s simple -d /A/B1/simple)
ADD_H5_TEST (A_B2_simple2 0 ${HDF_FILE1}.h5 -vp -s simple -d /A/B2/simple2)
ADD_H5_TEST (C_D_simple 0 ${HDF_FILE1}.h5 -vp -s /grp_dsets/simple -d /C/D/simple)
- ADD_H5_TEST (E_F_grp_dsets 0 ${HDF_FILE1}.h5 -vp -s /grp_dsets -d /E/F/grp_dsets)
- ADD_H5_TEST (G_H_grp_nested 0 ${HDF_FILE1}.h5 -vp -s /grp_nested -d /G/H/grp_nested)
+ if (USE_FILTER_DEFLATE)
+ ADD_H5_TEST (E_F_grp_dsets 0 ${HDF_FILE1}.h5 -vp -s /grp_dsets -d /E/F/grp_dsets)
+ ADD_H5_TEST (G_H_grp_nested 0 ${HDF_FILE1}.h5 -vp -s /grp_nested -d /G/H/grp_nested)
+ else ()
+ ADD_H5_TEST (E_F_grp_dsets 2 ${HDF_FILE1}.h5 -vp -s /grp_dsets -d /E/F/grp_dsets)
+ ADD_H5_TEST (G_H_grp_nested 2 ${HDF_FILE1}.h5 -vp -s /grp_nested -d /G/H/grp_nested)
+ endif ()
############# COPY REFERENCES ##############
@@ -374,4 +416,8 @@
# - dataset
ADD_H5_TEST_SAME (samefile1 0 ${HDF_FILE1}.h5 /simple /simple -v -s /simple -d /simple_cp)
# - group with some datasets
- ADD_H5_TEST_SAME (samefile2 0 ${HDF_FILE1}.h5 /grp_dsets /grp_dsets -v -s /grp_dsets -d /grp_dsets_cp)
+ if (USE_FILTER_DEFLATE)
+ ADD_H5_TEST_SAME (samefile2 0 ${HDF_FILE1}.h5 /grp_dsets /grp_dsets -v -s /grp_dsets -d /grp_dsets_cp)
+ else ()
+ ADD_H5_TEST_SAME (samefile2 2 ${HDF_FILE1}.h5 /grp_dsets /grp_dsets -v -s /grp_dsets -d /grp_dsets_cp)
+ endif ()
diff --git a/tools/h5copy/testh5copy.sh.in b/tools/h5copy/testh5copy.sh.in
index d8abfd9..449ae1a 100644
--- a/tools/h5copy/testh5copy.sh.in
+++ b/tools/h5copy/testh5copy.sh.in
@@ -21,6 +21,10 @@
srcdir=@srcdir@
+# Determine which filters are available
+USE_FILTER_SZIP="@USE_FILTER_SZIP@"
+USE_FILTER_DEFLATE="@USE_FILTER_DEFLATE@"
+
# source dirs
SRC_TOOLS="$srcdir/.."
SRC_TOOLS_TESTFILES="$SRC_TOOLS/testfiles"
@@ -128,7 +132,7 @@ CLEAN_TESTFILES_AND_TESTDIR()
# skip rm if srcdir is same as destdir
# this occurs when build/test performed in source dir and
# make cp fail
- SDIR=`$DIRNAME $tstfile`
+ SDIR=$SRC_H5COPY_TESTFILES
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
@@ -487,7 +491,9 @@ COPY_OBJECTS()
TOOLTEST -i $TESTFILE -o $TESTDIR/chunk.out.h5 -v -s chunk -d chunk
TOOLTEST -i $TESTFILE -o $TESTDIR/compact.out.h5 -v -s compact -d compact
TOOLTEST -i $TESTFILE -o $TESTDIR/compound.out.h5 -v -s compound -d compound
+if test $USE_FILTER_DEFLATE = "yes" ; then
TOOLTEST -i $TESTFILE -o $TESTDIR/compressed.out.h5 -v -s compressed -d compressed
+fi
TOOLTEST -i $TESTFILE -o $TESTDIR/named_vl.out.h5 -v -s named_vl -d named_vl
TOOLTEST -i $TESTFILE -o $TESTDIR/nested_vl.out.h5 -v -s nested_vl -d nested_vl
TOOLTEST -i $TESTFILE -o $TESTDIR/dset_attr.out.h5 -v -s /dset_attr -d /dset_attr
@@ -499,16 +505,19 @@ COPY_OBJECTS()
TOOLTEST -i $TESTFILE -o $TESTDIR/dsrename.out.h5 -v -s compound -d rename
echo "Test copying empty, 'full' & 'nested' groups"
+if test $USE_FILTER_DEFLATE = "yes" ; then
TOOLTEST -i $TESTFILE -o $TESTDIR/grp_empty.out.h5 -v -s grp_empty -d grp_empty
+fi
TOOLTEST -i $TESTFILE -o $TESTDIR/grp_dsets.out.h5 -v -s grp_dsets -d grp_dsets
TOOLTEST -i $TESTFILE -o $TESTDIR/grp_nested.out.h5 -v -s grp_nested -d grp_nested
TOOLTEST -i $TESTFILE -o $TESTDIR/grp_attr.out.h5 -v -s grp_attr -d grp_attr
+if test $USE_FILTER_DEFLATE = "yes" ; then
echo "Test copying dataset within group in source file to group in destination"
TOOLTEST_PREFILL -i $TESTFILE -o $TESTDIR/simple_group.out.h5 grp_dsets grp_dsets /grp_dsets/simple /grp_dsets/simple_group
-
echo "Test copying & renaming group"
TOOLTEST -i $TESTFILE -o $TESTDIR/grp_rename.out.h5 -v -s grp_dsets -d grp_rename
+fi
echo "Test copying 'full' group hierarchy into group in destination file"
TOOLTEST_PREFILL -i $TESTFILE -o $TESTDIR/grp_dsets_rename.out.h5 grp_dsets grp_rename grp_dsets /grp_rename/grp_dsets
@@ -517,8 +526,10 @@ COPY_OBJECTS()
TOOLTEST -i $TESTFILE -o $TESTDIR/A_B1_simple.out.h5 -vp -s simple -d /A/B1/simple
TOOLTEST -i $TESTFILE -o $TESTDIR/A_B2_simple2.out.h5 -vp -s simple -d /A/B2/simple2
TOOLTEST -i $TESTFILE -o $TESTDIR/C_D_simple.out.h5 -vp -s /grp_dsets/simple -d /C/D/simple
+if test $USE_FILTER_DEFLATE = "yes" ; then
TOOLTEST -i $TESTFILE -o $TESTDIR/E_F_grp_dsets.out.h5 -vp -s /grp_dsets -d /E/F/grp_dsets
TOOLTEST -i $TESTFILE -o $TESTDIR/G_H_grp_nested.out.h5 -vp -s /grp_nested -d /G/H/grp_nested
+fi
}
# Copy references in various way.
@@ -579,8 +590,10 @@ TEST_MISC()
TOOLTEST_FAIL 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
+ TOOLTEST_SAME -i $TESTFILE -o $TESTDIR/samefile1.out.h5 /simple /simple_cp
+if test $USE_FILTER_DEFLATE = "yes" ; then
TOOLTEST_SAME -i $TESTFILE -o $TESTDIR/samefile2.out.h5 /grp_dsets /grp_dsets_cp
+fi
}
##############################################################################
diff --git a/tools/h5diff/CMakeTests.cmake b/tools/h5diff/CMakeTests.cmake
index 91e0cab..a9ec683 100644
--- a/tools/h5diff/CMakeTests.cmake
+++ b/tools/h5diff/CMakeTests.cmake
@@ -335,13 +335,18 @@
-D "TEST_ARGS:STRING=${ARGN}"
-D "TEST_FOLDER=${PROJECT_BINARY_DIR}/PAR/testfiles"
-D "TEST_OUTPUT=${resultfile}.out"
- -D "TEST_EXPECT=${resultcode}"
+ -D "TEST_EXPECT=0"
-D "TEST_REFERENCE=${resultfile}.txt"
-# -D "TEST_APPEND=EXIT CODE: [0-9]"
-# -D "TEST_REF_FILTER=EXIT CODE: 0"
- -D "TEST_SKIP_COMPARE=TRUE"
+ -D "TEST_APPEND=EXIT CODE:"
+ -D "TEST_REF_APPEND=EXIT CODE: [0-9]"
+ -D "TEST_REF_FILTER=EXIT CODE: 0"
+ -D "TEST_SORT_COMPARE=TRUE"
-P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
)
+ if (NOT "${last_test}" STREQUAL "")
+ set_tests_properties (PH5DIFF-${resultfile} PROPERTIES DEPENDS ${last_test})
+ endif ()
+ set (last_test "PH5DIFF-${resultfile}")
endif ()
ENDMACRO ()
diff --git a/tools/h5import/CMakeTests.cmake b/tools/h5import/CMakeTests.cmake
index d1f1681..4e6e171 100644
--- a/tools/h5import/CMakeTests.cmake
+++ b/tools/h5import/CMakeTests.cmake
@@ -93,10 +93,6 @@
COMMAND ${CMAKE_COMMAND}
-E remove
${testfile}
- ${testfile}.new
- ${testfile}.new.err
- ${testfile}.out
- ${testfile}.out.err
)
set_tests_properties (H5IMPORT-${testname}-clear-objects PROPERTIES DEPENDS H5IMPORT-h5importtest)
@@ -141,12 +137,6 @@
-E remove
d${testfile}
d${testfile}.bin
- d${testfile}.imp
- d${testfile}.imp.err
- d${testfile}.dmp
- d${testfile}.dmp.err
- d${testfile}.dff
- d${testfile}.dff.err
)
set_tests_properties (H5IMPORT-DUMP-${testname}-clear-objects PROPERTIES DEPENDS H5IMPORT-h5importtest)
@@ -434,17 +424,17 @@
ADD_H5_TEST (BINARY_F64 binfp64.bin testfiles/binfp64.conf binfp64.h5)
if (NOT USE_FILTER_DEFLATE)
ADD_H5_SKIP_DUMPTEST (BINARY_F64 "/fp/bin/64-bit" binfp64.h5 BINARY)
- else (NOT USE_FILTER_DEFLATE)
+ else ()
ADD_H5_DUMPTEST (BINARY_F64 "/fp/bin/64-bit" binfp64.h5 BINARY)
- endif (NOT USE_FILTER_DEFLATE)
+ endif ()
# ----- TESTING "BINARY I8 - rank 3 - Output I16LE + Chunked+Extended+Compressed "
ADD_H5_TEST (BINARY_I8 binin8.bin testfiles/binin8.conf binin8.h5)
if (NOT USE_FILTER_DEFLATE)
ADD_H5_SKIP_DUMPTEST (BINARY_I8 "/int/bin/8-bit" binin8.h5 BINARY)
- else (NOT USE_FILTER_DEFLATE)
+ else ()
ADD_H5_DUMPTEST (BINARY_I8 "/int/bin/8-bit" binin8.h5 BINARY)
- endif (NOT USE_FILTER_DEFLATE)
+ endif ()
# ----- TESTING "BINARY I16 - rank 3 - Output order LE + CHUNKED + extended "
ADD_H5_TEST (BINARY_I16 binin16.bin testfiles/binin16.conf binin16.h5)
diff --git a/tools/h5import/h5importtestutil.sh.in b/tools/h5import/h5importtestutil.sh.in
index e50ddac..6e747e7 100644
--- a/tools/h5import/h5importtestutil.sh.in
+++ b/tools/h5import/h5importtestutil.sh.in
@@ -153,7 +153,7 @@ CLEAN_TESTFILES_AND_TESTDIR()
# skip rm if srcdir is same as destdir
# this occurs when build/test performed in source dir and
# make cp fail
- SDIR=`$DIRNAME $tstfile`
+ SDIR=$SRC_H5IMPORT_TESTFILES
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
@@ -161,6 +161,9 @@ CLEAN_TESTFILES_AND_TESTDIR()
fi
}
+# Print a line-line message left justified in a field of 70 characters
+# beginning with the word "Testing".
+#
TESTING() {
SPACES=" "
echo "Testing $* $SPACES" | cut -c1-70 | tr -d '\012'
diff --git a/tools/h5jam/CMakeTests.cmake b/tools/h5jam/CMakeTests.cmake
index 3752e55..f82e0d6 100644
--- a/tools/h5jam/CMakeTests.cmake
+++ b/tools/h5jam/CMakeTests.cmake
@@ -49,13 +49,6 @@
endif ()
else ()
add_test (
- NAME H5JAM-${expectfile}-clear-objects
- COMMAND ${CMAKE_COMMAND}
- -E remove
- ${expectfile}.out
- ${expectfile}.out.err
- )
- add_test (
NAME H5JAM-${expectfile}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:h5jam>"
@@ -66,7 +59,6 @@
-D "TEST_REFERENCE=testfiles/${expectfile}.txt"
-P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
)
- set_tests_properties (H5JAM-${expectfile} PROPERTIES DEPENDS H5JAM-${expectfile}-clear-objects)
endif ()
ENDMACRO ()
@@ -83,13 +75,6 @@
endif ()
else ()
add_test (
- NAME H5JAM-UNJAM-${expectfile}-clear-objects
- COMMAND ${CMAKE_COMMAND}
- -E remove
- ${expectfile}.out
- ${expectfile}.out.err
- )
- add_test (
NAME H5JAM-UNJAM-${expectfile}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:h5unjam>"
@@ -100,7 +85,6 @@
-D "TEST_REFERENCE=testfiles/${expectfile}.txt"
-P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
)
- set_tests_properties (H5JAM-UNJAM-${expectfile} PROPERTIES DEPENDS H5JAM-UNJAM-${expectfile}-clear-objects)
endif ()
ENDMACRO ()
@@ -108,16 +92,6 @@
# If using memchecker add tests without using scripts
if (NOT HDF5_ENABLE_USING_MEMCHECKER)
add_test (
- NAME H5JAM-${testname}-CHECKFILE-clear-objects
- COMMAND ${CMAKE_COMMAND}
- -E remove
- ${actual}.new
- ${actual}.new.err
- ${actual}.out
- ${actual}.out.err
- )
- set_tests_properties (H5JAM-${testname}-CHECKFILE-clear-objects PROPERTIES DEPENDS ${testdepends})
- add_test (
NAME H5JAM-${testname}-CHECKFILE-H5DMP
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:h5dump>"
@@ -129,7 +103,7 @@
-D "TEST_SKIP_COMPARE=TRUE"
-P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
)
- set_tests_properties (H5JAM-${testname}-CHECKFILE-H5DMP PROPERTIES DEPENDS H5JAM-${testname}-CHECKFILE-clear-objects)
+ set_tests_properties (H5JAM-${testname}-CHECKFILE-H5DMP PROPERTIES DEPENDS ${testdepends})
add_test (
NAME H5JAM-${testname}-CHECKFILE-H5DMP_CMP
COMMAND "${CMAKE_COMMAND}"
@@ -174,11 +148,6 @@
else ()
if (NOT "${ARGN}" STREQUAL "--delete")
add_test (
- NAME H5JAM-${testname}-UNJAM_D-clear-objects
- COMMAND ${CMAKE_COMMAND} -E remove ${outfile}.ufile.txt ${outfile}.ufile.txt.err
- )
- set_tests_properties (H5JAM-${testname}-UNJAM_D-clear-objects PROPERTIES DEPENDS H5JAM-${testname}-UNJAM-clear-objects)
- add_test (
NAME H5JAM-${testname}-UNJAM
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:h5unjam>"
@@ -189,7 +158,7 @@
-D "TEST_SKIP_COMPARE=TRUE"
-P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
)
- set_tests_properties (H5JAM-${testname}-UNJAM PROPERTIES DEPENDS H5JAM-${testname}-UNJAM_D-clear-objects)
+ set_tests_properties (H5JAM-${testname}-UNJAM PROPERTIES DEPENDS H5JAM-${testname}-UNJAM-clear-objects)
set (compare_test "${outfile}.ufile.txt")
else ()
add_test (NAME H5JAM-${testname}-UNJAM COMMAND $<TARGET_FILE:h5unjam> -i ${infile} -o ${outfile})
diff --git a/tools/h5jam/testh5jam.sh.in b/tools/h5jam/testh5jam.sh.in
index 1664d6b..d8c9274 100644
--- a/tools/h5jam/testh5jam.sh.in
+++ b/tools/h5jam/testh5jam.sh.in
@@ -126,7 +126,7 @@ CLEAN_TESTFILES_AND_TESTDIR()
# skip rm if srcdir is same as destdir
# this occurs when build/test performed in source dir and
# make cp fail
- SDIR=`$DIRNAME $tstfile`
+ SDIR=$SRC_H5JAM_TESTFILES
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
diff --git a/tools/h5ls/CMakeTests.cmake b/tools/h5ls/CMakeTests.cmake
index f995c74..ad54cc2 100644
--- a/tools/h5ls/CMakeTests.cmake
+++ b/tools/h5ls/CMakeTests.cmake
@@ -431,8 +431,14 @@
ADD_H5_TEST (tdataregle 0 -v tdatareg.h5)
endif ()
+# test for file with datasets that use Fixed Array chunk indices
+ if (USE_FILTER_DEFLATE)
+ # data read internal filters
+ ADD_H5_TEST (tdset_idx 0 -w80 -d tdset_idx.h5)
+ endif (USE_FILTER_DEFLATE)
+
+
##############################################################################
### P L U G I N T E S T S
##############################################################################
ADD_H5_UD_TEST (h5ls_plugin_test 0 tudfilter -w80 -d tudfilter.h5)
-
diff --git a/tools/h5repack/CMakeTests.cmake b/tools/h5repack/CMakeTests.cmake
index ebc2055..fa454ce 100644
--- a/tools/h5repack/CMakeTests.cmake
+++ b/tools/h5repack/CMakeTests.cmake
@@ -120,12 +120,6 @@
set (last_test "H5REPACK-${testname}")
else ()
add_test (
- NAME H5REPACK-h5repack-${testname}-clear-objects
- COMMAND ${CMAKE_COMMAND}
- -E remove h5repack-${testname}.out h5repack-${testname}.out.err
- )
- set_tests_properties (H5REPACK-h5repack-${testname}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles")
- add_test (
NAME H5REPACK-h5repack-${testname}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:h5repack>"
@@ -136,7 +130,6 @@
-D "TEST_REFERENCE=h5repack-${testname}.txt"
-P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
)
- set_tests_properties (H5REPACK-h5repack-${testname} PROPERTIES DEPENDS "H5REPACK-h5repack-${testname}-clear-objects")
endif ()
ENDMACRO ()
@@ -346,10 +339,6 @@
COMMAND ${CMAKE_COMMAND}
-E remove
testfiles/out-${testname}.${resultfile}
- testfiles/${testname}.${resultfile}.out
- testfiles/${testname}.${resultfile}.out.err
- testfiles/${resultfile}-${testname}.out
- testfiles/${resultfile}-${testname}.out.err
)
add_test (
NAME H5REPACK_UD-${testname}
@@ -961,7 +950,10 @@
ADD_H5_TEST (upgrade_layout "TEST" ${FILE14})
# test for datum size > H5TOOLS_MALLOCSIZE
- ADD_H5_TEST (gt_mallocsize "TEST" ${FILE1} -f GZIP=1)
+ if (NOT USE_FILTER_DEFLATE)
+ set (TESTTYPE "SKIP")
+ endif ()
+ ADD_H5_TEST (gt_mallocsize ${TESTTYPE} ${FILE1} -f GZIP=1)
# Check repacking file with committed datatypes in odd configurations
ADD_H5_TEST (committed_dt "TEST" ${FILE15})
@@ -997,12 +989,12 @@
set (TESTRETVAL 255)
if (WIN32)
set (TESTRETVAL -1)
- endif()
+ endif ()
ADD_H5_CMP_TEST (plugin_zero "" "TEST" ${TESTRETVAL} h5repack_layout.h5 -v -f UD=250,0)
if (HDF5_TEST_VFD)
# Run test with different Virtual File Driver
foreach (vfd ${VFD_LIST})
ADD_VFD_TEST (${vfd} 0)
- endforeach (vfd ${VFD_LIST})
+ endforeach ()
endif ()
diff --git a/tools/h5repack/h5repack.sh.in b/tools/h5repack/h5repack.sh.in
index de55f20..966aedf 100644
--- a/tools/h5repack/h5repack.sh.in
+++ b/tools/h5repack/h5repack.sh.in
@@ -39,6 +39,8 @@ H5DUMP=../h5dump/h5dump # The h5dump tool name
H5DUMP_BIN=`pwd`/$H5DUMP # The path of the h5dump tool binary
RM='rm -rf'
+CMP='cmp'
+DIFF='diff -c'
GREP='grep'
CP='cp'
DIRNAME='dirname'
@@ -165,7 +167,7 @@ CLEAN_TESTFILES_AND_TESTDIR()
# skip rm if srcdir is same as destdir
# this occurs when build/test performed in source dir and
# make cp fail
- SDIR=`$DIRNAME $tstfile`
+ SDIR=$SRC_H5REPACK_TESTFILES
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
diff --git a/tools/h5stat/CMakeTests.cmake b/tools/h5stat/CMakeTests.cmake
index 00ce250..a3db0fc 100644
--- a/tools/h5stat/CMakeTests.cmake
+++ b/tools/h5stat/CMakeTests.cmake
@@ -75,11 +75,6 @@
endif ()
else (HDF5_ENABLE_USING_MEMCHECKER)
add_test (
- NAME H5STAT-${resultfile}-clear-objects
- COMMAND ${CMAKE_COMMAND}
- -E remove ${resultfile}.out ${resultfile}.out.err
- )
- add_test (
NAME H5STAT-${resultfile}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:h5stat>"
@@ -90,7 +85,6 @@
-D "TEST_REFERENCE=${resultfile}.ddl"
-P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
)
- set_tests_properties (H5STAT-${resultfile} PROPERTIES DEPENDS "H5STAT-${resultfile}-clear-objects")
endif ()
ENDMACRO ()
@@ -194,7 +188,7 @@
ADD_H5_TEST (h5stat_filters-UD 0 -D h5stat_filters.h5)
ADD_H5_TEST (h5stat_filters-UT 0 -T h5stat_filters.h5)
# h5stat_tsohm.h5 is a copy of ../../../test/tsohm.h5 generated by tsohm.c
-# as of release 1.8.0-alpha4
+# as of release 1.8.7-snap0 (on a 64-bit machine)
ADD_H5_TEST (h5stat_tsohm 0 h5stat_tsohm.h5)
# h5stat_newgrat.h5 is generated by h5stat_gentest.c
ADD_H5_TEST (h5stat_newgrat 0 h5stat_newgrat.h5)
diff --git a/tools/h5stat/testh5stat.sh.in b/tools/h5stat/testh5stat.sh.in
index 4d698da..9ceb943 100644
--- a/tools/h5stat/testh5stat.sh.in
+++ b/tools/h5stat/testh5stat.sh.in
@@ -149,7 +149,7 @@ CLEAN_TESTFILES_AND_TESTDIR()
# skip rm if srcdir is same as destdir
# this occurs when build/test performed in source dir and
# make cp fail
- SDIR=`$DIRNAME $tstfile`
+ SDIR=$SRC_H5STAT_TESTFILES
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
diff --git a/tools/misc/CMakeTests.cmake b/tools/misc/CMakeTests.cmake
index d065b63..ee60bf8 100644
--- a/tools/misc/CMakeTests.cmake
+++ b/tools/misc/CMakeTests.cmake
@@ -76,8 +76,6 @@
COMMAND ${CMAKE_COMMAND}
-E remove
${resultfile}.h5
- ${resultfile}.out
- ${resultfile}.out.err
)
set_tests_properties (H5MKGRP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles")
endif ()
@@ -118,8 +116,6 @@
COMMAND ${CMAKE_COMMAND}
-E remove
${resultfile}.h5
- ${resultfile}.out
- ${resultfile}.out.err
)
set_tests_properties (H5MKGRP_CMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles")
add_test (
diff --git a/tools/misc/testh5mkgrp.sh.in b/tools/misc/testh5mkgrp.sh.in
index 190e824..a0413e1 100644
--- a/tools/misc/testh5mkgrp.sh.in
+++ b/tools/misc/testh5mkgrp.sh.in
@@ -117,7 +117,7 @@ CLEAN_TESTFILES_AND_TESTDIR()
# skip rm if srcdir is same as destdir
# this occurs when build/test performed in source dir and
# make cp fail
- SDIR=`$DIRNAME $tstfile`
+ SDIR=$SRC_H5MKGRP_TESTFILES
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