summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2017-01-10 23:09:53 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2017-01-10 23:10:03 (GMT)
commite1bcae8a6a804490aa941a654e99b1dd18251411 (patch)
treeef2ea266500b5bfea473b15495d850c5640ab1ed /test
parenta4cd30d418838bee49ca112fdfbcc199889b4a21 (diff)
downloadhdf5-e1bcae8a6a804490aa941a654e99b1dd18251411.zip
hdf5-e1bcae8a6a804490aa941a654e99b1dd18251411.tar.gz
hdf5-e1bcae8a6a804490aa941a654e99b1dd18251411.tar.bz2
Update cmake min version and cmake command convention
Diffstat (limited to 'test')
-rw-r--r--test/CMakeLists.txt48
-rw-r--r--test/CMakeTests.cmake140
2 files changed, 94 insertions, 94 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 8891af7..bd73c84 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -1,4 +1,4 @@
-cmake_minimum_required (VERSION 3.1.0)
+cmake_minimum_required (VERSION 3.2.2)
PROJECT (HDF5_TEST)
#-----------------------------------------------------------------------------
@@ -31,10 +31,10 @@ add_library (${HDF5_TEST_LIB_TARGET} STATIC ${TEST_LIB_SOURCES} ${TEST_LIB_HEADE
TARGET_C_PROPERTIES (${HDF5_TEST_LIB_TARGET} STATIC " " " ")
if (MSVC)
target_link_libraries (${HDF5_TEST_LIB_TARGET} "ws2_32.lib")
-endif (MSVC)
+endif ()
if (MINGW)
target_link_libraries (${HDF5_TEST_LIB_TARGET} "wsock32.lib")
-endif (MINGW)
+endif ()
target_link_libraries (${HDF5_TEST_LIB_TARGET} ${HDF5_LIB_TARGET})
H5_SET_LIB_OPTIONS (${HDF5_TEST_LIB_TARGET} ${HDF5_TEST_LIB_NAME} STATIC)
set_target_properties (${HDF5_TEST_LIB_TARGET} PROPERTIES
@@ -47,10 +47,10 @@ if (BUILD_SHARED_LIBS)
TARGET_C_PROPERTIES (${HDF5_TEST_LIBSH_TARGET} SHARED " " " ")
if (MSVC)
target_link_libraries (${HDF5_TEST_LIBSH_TARGET} "ws2_32.lib")
- endif (MSVC)
+ endif ()
if (MINGW)
target_link_libraries (${HDF5_TEST_LIBSH_TARGET} "wsock32.lib")
- endif (MINGW)
+ endif ()
target_link_libraries (${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET})
H5_SET_LIB_OPTIONS (${HDF5_TEST_LIBSH_TARGET} ${HDF5_TEST_LIB_NAME} SHARED ${HDF5_PACKAGE_SOVERSION})
set_target_properties (${HDF5_TEST_LIBSH_TARGET} PROPERTIES
@@ -64,8 +64,8 @@ if (BUILD_SHARED_LIBS)
APPEND PROPERTY COMPILE_DEFINITIONS
"H5_HAVE_THREADSAFE"
)
- endif (HDF5_ENABLE_THREADSAFE)
-endif (BUILD_SHARED_LIBS)
+ endif ()
+endif ()
#-----------------------------------------------------------------------------
# If plugin library tests can be tested
@@ -110,7 +110,7 @@ endif (BUILD_SHARED_LIBS)
"$<TARGET_FILE:${HDF5_TEST_PLUGIN_LIB_TARGET}>"
"${CMAKE_BINARY_DIR}/testdir1/$<TARGET_FILE_NAME:${HDF5_TEST_PLUGIN_LIB_TARGET}>"
)
- endforeach (test_lib ${TEST_PLUGIN_LIBS})
+ endforeach ()
foreach (test_lib ${TEST2_PLUGIN_LIBS})
set (HDF5_TEST_PLUGIN_LIB_CORENAME "${test_lib}")
@@ -136,7 +136,7 @@ endif (BUILD_SHARED_LIBS)
"$<TARGET_FILE:${HDF5_TEST_PLUGIN_LIB_TARGET}>"
"${CMAKE_BINARY_DIR}/testdir2/$<TARGET_FILE_NAME:${HDF5_TEST_PLUGIN_LIB_TARGET}>"
)
- endforeach (test_lib ${TEST2_PLUGIN_LIBS})
+ endforeach ()
set (testhdf5_SOURCES
${HDF5_TEST_SOURCE_DIR}/testhdf5.c
@@ -178,7 +178,7 @@ if (BUILD_SHARED_LIBS)
TARGET_C_PROPERTIES (testhdf5-shared SHARED " " " ")
target_link_libraries (testhdf5-shared ${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET})
set_target_properties (testhdf5-shared PROPERTIES FOLDER test)
-endif (BUILD_SHARED_LIBS)
+endif ()
MACRO (ADD_H5_EXE file)
add_executable (${file} ${HDF5_TEST_SOURCE_DIR}/${file}.c)
@@ -192,8 +192,8 @@ MACRO (ADD_H5_EXE file)
TARGET_C_PROPERTIES (${file}-shared SHARED " " " ")
target_link_libraries (${file}-shared ${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET})
set_target_properties (${file}-shared PROPERTIES FOLDER test)
- endif (BUILD_SHARED_LIBS)
-ENDMACRO (ADD_H5_EXE file)
+ endif ()
+ENDMACRO ()
set (H5_TESTS
cache
@@ -253,7 +253,7 @@ set (H5_TESTS
foreach (test ${H5_TESTS})
ADD_H5_EXE(${test})
-endforeach (test ${H5_TESTS})
+endforeach ()
set (H5_SWMR_TESTS
swmr_check_compat_vfd
@@ -261,7 +261,7 @@ set (H5_SWMR_TESTS
foreach (test ${H5_SWMR_TESTS})
ADD_H5_EXE(${test})
-endforeach (test ${H5_SWMR_TESTS})
+endforeach ()
##############################################################################
##############################################################################
@@ -286,8 +286,8 @@ if (BUILD_SHARED_LIBS)
APPEND PROPERTY COMPILE_DEFINITIONS
"H5_HAVE_THREADSAFE"
)
- endif (HDF5_ENABLE_THREADSAFE)
-endif (BUILD_SHARED_LIBS)
+ endif ()
+endif ()
#-- Adding test for ttsafe
add_executable (ttsafe
@@ -318,8 +318,8 @@ if (BUILD_SHARED_LIBS)
APPEND PROPERTY COMPILE_DEFINITIONS
"H5_HAVE_THREADSAFE"
)
- endif (HDF5_ENABLE_THREADSAFE)
-endif (BUILD_SHARED_LIBS)
+ endif ()
+endif ()
set (H5_CHECK_TESTS
error_test
@@ -332,7 +332,7 @@ set (H5_CHECK_TESTS
foreach (test ${H5_CHECK_TESTS})
ADD_H5_EXE(${test})
-endforeach (test ${H5_CHECK_TESTS})
+endforeach ()
#-- Adding test for accum_swmr_reader
# This has to be copied to the test directory for execve() to find it
@@ -347,7 +347,7 @@ set_target_properties (accum_swmr_reader PROPERTIES FOLDER test)
set_target_properties (accum PROPERTIES DEPENDS accum_swmr_reader)
if (BUILD_SHARED_LIBS)
set_target_properties (accum-shared PROPERTIES DEPENDS accum_swmr_reader)
-endif (BUILD_SHARED_LIBS)
+endif ()
#-- Adding test for libinfo
set (GREP_RUNNER ${PROJECT_BINARY_DIR}/GrepRunner.cmake)
@@ -355,9 +355,9 @@ file (WRITE ${GREP_RUNNER}
"file (STRINGS \${TEST_PROGRAM} TEST_RESULT REGEX \"SUMMARY OF THE HDF5 CONFIGURATION\")
if (\${TEST_RESULT} STREQUAL \"0\")
message (FATAL_ERROR \"Failed: The output: \${TEST_RESULT} of \${TEST_PROGRAM} did not contain SUMMARY OF THE HDF5 CONFIGURATION\")
-else (\${TEST_RESULT} STREQUAL \"0\")
+else ()
message (STATUS \"COMMAND Result: \${TEST_RESULT}\")
-endif (\${TEST_RESULT} STREQUAL \"0\")
+endif ()
"
)
@@ -370,12 +370,12 @@ if (BUILD_SHARED_LIBS)
TARGET_C_PROPERTIES (plugin SHARED " " " ")
target_link_libraries (plugin ${HDF5_TEST_LIB_TARGET})
set_target_properties (plugin PROPERTIES FOLDER test)
-else (BUILD_SHARED_LIBS)
+else ()
add_executable (plugin ${HDF5_TEST_SOURCE_DIR}/plugin.c)
TARGET_NAMING (plugin STATIC)
TARGET_C_PROPERTIES (plugin STATIC " " " ")
target_link_libraries (plugin ${HDF5_TEST_LIB_TARGET})
set_target_properties (plugin PROPERTIES FOLDER test)
-endif (BUILD_SHARED_LIBS)
+endif ()
include (CMakeTests.cmake)
diff --git a/test/CMakeTests.cmake b/test/CMakeTests.cmake
index 5b3d0bf..dd6ff89 100644
--- a/test/CMakeTests.cmake
+++ b/test/CMakeTests.cmake
@@ -13,7 +13,7 @@ if (BUILD_SHARED_LIBS)
file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/H5TEST-shared")
file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/H5TEST-shared/testfiles")
file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/H5TEST-shared/testfiles/plist_files")
-endif (BUILD_SHARED_LIBS)
+endif ()
if (HDF5_TEST_VFD)
set (VFD_LIST
@@ -27,14 +27,14 @@ if (HDF5_TEST_VFD)
)
if (DIRECT_VFD)
set (VFD_LIST ${VFD_LIST} direct)
- endif (DIRECT_VFD)
+ endif ()
foreach (vfdtest ${VFD_LIST})
file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/${vfdtest}")
#if (BUILD_SHARED_LIBS)
# file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/${vfdtest}-shared")
- #endif (BUILD_SHARED_LIBS)
- endforeach (vfdtest ${VFD_LIST})
-endif (HDF5_TEST_VFD)
+ #endif ()
+ endforeach ()
+endif ()
# --------------------------------------------------------------------
# Copy all the HDF5 files from the source directory into the test directory
@@ -56,24 +56,24 @@ if (BUILD_SHARED_LIBS)
COMMAND ${CMAKE_COMMAND}
ARGS -E copy_if_different "$<TARGET_FILE:accum_swmr_reader>" "${PROJECT_BINARY_DIR}/H5TEST-shared/accum_swmr_reader"
)
-endif (BUILD_SHARED_LIBS)
+endif ()
foreach (h5_tfile ${HDF5_TEST_FILES})
HDFTEST_COPY_FILE("${HDF5_TOOLS_DIR}/testfiles/${h5_tfile}" "${PROJECT_BINARY_DIR}/H5TEST/${h5_tfile}" "HDF5_TEST_LIB_files")
if (BUILD_SHARED_LIBS)
HDFTEST_COPY_FILE("${HDF5_TOOLS_DIR}/testfiles/${h5_tfile}" "${PROJECT_BINARY_DIR}/H5TEST-shared/${h5_tfile}" "HDF5_TEST_LIBSH_files")
- endif (BUILD_SHARED_LIBS)
-endforeach (h5_tfile ${HDF5_TEST_FILES})
+ endif ()
+endforeach ()
if (HDF5_TEST_VFD)
foreach (vfdtest ${VFD_LIST})
foreach (h5_tfile ${HDF5_TEST_FILES})
HDFTEST_COPY_FILE("${HDF5_TOOLS_DIR}/testfiles/${h5_tfile}" "${PROJECT_BINARY_DIR}/${vfdtest}/${h5_tfile}" "HDF5_TEST_LIB_files")
if (BUILD_SHARED_LIBS)
HDFTEST_COPY_FILE("${HDF5_TOOLS_DIR}/testfiles/${h5_tfile}" "${PROJECT_BINARY_DIR}/${vfdtest}-shared/${h5_tfile}" "HDF5_TEST_LIBSH_files")
- endif (BUILD_SHARED_LIBS)
- endforeach (h5_tfile ${HDF5_TEST_FILES})
- endforeach (vfdtest ${VFD_LIST})
-endif (HDF5_TEST_VFD)
+ endif ()
+ endforeach ()
+ endforeach ()
+endif ()
# --------------------------------------------------------------------
# Copy all the HDF5 files from the test directory into the source directory
@@ -90,18 +90,18 @@ foreach (ref_file ${HDF5_REFERENCE_FILES})
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/testfiles/${ref_file}" "${PROJECT_BINARY_DIR}/H5TEST/${ref_file}" "HDF5_TEST_LIB_files")
if (BUILD_SHARED_LIBS)
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/testfiles/${ref_file}" "${PROJECT_BINARY_DIR}/H5TEST-shared/${ref_file}" "HDF5_TEST_LIBSH_files")
- endif (BUILD_SHARED_LIBS)
-endforeach (ref_file ${HDF5_REFERENCE_FILES})
+ endif ()
+endforeach ()
if (HDF5_TEST_VFD)
foreach (vfdtest ${VFD_LIST})
foreach (ref_file ${HDF5_REFERENCE_FILES})
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/testfiles/${ref_file}" "${PROJECT_BINARY_DIR}/${vfdtest}/${ref_file}" "HDF5_TEST_LIB_files")
if (BUILD_SHARED_LIBS)
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/testfiles/${ref_file}" "${PROJECT_BINARY_DIR}/${vfdtest}-shared/${ref_file}" "HDF5_TEST_LIBSH_files")
- endif (BUILD_SHARED_LIBS)
- endforeach (ref_file ${HDF5_REFERENCE_FILES})
- endforeach (vfdtest ${VFD_LIST})
-endif (HDF5_TEST_VFD)
+ endif ()
+ endforeach ()
+ endforeach ()
+endif ()
# --------------------------------------------------------------------
# Copy test files from test/testfiles/plist_files dir to test dir
@@ -163,8 +163,8 @@ foreach (plistfile ${HDF5_REFERENCE_PLIST_FILES})
if (BUILD_SHARED_LIBS)
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/testfiles/plist_files/${plistfile}" "${PROJECT_BINARY_DIR}/H5TEST-shared/testfiles/plist_files/${plistfile}" "HDF5_TEST_LIBSH_files")
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/testfiles/plist_files/def_${plistfile}" "${PROJECT_BINARY_DIR}/H5TEST-shared/testfiles/plist_files/def_${plistfile}" "HDF5_TEST_LIBSH_files")
- endif (BUILD_SHARED_LIBS)
-endforeach (plistfile ${HDF5_REFERENCE_PLIST_FILES})
+ endif ()
+endforeach ()
# --------------------------------------------------------------------
#-- Copy all the HDF5 files from the test directory into the source directory
@@ -212,18 +212,18 @@ foreach (h5_file ${HDF5_REFERENCE_TEST_FILES})
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/${h5_file}" "${HDF5_TEST_BINARY_DIR}/H5TEST/${h5_file}" "HDF5_TEST_LIB_files")
if (BUILD_SHARED_LIBS)
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/${h5_file}" "${HDF5_TEST_BINARY_DIR}/H5TEST-shared/${h5_file}" "HDF5_TEST_LIBSH_files")
- endif (BUILD_SHARED_LIBS)
-endforeach (h5_file ${HDF5_REFERENCE_TEST_FILES})
+ endif ()
+endforeach ()
if (HDF5_TEST_VFD)
foreach (vfdtest ${VFD_LIST})
foreach (h5_file ${HDF5_REFERENCE_TEST_FILES})
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/${h5_file}" "${HDF5_TEST_BINARY_DIR}/${vfdtest}/${h5_file}" "HDF5_TEST_LIB_files")
if (BUILD_SHARED_LIBS)
HDFTEST_COPY_FILE("${HDF5_TEST_SOURCE_DIR}/${h5_file}" "${HDF5_TEST_BINARY_DIR}/${vfdtest}-shared/${h5_file}" "HDF5_TEST_LIBSH_files")
- endif (BUILD_SHARED_LIBS)
- endforeach (h5_file ${HDF5_REFERENCE_TEST_FILES})
- endforeach (vfdtest ${VFD_LIST})
-endif (HDF5_TEST_VFD)
+ endif ()
+ endforeach ()
+ endforeach ()
+endif ()
add_custom_target(HDF5_TEST_LIB_files ALL COMMENT "Copying files needed by HDF5_TEST_LIB tests" DEPENDS ${HDF5_TEST_LIB_files_list})
if (BUILD_SHARED_LIBS)
add_custom_target(HDF5_TEST_LIBSH_files ALL COMMENT "Copying files needed by HDF5_TEST_LIBSH tests" DEPENDS ${HDF5_TEST_LIBSH_files_list})
@@ -279,7 +279,7 @@ if (HDF5_ENABLE_USING_MEMCHECKER)
ENVIRONMENT "HDF5_ALARM_SECONDS=3600;srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
)
-else (HDF5_ENABLE_USING_MEMCHECKER)
+else ()
add_test (NAME H5TEST-testhdf5 COMMAND $<TARGET_FILE:testhdf5>)
set_tests_properties (H5TEST-testhdf5 PROPERTIES
DEPENDS H5TEST-clear-testhdf5-objects
@@ -316,8 +316,8 @@ else (HDF5_ENABLE_USING_MEMCHECKER)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST-shared"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
)
- endif (BUILD_SHARED_LIBS)
-endif (HDF5_ENABLE_USING_MEMCHECKER)
+ endif ()
+endif ()
##############################################################################
##############################################################################
@@ -599,15 +599,15 @@ foreach (test ${H5TEST_TESTS})
add_test (NAME H5TEST-${test}
COMMAND ${CMAKE_COMMAND} -E echo "SKIP ${test}"
)
- else (${test} STREQUAL "big" AND CYGWIN)
+ else ()
add_test (NAME H5TEST-${test} COMMAND $<TARGET_FILE:${test}>)
- endif (${test} STREQUAL "big" AND CYGWIN)
+ endif ()
set_tests_properties (H5TEST-${test} PROPERTIES
DEPENDS H5TEST-clear-objects
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
)
-endforeach (test ${H5TEST_TESTS})
+endforeach ()
set_tests_properties (H5TEST-flush2 PROPERTIES DEPENDS H5TEST-flush1)
set_tests_properties (H5TEST-fheap PROPERTIES TIMEOUT 1800)
@@ -630,22 +630,22 @@ if (BUILD_SHARED_LIBS)
add_test (NAME H5TEST-shared-${test}
COMMAND ${CMAKE_COMMAND} -E echo "SKIP ${test}-shared"
)
- else (${test} STREQUAL "big" AND CYGWIN)
+ else ()
add_test (NAME H5TEST-shared-${test} COMMAND $<TARGET_FILE:${test}-shared>)
- endif (${test} STREQUAL "big" AND CYGWIN)
+ endif ()
set_tests_properties (H5TEST-shared-${test} PROPERTIES
DEPENDS H5TEST-shared-clear-objects
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST-shared"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
)
- endforeach (test ${H5TEST_TESTS})
+ 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)
set_tests_properties (H5TEST-shared-objcopy PROPERTIES TIMEOUT 1800)
-endif (BUILD_SHARED_LIBS)
+endif ()
##############################################################################
##############################################################################
@@ -669,7 +669,7 @@ if (NOT CYGWIN)
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
)
set_tests_properties (H5TEST-cache PROPERTIES TIMEOUT 1800)
-endif (NOT CYGWIN)
+endif ()
#-- Adding test for err_compat
if (HDF5_ENABLE_DEPRECATED_SYMBOLS)
@@ -696,7 +696,7 @@ if (HDF5_ENABLE_DEPRECATED_SYMBOLS)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
)
-endif (HDF5_ENABLE_DEPRECATED_SYMBOLS)
+endif ()
#-- Adding test for error_test
add_test (NAME H5TEST-clear-error_test-objects
@@ -776,7 +776,7 @@ if (BUILD_SHARED_LIBS)
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
)
set_tests_properties (H5TEST-shared-cache PROPERTIES TIMEOUT 1800)
- endif (NOT CYGWIN)
+ endif ()
#-- Adding test for err_compat
if (HDF5_ENABLE_DEPRECATED_SYMBOLS)
@@ -803,7 +803,7 @@ if (BUILD_SHARED_LIBS)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST-shared"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
)
- endif (HDF5_ENABLE_DEPRECATED_SYMBOLS)
+ endif ()
#-- Adding test for error_test
add_test (NAME H5TEST-shared-clear-error_test-objects
@@ -865,16 +865,16 @@ if (BUILD_SHARED_LIBS)
WORKING_DIRECTORY
${HDF5_TEST_BINARY_DIR}/H5TEST-shared
)
-endif (BUILD_SHARED_LIBS)
+endif ()
##############################################################################
### P L U G I N T E S T S
##############################################################################
if (WIN32)
set (CMAKE_SEP "\;")
-else (WIN32)
+else ()
set (CMAKE_SEP ":")
-endif (WIN32)
+endif ()
add_test (NAME H5PLUGIN-plugin COMMAND $<TARGET_FILE:plugin>)
set_tests_properties (H5PLUGIN-plugin PROPERTIES
@@ -953,7 +953,7 @@ if (HDF5_TEST_VFD)
)
if (NOT CYGWIN)
set (H5_VFD_TESTS ${H5_VFD_TESTS} big cache)
- endif (NOT CYGWIN)
+ endif ()
MACRO (CHECK_VFD_TEST vfdtest vfdname resultcode)
if (${vfdtest} STREQUAL "flush1" OR ${vfdtest} STREQUAL "flush2")
@@ -988,8 +988,8 @@ if (HDF5_TEST_VFD)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/${vfdname}-shared"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/${vfdname}-shared
)
- endif (BUILD_SHARED_LIBS)
- else (NOT BUILD_SHARED_LIBS AND NOT CMAKE_BUILD_TYPE MATCHES Debug)
+ endif ()
+ else ()
add_test (NAME VFD-${vfdname}-${vfdtest}
COMMAND ${CMAKE_COMMAND} -E echo "SKIP VFD-${vfdname}-${vfdtest}"
)
@@ -997,9 +997,9 @@ if (HDF5_TEST_VFD)
add_test (NAME VFD-${vfdname}-${test}-shared
COMMAND ${CMAKE_COMMAND} -E echo "SKIP VFD-${vfdname}-${vfdtest}-shared"
)
- endif (BUILD_SHARED_LIBS)
- endif(NOT BUILD_SHARED_LIBS AND NOT CMAKE_BUILD_TYPE MATCHES Debug)
- else (${vfdname} STREQUAL "multi" OR ${vfdname} STREQUAL "split")
+ endif ()
+ endif()
+ else ()
add_test (NAME VFD-${vfdname}-${vfdtest}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:${vfdtest}>"
@@ -1029,9 +1029,9 @@ if (HDF5_TEST_VFD)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/${vfdname}-shared"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/${vfdname}-shared
)
- endif (BUILD_SHARED_LIBS)
- endif (${vfdname} STREQUAL "multi" OR ${vfdname} STREQUAL "split")
- else (${vfdtest} STREQUAL "flush1" OR ${vfdtest} STREQUAL "flush2")
+ endif ()
+ endif ()
+ else ()
add_test (NAME VFD-${vfdname}-${vfdtest}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:${vfdtest}>"
@@ -1061,15 +1061,15 @@ if (HDF5_TEST_VFD)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/${vfdname}-shared;HDF5TestExpress=${HDF_TEST_EXPRESS}"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/${vfdname}-shared
)
- endif (BUILD_SHARED_LIBS)
- endif (${vfdtest} STREQUAL "flush1" OR ${vfdtest} STREQUAL "flush2")
- ENDMACRO (CHECK_VFD_TEST vfdtest vfdname resultcode)
+ endif ()
+ endif ()
+ ENDMACRO ()
MACRO (ADD_VFD_TEST vfdname resultcode)
foreach (test ${H5_VFD_TESTS})
if (WIN32)
CHECK_VFD_TEST (${test} ${vfdname} ${resultcode})
- else (WIN32)
+ else ()
add_test (NAME VFD-${vfdname}-${test}
COMMAND "${CMAKE_COMMAND}"
-D "TEST_PROGRAM=$<TARGET_FILE:${test}>"
@@ -1099,16 +1099,16 @@ if (HDF5_TEST_VFD)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/${vfdname}-shared"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/${vfdname}-shared
)
- endif (BUILD_SHARED_LIBS)
- endif (WIN32)
- endforeach (test ${H5_VFD_TESTS})
+ endif ()
+ endif ()
+ endforeach ()
set_tests_properties (VFD-${vfdname}-flush2 PROPERTIES DEPENDS VFD-${vfdname}-flush1)
set_tests_properties (VFD-${vfdname}-flush1 PROPERTIES TIMEOUT 10)
set_tests_properties (VFD-${vfdname}-flush2 PROPERTIES TIMEOUT 10)
set_tests_properties (VFD-${vfdname}-istore PROPERTIES TIMEOUT 1800)
if (NOT CYGWIN)
set_tests_properties (VFD-${vfdname}-cache PROPERTIES TIMEOUT 1800)
- endif (NOT CYGWIN)
+ endif ()
if (BUILD_SHARED_LIBS)
set_tests_properties (VFD-${vfdname}-flush2-shared PROPERTIES DEPENDS VFD-${vfdname}-flush1-shared)
set_tests_properties (VFD-${vfdname}-flush1-shared PROPERTIES TIMEOUT 10)
@@ -1116,8 +1116,8 @@ if (HDF5_TEST_VFD)
set_tests_properties (VFD-${vfdname}-istore-shared PROPERTIES TIMEOUT 1800)
if (NOT CYGWIN)
set_tests_properties (VFD-${vfdname}-cache-shared PROPERTIES TIMEOUT 1800)
- endif (NOT CYGWIN)
- endif (BUILD_SHARED_LIBS)
+ endif ()
+ endif ()
if (HDF5_TEST_FHEAP_VFD)
add_test (NAME VFD-${vfdname}-fheap
COMMAND "${CMAKE_COMMAND}"
@@ -1150,16 +1150,16 @@ if (HDF5_TEST_VFD)
ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/${vfdname}-shared;HDF5TestExpress=${HDF_TEST_EXPRESS}"
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/${vfdname}-shared
)
- endif (BUILD_SHARED_LIBS)
- endif (HDF5_TEST_FHEAP_VFD)
- ENDMACRO (ADD_VFD_TEST)
+ endif ()
+ endif ()
+ ENDMACRO ()
# Run test with different Virtual File Driver
foreach (vfd ${VFD_LIST})
ADD_VFD_TEST (${vfd} 0)
- endforeach (vfd ${VFD_LIST})
+ endforeach ()
-endif (HDF5_TEST_VFD)
+endif ()
##############################################################################
##############################################################################
@@ -1174,7 +1174,7 @@ if (HDF5_BUILD_GENERATORS)
TARGET_C_PROPERTIES (${genfile} STATIC " " " ")
target_link_libraries (${genfile} ${HDF5_TEST_LIB_TARGET} ${HDF5_LIB_TARGET})
set_target_properties (${genfile} PROPERTIES FOLDER generator/test)
- ENDMACRO (ADD_H5_GENERATOR genfile)
+ ENDMACRO ()
# generator executables
set (H5_GENERATORS
@@ -1201,6 +1201,6 @@ if (HDF5_BUILD_GENERATORS)
foreach (gen ${H5_GENERATORS})
ADD_H5_GENERATOR (${gen})
- endforeach (gen ${H5_GENERATORS})
+ endforeach ()
-endif (HDF5_BUILD_GENERATORS)
+endif ()