diff options
author | Vailin Choi <vchoi@hdfgroup.org> | 2013-08-23 04:55:15 (GMT) |
---|---|---|
committer | Vailin Choi <vchoi@hdfgroup.org> | 2013-08-23 04:55:15 (GMT) |
commit | d8a0a14591c902c21497f4fc7aab7ea9a35caee4 (patch) | |
tree | d77637306313312d02d7b7a88117b1d61a3baf00 /tools/h5repack/h5repack.sh.in | |
parent | 66921438dd3903b70ad3d4013c8726db3f6b69bd (diff) | |
download | hdf5-d8a0a14591c902c21497f4fc7aab7ea9a35caee4.zip hdf5-d8a0a14591c902c21497f4fc7aab7ea9a35caee4.tar.gz hdf5-d8a0a14591c902c21497f4fc7aab7ea9a35caee4.tar.bz2 |
[svn-r24062] Bring revisions #24030 - 24058 from trunk to revise_chunks.
h5committested.
Diffstat (limited to 'tools/h5repack/h5repack.sh.in')
-rw-r--r-- | tools/h5repack/h5repack.sh.in | 53 |
1 files changed, 51 insertions, 2 deletions
diff --git a/tools/h5repack/h5repack.sh.in b/tools/h5repack/h5repack.sh.in index ca25183..42b8ecb 100644 --- a/tools/h5repack/h5repack.sh.in +++ b/tools/h5repack/h5repack.sh.in @@ -120,6 +120,7 @@ LIST_OTHER_TEST_FILES=" $SRC_H5REPACK_TESTFILES/h5repack_ext.bin $SRC_H5REPACK_TESTFILES/ublock.bin $SRC_H5REPACK_TESTFILES/h5repack.info +$SRC_H5REPACK_TESTFILES/h5repack_layout.h5.ddl $SRC_TOOLS_TESTFILES/h5repack_filters.h5.ddl " @@ -201,7 +202,7 @@ DIFFTEST() fi } - + # Call h5repack # @@ -475,6 +476,54 @@ TOOLTESTV() rm -f $actual $actual_err rm -f $outfile } + +# This is same as TOOLTESTV() with comparing h5dump output +# from -pH option +# +TOOLTEST_DUMP() +{ + infile=$TESTDIR/$2 + outfile=$TESTDIR/out-$1.$2 + expect="$TESTDIR/$2.ddl" + actual="$TESTDIR/out-$1.$2.out" + actual_err="$TESTDIR/out-$1.$2.err" + + shift + shift + + # Run test. + TESTING $H5REPACK $@ + ( + $RUNSERIAL $H5REPACK_BIN "$@" $infile $outfile + ) >$actual 2>$actual_err + RET=$? + if [ $RET != 0 ] ; then + echo "*FAILED*" + nerrors="`expr $nerrors + 1`" + else + echo " PASSED" + VERIFY h5dump output $@ + ( + $RUNSERIAL $H5DUMP_BIN -pH $outfile + ) >$actual 2>$actual_err + cat $actual_err >> $actual + + RET=$? + + fi + + if cmp -s $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 -c $expect $actual |sed 's/^/ /' + fi + + rm -f $actual $actual_err + rm -f $outfile +} # TOOLTEST_META: # Test metadata block size option. @@ -820,7 +869,7 @@ arg="h5repack_layout.h5 -f GZIP=1 -m 1024" if test $USE_FILTER_DEFLATE != "yes" ; then SKIP $arg else - TOOLTEST deflate_limit $arg + TOOLTEST_DUMP deflate_limit $arg fi #file |