summaryrefslogtreecommitdiffstats
path: root/test/CMakeTests.cmake
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2018-09-24 19:38:46 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2018-09-24 19:38:46 (GMT)
commit8d7bdb704163327cacf8be3a4e03f02fb88a957b (patch)
tree9a2731767f265171eaae87a10adec2a504082a6a /test/CMakeTests.cmake
parent496de34110a27b9f550aa2bdc868d38eeb1b4908 (diff)
downloadhdf5-8d7bdb704163327cacf8be3a4e03f02fb88a957b.zip
hdf5-8d7bdb704163327cacf8be3a4e03f02fb88a957b.tar.gz
hdf5-8d7bdb704163327cacf8be3a4e03f02fb88a957b.tar.bz2
CMake changes for SKIPPED and flush tests
Diffstat (limited to 'test/CMakeTests.cmake')
-rw-r--r--test/CMakeTests.cmake66
1 files changed, 54 insertions, 12 deletions
diff --git a/test/CMakeTests.cmake b/test/CMakeTests.cmake
index cc6ebb8..8838c34 100644
--- a/test/CMakeTests.cmake
+++ b/test/CMakeTests.cmake
@@ -439,14 +439,6 @@ set (test_CLEANFILES
tvlstr.h5
tvlstr2.h5
twriteorder.dat
- flush.h5
- flush-swmr.h5
- noflush.h5
- noflush-swmr.h5
- flush_extend.h5
- flush_extend-swmr.h5
- noflush_extend.h5
- noflush_extend-swmr.h5
enum1.h5
titerate.h5
ttsafe.h5
@@ -551,6 +543,8 @@ set (H5TEST_SEPARATE_TESTS
testhdf5
cache
cache_image
+ flush1
+ flush2
)
foreach (test ${H5_TESTS})
if (NOT ${test} IN_LIST H5TEST_SEPARATE_TESTS)
@@ -587,7 +581,6 @@ foreach (test ${H5_TESTS})
endif ()
endforeach ()
-set_tests_properties (H5TEST-flush2 PROPERTIES DEPENDS H5TEST-flush1)
set_tests_properties (H5TEST-fheap PROPERTIES TIMEOUT 1800)
set_tests_properties (H5TEST-big PROPERTIES TIMEOUT 1800)
set_tests_properties (H5TEST-btree2 PROPERTIES TIMEOUT 1800)
@@ -630,7 +623,6 @@ if (BUILD_SHARED_LIBS)
endif ()
endforeach ()
- set_tests_properties (H5TEST-shared-flush2 PROPERTIES DEPENDS H5TEST-shared-flush1)
set_tests_properties (H5TEST-shared-fheap PROPERTIES TIMEOUT 1800)
set_tests_properties (H5TEST-shared-big PROPERTIES TIMEOUT 1800)
set_tests_properties (H5TEST-shared-btree2 PROPERTIES TIMEOUT 1800)
@@ -720,6 +712,54 @@ if (BUILD_SHARED_LIBS)
endif ()
endif ()
+#-- Adding test for flush1/2
+add_test (NAME H5TEST-clear-flush-objects
+ COMMAND ${CMAKE_COMMAND}
+ -E remove
+ flush.h5
+ flush-swmr.h5
+ noflush.h5
+ noflush-swmr.h5
+ flush_extend.h5
+ flush_extend-swmr.h5
+ noflush_extend.h5
+ noflush_extend-swmr.h5
+ WORKING_DIRECTORY
+ ${HDF5_TEST_BINARY_DIR}/H5TEST
+)
+if (HDF5_ENABLE_USING_MEMCHECKER)
+ add_test (NAME H5TEST-flush1 COMMAND $<TARGET_FILE:flush1>)
+else ()
+ add_test (NAME H5TEST-flush1 COMMAND "${CMAKE_COMMAND}"
+ -D "TEST_PROGRAM=$<TARGET_FILE:flush1>"
+ -D "TEST_ARGS:STRING="
+ -D "TEST_EXPECT=0"
+ -D "TEST_SKIP_COMPARE=TRUE"
+ -D "TEST_OUTPUT=flush1.txt"
+ -D "TEST_FOLDER=${HDF5_TEST_BINARY_DIR}/H5TEST"
+ -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+ )
+endif ()
+set_tests_properties (H5TEST-flush1 PROPERTIES
+ DEPENDS H5TEST-clear-flush-objects
+ ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST;HDF5TestExpress=${HDF_TEST_EXPRESS}"
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
+)
+if (HDF5_ENABLE_USING_MEMCHECKER)
+ add_test (NAME H5TEST-flush2 COMMAND $<TARGET_FILE:flush2>)
+else ()
+ add_test (NAME H5TEST-flush2 COMMAND "${CMAKE_COMMAND}"
+ -D "TEST_PROGRAM=$<TARGET_FILE:flush2>"
+ -D "TEST_ARGS:STRING="
+ -D "TEST_EXPECT=0"
+ -D "TEST_SKIP_COMPARE=TRUE"
+ -D "TEST_OUTPUT=flush2.txt"
+ -D "TEST_FOLDER=${HDF5_TEST_BINARY_DIR}/H5TEST"
+ -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+ )
+endif ()
+set_tests_properties (H5TEST-flush2 PROPERTIES DEPENDS H5TEST-flush1)
+
#-- Adding test for tcheck_version
add_test (NAME H5TEST-tcheck_version-major COMMAND $<TARGET_FILE:tcheck_version> "-tM")
set_tests_properties (H5TEST-tcheck_version-major PROPERTIES
@@ -826,9 +866,10 @@ add_test (NAME H5TEST-clear-error_test-objects
set_tests_properties (H5TEST-clear-error_test-objects PROPERTIES FIXTURES_SETUP error_test_clear_objects)
if (HDF5_USE_16_API_DEFAULT)
add_test (
- NAME H5TEST-error_test-SKIPPED
+ NAME H5TEST-error_test
COMMAND ${CMAKE_COMMAND} -E echo "SKIP $<TARGET_FILE:error_test>"
)
+ set_property(TEST H5TEST-error_test PROPERTY DISABLED)
else ()
add_test (NAME H5TEST-error_test COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:error_test>"
@@ -925,9 +966,10 @@ if (BUILD_SHARED_LIBS)
set_tests_properties (H5TEST-shared-clear-error_test-objects PROPERTIES FIXTURES_SETUP shared_error_test_clear_objects)
if (HDF5_USE_16_API_DEFAULT)
add_test (
- NAME H5TEST-shared-error_test-SKIPPED
+ NAME H5TEST-shared-error_test
COMMAND ${CMAKE_COMMAND} -E echo "SKIP $<TARGET_FILE:error_test-shared>"
)
+ set_property(TEST H5TEST-shared-error_test PROPERTY DISABLED)
else ()
add_test (NAME H5TEST-shared-error_test COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:error_test-shared>"