summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2012-07-26 13:54:06 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2012-07-26 13:54:06 (GMT)
commitaeaab5204b97a5912a26049fdfe95c7f6d962f93 (patch)
treeb2c68947daa4a88694854b21b157888338362ef3 /tools
parent389e928176aae700eddefcb1983e9ff1a7665046 (diff)
downloadhdf5-aeaab5204b97a5912a26049fdfe95c7f6d962f93.zip
hdf5-aeaab5204b97a5912a26049fdfe95c7f6d962f93.tar.gz
hdf5-aeaab5204b97a5912a26049fdfe95c7f6d962f93.tar.bz2
[svn-r22605] Skip test that require h5diff to compress when the DEFALTE filter is unavailable
Diffstat (limited to 'tools')
-rw-r--r--tools/h5import/CMakeLists.txt25
-rwxr-xr-xtools/h5import/h5importtestutil.sh21
2 files changed, 42 insertions, 4 deletions
diff --git a/tools/h5import/CMakeLists.txt b/tools/h5import/CMakeLists.txt
index 5bbcf02..0188852 100644
--- a/tools/h5import/CMakeLists.txt
+++ b/tools/h5import/CMakeLists.txt
@@ -263,6 +263,19 @@ IF (BUILD_TESTING)
ENDIF (NOT HDF5_ENABLE_USING_MEMCHECKER)
ENDMACRO (ADD_H5_DUMPTEST testname datasetname testfile)
+ MACRO (ADD_H5_SKIP_DUMPTEST testname datasetname testfile)
+ ADD_TEST (
+ NAME H5IMPORT-DUMP-${testname}-SKIPPED
+ COMMAND ${CMAKE_COMMAND} -E echo "SKIP ${testname} ${datasetname} ${testfile} --- DEFLATE filter not available"
+ )
+ ENDIF (NOT HDF5_ENABLE_USING_MEMCHECKER)
+ ENDMACRO (ADD_H5_SKIP_DUMPTEST testname datasetname testfile)
+
+ # --------------------------------------------------------------------
+ # Determine if filter is available for h5diff
+ # --------------------------------------------------------------------
+ SET (USE_FILTER_DEFLATE H5_HAVE_FILTER_DEFLATE)
+
##############################################################################
##############################################################################
### T H E T E S T S ###
@@ -314,11 +327,19 @@ IF (BUILD_TESTING)
# ----- TESTING "BINARY F64 - rank 3 - Output LE+CHUNKED+Extended+Compressed "
ADD_H5_TEST (BINARY_F64 binfp64.bin testfiles/binfp64.conf binfp64.h5)
- ADD_H5_DUMPTEST (BINARY_F64 "/fp/bin/64-bit" binfp64.h5 BINARY)
+ IF (NOT USE_FILTER_DEFLATE)
+ ADD_H5_SKIP_DUMPTEST (BINARY_F64 "/fp/bin/64-bit" binfp64.h5 BINARY)
+ ELSE (NOT USE_FILTER_DEFLATE)
+ ADD_H5_DUMPTEST (BINARY_F64 "/fp/bin/64-bit" binfp64.h5 BINARY)
+ ENDIF (NOT USE_FILTER_DEFLATE)
# ----- TESTING "BINARY I8 - rank 3 - Output I16LE + Chunked+Extended+Compressed "
ADD_H5_TEST (BINARY_I8 binin8.bin testfiles/binin8.conf binin8.h5)
- ADD_H5_DUMPTEST (BINARY_I8 "/int/bin/8-bit" binin8.h5 BINARY)
+ IF (NOT USE_FILTER_DEFLATE)
+ ADD_H5_SKIP_DUMPTEST (BINARY_I8 "/int/bin/8-bit" binin8.h5 BINARY)
+ ELSE (NOT USE_FILTER_DEFLATE)
+ ADD_H5_DUMPTEST (BINARY_I8 "/int/bin/8-bit" binin8.h5 BINARY)
+ ENDIF (NOT USE_FILTER_DEFLATE)
# ----- 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 b/tools/h5import/h5importtestutil.sh
index 5be3118..45a360a 100755
--- a/tools/h5import/h5importtestutil.sh
+++ b/tools/h5import/h5importtestutil.sh
@@ -16,6 +16,9 @@
# HDF Utilities Test script
# Usage: h5importtestutil.sh [machine-type]
+# Determine which filters are available
+USE_FILTER_DEFLATE="@USE_FILTER_DEFLATE@"
+
TESTNAME=h5import
EXIT_SUCCESS=0
EXIT_FAILURE=1
@@ -141,6 +144,12 @@ TESTING() {
echo "Testing $* $SPACES" | cut -c1-70 | tr -d '\012'
}
+# Print a "SKIP" message
+SKIP() {
+ TESTING $TESTNAME $@
+ echo " -SKIP-"
+}
+
TOOLTEST()
{
err=0
@@ -273,13 +282,21 @@ TOOLTEST $TESTDIR/txtfp64.txt -c $TESTDIR/txtfp64.conf -o txtfp64.h5
TESTING "BINARY F64 - rank 3 - Output LE+CHUNKED+Extended+Compressed "
TOOLTEST binfp64.bin -c $TESTDIR/binfp64.conf -o binfp64.h5
TESTING "H5DUMP-BINARY F64 - rank 3 - Output LE+CHUNKED+Extended+Compressed "
-TOOLTEST2 "/fp/bin/64-bit" binfp64.h5
+if test $USE_FILTER_DEFLATE != "yes"; then
+ SKIP "/fp/bin/64-bit" binfp64.h5
+else
+ TOOLTEST2 "/fp/bin/64-bit" binfp64.h5
+fi
TESTING "BINARY I8 - rank 3 - Output I16LE + Chunked+Extended+Compressed "
TOOLTEST binin8.bin -c $TESTDIR/binin8.conf -o binin8.h5
TESTING "H5DUMP-BINARY I8 - rank 3 - Output I16LE + Chunked+Extended+Compressed "
-TOOLTEST2 "/int/bin/8-bit" binin8.h5
+if test $USE_FILTER_DEFLATE != "yes"; then
+ SKIP "/int/bin/8-bit" binin8.h5
+else
+ TOOLTEST2 "/int/bin/8-bit" binin8.h5
+fi
TESTING "BINARY I16 - rank 3 - Output order LE + CHUNKED + extended "
TOOLTEST binin16.bin -c $TESTDIR/binin16.conf -o binin16.h5