summaryrefslogtreecommitdiffstats
path: root/tools/h5diff/CMakeLists.txt
diff options
context:
space:
mode:
authorJonathan Kim <jkm@hdfgroup.org>2011-08-16 22:40:36 (GMT)
committerJonathan Kim <jkm@hdfgroup.org>2011-08-16 22:40:36 (GMT)
commit7a6f281a8b8a34e8cf4f58c2d1b36a13329cb365 (patch)
tree158e71f623819faeb27a04242065b09171acb1e7 /tools/h5diff/CMakeLists.txt
parente703a6a2a4c6e6ee443d2e2af08fe61479789f79 (diff)
downloadhdf5-7a6f281a8b8a34e8cf4f58c2d1b36a13329cb365.zip
hdf5-7a6f281a8b8a34e8cf4f58c2d1b36a13329cb365.tar.gz
hdf5-7a6f281a8b8a34e8cf4f58c2d1b36a13329cb365.tar.bz2
[svn-r21237] Description:
Add test cases for HDFFV-7656 - "--delta=something" considers two NaN of the same type are different. The fix was added (r21105) before but test cases were incorrectly added and missing for cmake script. Tested: jam (linux32-LE), koala (linux64-LE), heiwa (linuxppc64-BE), tejeda (mac32-LE), linew (solaris-BE), cmake
Diffstat (limited to 'tools/h5diff/CMakeLists.txt')
-rw-r--r--tools/h5diff/CMakeLists.txt38
1 files changed, 38 insertions, 0 deletions
diff --git a/tools/h5diff/CMakeLists.txt b/tools/h5diff/CMakeLists.txt
index b04e577..52a58eb 100644
--- a/tools/h5diff/CMakeLists.txt
+++ b/tools/h5diff/CMakeLists.txt
@@ -185,6 +185,8 @@ IF (BUILD_TESTING)
h5diff_627.txt
h5diff_628.txt
h5diff_629.txt
+ h5diff_630.txt
+ h5diff_631.txt
h5diff_640.txt
h5diff_641.txt
h5diff_642.txt
@@ -400,6 +402,35 @@ IF (BUILD_TESTING)
ENDIF (HDF5_ENABLE_USING_MEMCHECKER)
ENDMACRO (ADD_PH5_TEST file)
+ # ADD_H5_NO_OUTPUT_TEST
+ # Purpose to verify only exitcode without output comparison
+ # Don't use this if possible; this may be removed.
+ MACRO (ADD_H5_NO_OUTPUT_TEST testname resultcode)
+ # If using memchecker add tests without using scripts
+ IF (NOT HDF5_ENABLE_USING_MEMCHECKER)
+ ADD_TEST (
+ NAME H5DIFF-clear-${testname}-objects
+ COMMAND ${CMAKE_COMMAND}
+ -E remove ${testname}.out ${testname}.out.err
+ )
+ # if there was a previous test
+ IF (NOT "${last_test}" STREQUAL "")
+ SET_TESTS_PROPERTIES (H5DIFF-clear-${testname}-objects PROPERTIES DEPENDS ${last_test})
+ ENDIF (NOT "${last_test}" STREQUAL "")
+ SET (last_test "H5DIFF-clear-${testname}-objects")
+ ENDIF (NOT HDF5_ENABLE_USING_MEMCHECKER)
+
+ ADD_TEST (NAME H5DIFF-${testname} COMMAND $<TARGET_FILE:h5diff> ${ARGN})
+ IF (NOT ${resultcode} STREQUAL "0")
+ SET_TESTS_PROPERTIES (H5DIFF-${testname} PROPERTIES WILL_FAIL "true")
+ ENDIF (NOT ${resultcode} STREQUAL "0")
+
+ IF (NOT "${last_test}" STREQUAL "")
+ SET_TESTS_PROPERTIES (H5DIFF-${testname} PROPERTIES DEPENDS ${last_test})
+ ENDIF (NOT "${last_test}" STREQUAL "")
+ SET (last_test "H5DIFF-${testname}")
+ ENDMACRO (ADD_H5_NO_OUTPUT_TEST)
+
##############################################################################
##############################################################################
### T H E T E S T S ###
@@ -986,6 +1017,13 @@ ADD_H5_TEST (h5diff_628 1 -n 1 ${FILE1} ${FILE2} g1/dset3 g1/dset4)
#ADD_H5_TEST (h5diff_629 2 file1.h6 file2.h6)
# ##############################################################################
+# # NaN
+# ##############################################################################
+# 6.30: test (NaN == NaN) must be true based on our documentation -- XCAO
+ADD_H5_TEST (h5diff_630 0 -v -d "0.0001" ${FILE1} ${FILE1} g1/fp18 g1/fp18_COPY)
+ADD_H5_TEST (h5diff_631 0 -v --use-system-epsilon ${FILE1} ${FILE1} g1/fp18 g1/fp18_COPY)
+
+# ##############################################################################
# 7. attributes
# ##############################################################################
ADD_H5_TEST (h5diff_70 1 -v ${FILE5} ${FILE6})