summaryrefslogtreecommitdiffstats
path: root/tools/h5dump/testh5dump.sh.in
diff options
context:
space:
mode:
Diffstat (limited to 'tools/h5dump/testh5dump.sh.in')
-rw-r--r--tools/h5dump/testh5dump.sh.in151
1 files changed, 71 insertions, 80 deletions
diff --git a/tools/h5dump/testh5dump.sh.in b/tools/h5dump/testh5dump.sh.in
index f8da64b..9406df7 100644
--- a/tools/h5dump/testh5dump.sh.in
+++ b/tools/h5dump/testh5dump.sh.in
@@ -23,9 +23,6 @@ USE_FILTER_FLETCHER32="@USE_FILTER_FLETCHER32@"
USE_FILTER_NBIT="@USE_FILTER_NBIT@"
USE_FILTER_SCALEOFFSET="@USE_FILTER_SCALEOFFSET@"
-# Determine if H5dump packed bits feature is included
-Have_Packed_Bits="@PACKED_BITS@"
-
TESTNAME=h5dump
EXIT_SUCCESS=0
EXIT_FAILURE=1
@@ -82,12 +79,12 @@ TOOLTEST() {
echo "#############################"
echo "Expected output for '$DUMPER $@'"
echo "#############################"
- cd $srcdir/../testfiles
- $RUNSERIAL $DUMPER_BIN $@
+ cd $srcdir/../testfiles
+ $RUNSERIAL $DUMPER_BIN $@
) >$actual 2>$actual_err
cat $actual_err >> $actual
- if [ ! -f $expect ]; then
+ if [ ! -f $expect ]; then
# Create the expect file if it doesn't yet exist.
echo " CREATED"
cp $actual $expect
@@ -96,13 +93,13 @@ TOOLTEST() {
else
echo "*FAILED*"
echo " Expected result (*.ddl) differs from actual result (*.out)"
- nerrors="`expr $nerrors + 1`"
- test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /'
+ 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
+ rm -f $actual $actual_err
fi
}
@@ -121,12 +118,12 @@ TOOLTEST1() {
TESTING $DUMPER $@
(
- cd $srcdir/../testfiles
- $RUNSERIAL $DUMPER_BIN $@
+ cd $srcdir/../testfiles
+ $RUNSERIAL $DUMPER_BIN $@
) >$actual 2>$actual_err
cat $actual_err >> $actual
- if [ ! -f $expect ]; then
+ if [ ! -f $expect ]; then
# Create the expect file if it doesn't yet exist.
echo " CREATED"
cp $actual $expect
@@ -135,13 +132,13 @@ TOOLTEST1() {
else
echo "*FAILED*"
echo " Expected result (*.ddl) differs from actual result (*.out)"
- nerrors="`expr $nerrors + 1`"
- test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /'
+ 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
+ rm -f $actual $actual_err
fi
}
@@ -250,8 +247,8 @@ TOOLTEST3() {
# Print a "SKIP" message
SKIP() {
- TESTING $DUMPER $@
- echo " -SKIP-"
+ TESTING $DUMPER $@
+ echo " -SKIP-"
}
# Print a line-line message left justified in a field of 70 characters
@@ -268,8 +265,8 @@ DIFFTEST()
{
PRINT_H5DIFF $@
(
- cd $srcdir/../testfiles
- $RUNSERIAL $H5DIFF_BIN "$@" -q
+ cd $srcdir/../testfiles
+ $RUNSERIAL $H5DIFF_BIN "$@" -q
)
RET=$?
if [ $RET != 0 ] ; then
@@ -301,8 +298,8 @@ IMPORTTEST()
PRINT_H5IMPORT $@
(
- cd $srcdir/../testfiles
- $RUNSERIAL $H5IMPORT_BIN "$@"
+ cd $srcdir/../testfiles
+ $RUNSERIAL $H5IMPORT_BIN "$@"
)
RET=$?
if [ $RET != 0 ] ; then
@@ -317,7 +314,7 @@ IMPORTTEST()
##############################################################################
##############################################################################
-### T H E T E S T S ###
+### T H E T E S T S ###
##############################################################################
##############################################################################
@@ -646,12 +643,6 @@ TOOLTEST3 filter_fail.ddl --enable-error-stack filter_fail.h5
TOOLTEST1 tall-6.ddl -y -o $TESTDIR/data -d /g1/g1.1/dset1.1.1 tall.h5
# test for dataset packed bits
-# Set up xCMD to test or skip.
-if test "$Have_Packed_Bits" = "yes"; then
- xCMD=TOOLTEST
-else
- xCMD=SKIP
-fi
# Limits:
# Maximum number of packed bits is 8 (for now).
# Maximum integer size is 64 (for now).
@@ -661,72 +652,72 @@ fi
# Normal operation on both signed and unsigned int datasets.
# Sanity check
# Their rawdata output should be the same.
-$xCMD tpbitsSignedWhole.ddl -d /DS08BITS -M 0,8 packedbits.h5
-$xCMD tpbitsUnsignedWhole.ddl -d /DU08BITS -M 0,8 packedbits.h5
-$xCMD tpbitsSignedIntWhole.ddl -d /DS16BITS -M 0,16 packedbits.h5
-$xCMD tpbitsUnsignedIntWhole.ddl -d /DU16BITS -M 0,16 packedbits.h5
-$xCMD tpbitsSignedLongWhole.ddl -d /DS32BITS -M 0,32 packedbits.h5
-$xCMD tpbitsUnsignedLongWhole.ddl -d /DU32BITS -M 0,32 packedbits.h5
-$xCMD tpbitsSignedLongLongWhole.ddl -d /DS64BITS -M 0,64 packedbits.h5
-$xCMD tpbitsUnsignedLongLongWhole.ddl -d /DU64BITS -M 0,64 packedbits.h5
-$xCMD tpbitsSignedLongLongWhole63.ddl -d /DS64BITS -M 0,63 packedbits.h5
-$xCMD tpbitsUnsignedLongLongWhole63.ddl -d /DU64BITS -M 0,63 packedbits.h5
-$xCMD tpbitsSignedLongLongWhole1.ddl -d /DS64BITS -M 1,63 packedbits.h5
-$xCMD tpbitsUnsignedLongLongWhole1.ddl -d /DU64BITS -M 1,63 packedbits.h5
+TOOLTEST tpbitsSignedWhole.ddl -d /DS08BITS -M 0,8 packedbits.h5
+TOOLTEST tpbitsUnsignedWhole.ddl -d /DU08BITS -M 0,8 packedbits.h5
+TOOLTEST tpbitsSignedIntWhole.ddl -d /DS16BITS -M 0,16 packedbits.h5
+TOOLTEST tpbitsUnsignedIntWhole.ddl -d /DU16BITS -M 0,16 packedbits.h5
+TOOLTEST tpbitsSignedLongWhole.ddl -d /DS32BITS -M 0,32 packedbits.h5
+TOOLTEST tpbitsUnsignedLongWhole.ddl -d /DU32BITS -M 0,32 packedbits.h5
+TOOLTEST tpbitsSignedLongLongWhole.ddl -d /DS64BITS -M 0,64 packedbits.h5
+TOOLTEST tpbitsUnsignedLongLongWhole.ddl -d /DU64BITS -M 0,64 packedbits.h5
+TOOLTEST tpbitsSignedLongLongWhole63.ddl -d /DS64BITS -M 0,63 packedbits.h5
+TOOLTEST tpbitsUnsignedLongLongWhole63.ddl -d /DU64BITS -M 0,63 packedbits.h5
+TOOLTEST tpbitsSignedLongLongWhole1.ddl -d /DS64BITS -M 1,63 packedbits.h5
+TOOLTEST tpbitsUnsignedLongLongWhole1.ddl -d /DU64BITS -M 1,63 packedbits.h5
# Half sections
-$xCMD tpbitsSigned4.ddl -d /DS08BITS -M 0,4,4,4 packedbits.h5
-$xCMD tpbitsUnsigned4.ddl -d /DU08BITS -M 0,4,4,4 packedbits.h5
-$xCMD tpbitsSignedInt8.ddl -d /DS16BITS -M 0,8,8,8 packedbits.h5
-$xCMD tpbitsUnsignedInt8.ddl -d /DU16BITS -M 0,8,8,8 packedbits.h5
-$xCMD tpbitsSignedLong16.ddl -d /DS32BITS -M 0,16,16,16 packedbits.h5
-$xCMD tpbitsUnsignedLong16.ddl -d /DU32BITS -M 0,16,16,16 packedbits.h5
-$xCMD tpbitsSignedLongLong32.ddl -d /DS64BITS -M 0,32,32,32 packedbits.h5
-$xCMD tpbitsUnsignedLongLong32.ddl -d /DU64BITS -M 0,32,32,32 packedbits.h5
+TOOLTEST tpbitsSigned4.ddl -d /DS08BITS -M 0,4,4,4 packedbits.h5
+TOOLTEST tpbitsUnsigned4.ddl -d /DU08BITS -M 0,4,4,4 packedbits.h5
+TOOLTEST tpbitsSignedInt8.ddl -d /DS16BITS -M 0,8,8,8 packedbits.h5
+TOOLTEST tpbitsUnsignedInt8.ddl -d /DU16BITS -M 0,8,8,8 packedbits.h5
+TOOLTEST tpbitsSignedLong16.ddl -d /DS32BITS -M 0,16,16,16 packedbits.h5
+TOOLTEST tpbitsUnsignedLong16.ddl -d /DU32BITS -M 0,16,16,16 packedbits.h5
+TOOLTEST tpbitsSignedLongLong32.ddl -d /DS64BITS -M 0,32,32,32 packedbits.h5
+TOOLTEST tpbitsUnsignedLongLong32.ddl -d /DU64BITS -M 0,32,32,32 packedbits.h5
# Quarter sections
-$xCMD tpbitsSigned2.ddl -d /DS08BITS -M 0,2,2,2,4,2,6,2 packedbits.h5
-$xCMD tpbitsUnsigned2.ddl -d /DU08BITS -M 0,2,2,2,4,2,6,2 packedbits.h5
-$xCMD tpbitsSignedInt4.ddl -d /DS16BITS -M 0,4,4,4,8,4,12,4 packedbits.h5
-$xCMD tpbitsUnsignedInt4.ddl -d /DU16BITS -M 0,4,4,4,8,4,12,4 packedbits.h5
-$xCMD tpbitsSignedLong8.ddl -d /DS32BITS -M 0,8,8,8,16,8,24,8 packedbits.h5
-$xCMD tpbitsUnsignedLong8.ddl -d /DU32BITS -M 0,8,8,8,16,8,24,8 packedbits.h5
-$xCMD tpbitsSignedLongLong16.ddl -d /DS64BITS -M 0,16,16,16,32,16,48,16 packedbits.h5
-$xCMD tpbitsUnsignedLongLong16.ddl -d /DU64BITS -M 0,16,16,16,32,16,48,16 packedbits.h5
+TOOLTEST tpbitsSigned2.ddl -d /DS08BITS -M 0,2,2,2,4,2,6,2 packedbits.h5
+TOOLTEST tpbitsUnsigned2.ddl -d /DU08BITS -M 0,2,2,2,4,2,6,2 packedbits.h5
+TOOLTEST tpbitsSignedInt4.ddl -d /DS16BITS -M 0,4,4,4,8,4,12,4 packedbits.h5
+TOOLTEST tpbitsUnsignedInt4.ddl -d /DU16BITS -M 0,4,4,4,8,4,12,4 packedbits.h5
+TOOLTEST tpbitsSignedLong8.ddl -d /DS32BITS -M 0,8,8,8,16,8,24,8 packedbits.h5
+TOOLTEST tpbitsUnsignedLong8.ddl -d /DU32BITS -M 0,8,8,8,16,8,24,8 packedbits.h5
+TOOLTEST tpbitsSignedLongLong16.ddl -d /DS64BITS -M 0,16,16,16,32,16,48,16 packedbits.h5
+TOOLTEST tpbitsUnsignedLongLong16.ddl -d /DU64BITS -M 0,16,16,16,32,16,48,16 packedbits.h5
# Begin and End
-$xCMD tpbitsSigned.ddl -d /DS08BITS -M 0,2,2,6 packedbits.h5
-$xCMD tpbitsUnsigned.ddl -d /DU08BITS -M 0,2,2,6 packedbits.h5
-$xCMD tpbitsSignedInt.ddl -d /DS16BITS -M 0,2,10,6 packedbits.h5
-$xCMD tpbitsUnsignedInt.ddl -d /DU16BITS -M 0,2,10,6 packedbits.h5
-$xCMD tpbitsSignedLong.ddl -d /DS32BITS -M 0,2,26,6 packedbits.h5
-$xCMD tpbitsUnsignedLong.ddl -d /DU32BITS -M 0,2,26,6 packedbits.h5
-$xCMD tpbitsSignedLongLong.ddl -d /DS64BITS -M 0,2,58,6 packedbits.h5
-$xCMD tpbitsUnsignedLongLong.ddl -d /DU64BITS -M 0,2,58,6 packedbits.h5
+TOOLTEST tpbitsSigned.ddl -d /DS08BITS -M 0,2,2,6 packedbits.h5
+TOOLTEST tpbitsUnsigned.ddl -d /DU08BITS -M 0,2,2,6 packedbits.h5
+TOOLTEST tpbitsSignedInt.ddl -d /DS16BITS -M 0,2,10,6 packedbits.h5
+TOOLTEST tpbitsUnsignedInt.ddl -d /DU16BITS -M 0,2,10,6 packedbits.h5
+TOOLTEST tpbitsSignedLong.ddl -d /DS32BITS -M 0,2,26,6 packedbits.h5
+TOOLTEST tpbitsUnsignedLong.ddl -d /DU32BITS -M 0,2,26,6 packedbits.h5
+TOOLTEST tpbitsSignedLongLong.ddl -d /DS64BITS -M 0,2,58,6 packedbits.h5
+TOOLTEST tpbitsUnsignedLongLong.ddl -d /DU64BITS -M 0,2,58,6 packedbits.h5
# Overlapped packed bits.
-$xCMD tpbitsOverlapped.ddl -d /DS08BITS -M 0,1,1,1,2,1,0,3 packedbits.h5
+TOOLTEST tpbitsOverlapped.ddl -d /DS08BITS -M 0,1,1,1,2,1,0,3 packedbits.h5
# Maximum number of packed bits.
-$xCMD tpbitsMax.ddl -d /DS08BITS -M 0,1,1,1,2,1,3,1,4,1,5,1,6,1,7,1 packedbits.h5
+TOOLTEST tpbitsMax.ddl -d /DS08BITS -M 0,1,1,1,2,1,3,1,4,1,5,1,6,1,7,1 packedbits.h5
# Compound type.
-$xCMD tpbitsCompound.ddl -d /dset1 -M 0,1,1,1 tcompound.h5
+TOOLTEST tpbitsCompound.ddl -d /dset1 -M 0,1,1,1 tcompound.h5
# Array type.
-$xCMD tpbitsArray.ddl -d /Dataset1 -M 0,1,1,1 tarray1.h5
+TOOLTEST tpbitsArray.ddl -d /Dataset1 -M 0,1,1,1 tarray1.h5
# Test Error handling.
# Too many packed bits requested. Max is 8 for now.
-$xCMD tpbitsMaxExceeded.ddl -d /DS08BITS -M 0,1,0,1,1,1,2,1,3,1,4,1,5,1,6,1,7,1 packedbits.h5
+TOOLTEST tpbitsMaxExceeded.ddl -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.
-$xCMD tpbitsOffsetExceeded.ddl -d /DS08BITS -M 64,1 packedbits.h5
-$xCMD tpbitsCharOffsetExceeded.ddl -d /DS08BITS -M 8,1 packedbits.h5
-$xCMD tpbitsIntOffsetExceeded.ddl -d /DS16BITS -M 16,1 packedbits.h5
-$xCMD tpbitsLongOffsetExceeded.ddl -d /DS32BITS -M 32,1 packedbits.h5
+TOOLTEST tpbitsOffsetExceeded.ddl -d /DS08BITS -M 64,1 packedbits.h5
+TOOLTEST tpbitsCharOffsetExceeded.ddl -d /DS08BITS -M 8,1 packedbits.h5
+TOOLTEST tpbitsIntOffsetExceeded.ddl -d /DS16BITS -M 16,1 packedbits.h5
+TOOLTEST tpbitsLongOffsetExceeded.ddl -d /DS32BITS -M 32,1 packedbits.h5
# Bad offset, must not be negative.
-$xCMD tpbitsOffsetNegative.ddl -d /DS08BITS -M -1,1 packedbits.h5
+TOOLTEST tpbitsOffsetNegative.ddl -d /DS08BITS -M -1,1 packedbits.h5
# Bad length, must not be positive.
-$xCMD tpbitsLengthPositive.ddl -d /DS08BITS -M 4,0 packedbits.h5
+TOOLTEST tpbitsLengthPositive.ddl -d /DS08BITS -M 4,0 packedbits.h5
# Offset+Length is too large. Max is 8 for now.
-$xCMD tpbitsLengthExceeded.ddl -d /DS08BITS -M 37,28 packedbits.h5
-$xCMD tpbitsCharLengthExceeded.ddl -d /DS08BITS -M 2,7 packedbits.h5
-$xCMD tpbitsIntLengthExceeded.ddl -d /DS16BITS -M 10,7 packedbits.h5
-$xCMD tpbitsLongLengthExceeded.ddl -d /DS32BITS -M 26,7 packedbits.h5
+TOOLTEST tpbitsLengthExceeded.ddl -d /DS08BITS -M 37,28 packedbits.h5
+TOOLTEST tpbitsCharLengthExceeded.ddl -d /DS08BITS -M 2,7 packedbits.h5
+TOOLTEST tpbitsIntLengthExceeded.ddl -d /DS16BITS -M 10,7 packedbits.h5
+TOOLTEST tpbitsLongLengthExceeded.ddl -d /DS32BITS -M 26,7 packedbits.h5
# Incomplete pair of packed bits request.
-$xCMD tpbitsIncomplete.ddl -d /DS08BITS -M 0,2,2,1,0,2,2, packedbits.h5
+TOOLTEST tpbitsIncomplete.ddl -d /DS08BITS -M 0,2,2,1,0,2,2, packedbits.h5
# Report test results and exit