summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2018-07-18 15:42:14 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2018-07-18 15:42:14 (GMT)
commite5156823bdb90522a2800392bbf0c58d8a5e7b37 (patch)
tree7d1ef5dadb6fb43f70aa37a83eb0f952e603dd2f /test
parent72931507f94fc28ec68d8b96ad928848dae83456 (diff)
downloadhdf5-e5156823bdb90522a2800392bbf0c58d8a5e7b37.zip
hdf5-e5156823bdb90522a2800392bbf0c58d8a5e7b37.tar.gz
hdf5-e5156823bdb90522a2800392bbf0c58d8a5e7b37.tar.bz2
TRILABS-137 Convert tcheck_version script to cmake tests
Diffstat (limited to 'test')
-rw-r--r--test/CMakeTests.cmake19
-rw-r--r--test/ShellTests.cmake28
2 files changed, 17 insertions, 30 deletions
diff --git a/test/CMakeTests.cmake b/test/CMakeTests.cmake
index 34e21f7..cc6ebb8 100644
--- a/test/CMakeTests.cmake
+++ b/test/CMakeTests.cmake
@@ -720,6 +720,23 @@ if (BUILD_SHARED_LIBS)
endif ()
endif ()
+#-- 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
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
+ WILL_FAIL "true"
+)
+add_test (NAME H5TEST-tcheck_version-minor COMMAND $<TARGET_FILE:tcheck_version> "-tm")
+set_tests_properties (H5TEST-tcheck_version-minor PROPERTIES
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
+ WILL_FAIL "true"
+)
+add_test (NAME H5TEST-tcheck_version-release COMMAND $<TARGET_FILE:tcheck_version> "-tr")
+set_tests_properties (H5TEST-tcheck_version-release PROPERTIES
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
+ WILL_FAIL "true"
+)
+
##############################################################################
##############################################################################
@@ -730,7 +747,6 @@ endif ()
#---------------
# error_test
# err_compat
-# tcheck_version
# testmeta
# atomic_writer
# atomic_reader
@@ -740,7 +756,6 @@ endif ()
##############################################################################
# autotools script tests
# error_test and err_compat are built at the same time as the other tests, but executed by testerror.sh.
-# NOT CONVERTED tcheck_version is used by testcheck_version.sh.
# NOT CONVERTED accum_swmr_reader is used by accum.c.
# NOT CONVERTED atomic_writer and atomic_reader are standalone programs.
# links_env is used by testlinks_env.sh
diff --git a/test/ShellTests.cmake b/test/ShellTests.cmake
index fe997b2..58dc85d 100644
--- a/test/ShellTests.cmake
+++ b/test/ShellTests.cmake
@@ -28,7 +28,6 @@ if (UNIX)
configure_file(${HDF5_TEST_SOURCE_DIR}/testflushrefresh.sh.in ${HDF5_TEST_BINARY_DIR}/H5TEST/testflushrefresh.sh @ONLY)
endif ()
configure_file(${HDF5_TEST_SOURCE_DIR}/test_usecases.sh.in ${HDF5_TEST_BINARY_DIR}/H5TEST/test_usecases.sh @ONLY)
- configure_file(${HDF5_TEST_SOURCE_DIR}/testcheck_version.sh.in ${HDF5_TEST_BINARY_DIR}/H5TEST/testcheck_version.sh @ONLY)
configure_file(${HDF5_TEST_SOURCE_DIR}/testswmr.sh.in ${HDF5_TEST_BINARY_DIR}/H5TEST/testswmr.sh @ONLY)
configure_file(${HDF5_TEST_SOURCE_DIR}/testvdsswmr.sh.in ${HDF5_TEST_BINARY_DIR}/H5TEST/testvdsswmr.sh @ONLY)
@@ -49,27 +48,6 @@ if (UNIX)
ARGS -E copy_if_different "${HDF5_SOURCE_DIR}/bin/output_filter.sh" "${HDF5_TEST_BINARY_DIR}/H5TEST/bin/output_filter.sh"
)
- add_custom_command (
- TARGET tcheck_version
- POST_BUILD
- COMMAND ${CMAKE_COMMAND}
- ARGS -E copy_if_different "${HDF5_BINARY_DIR}/H5pubconf.h" "${HDF5_TEST_BINARY_DIR}/src/H5pubconf.h"
- )
-
- add_custom_command (
- TARGET tcheck_version
- POST_BUILD
- COMMAND ${CMAKE_COMMAND}
- ARGS -E copy_if_different "${HDF5_BINARY_DIR}/libhdf5.settings" "${HDF5_TEST_BINARY_DIR}/src/libhdf5.settings"
- )
-
- add_custom_command (
- TARGET tcheck_version
- POST_BUILD
- COMMAND ${CMAKE_COMMAND}
- ARGS -E copy_if_different "${HDF5_SOURCE_DIR}/src/H5public.h" "${HDF5_TEST_BINARY_DIR}/src/H5public.h"
- )
-
file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/H5TEST/flushrefresh_test")
add_custom_command (
TARGET flushrefresh
@@ -190,7 +168,6 @@ if (UNIX)
##############################################################################
# H5_CHECK_TESTS
#---------------
- # tcheck_version
# atomic_writer
# atomic_reader
# filenotclosed
@@ -198,7 +175,6 @@ if (UNIX)
##############################################################################
# autotools script tests
# error_test and err_compat are built at the same time as the other tests, but executed by testerror.sh.
- # NOT CONVERTED tcheck_version is used by testcheck_version.sh.
# NOT CONVERTED accum_swmr_reader is used by accum.c.
# NOT CONVERTED atomic_writer and atomic_reader are standalone programs.
# links_env is used by testlinks_env.sh
@@ -235,10 +211,6 @@ if (UNIX)
set_tests_properties (H5SHELL-testvdsswmr PROPERTIES
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
)
- add_test (H5SHELL-testcheck_version ${SH_PROGRAM} ${HDF5_TEST_BINARY_DIR}/H5TEST/testcheck_version.sh)
- set_tests_properties (H5SHELL-testcheck_version PROPERTIES
- WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
- )
endif ()
endif ()