diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2018-11-09 14:13:07 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2018-11-09 14:13:07 (GMT) |
commit | 4da93e9d6f9ee0fc7462ee66645c5ad0fa9a9e35 (patch) | |
tree | ad6d5f412a8f1af0a2121bb0fb7fa3073462c713 /test | |
parent | f97de01d36cde2b66042ffac3debcfab72de0c1d (diff) | |
download | hdf5-4da93e9d6f9ee0fc7462ee66645c5ad0fa9a9e35.zip hdf5-4da93e9d6f9ee0fc7462ee66645c5ad0fa9a9e35.tar.gz hdf5-4da93e9d6f9ee0fc7462ee66645c5ad0fa9a9e35.tar.bz2 |
TRILABS-81 coverity tools fixes
Diffstat (limited to 'test')
-rw-r--r-- | test/CMakeLists.txt | 2 | ||||
-rw-r--r-- | test/CMakeTests.cmake | 26 |
2 files changed, 16 insertions, 12 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 117f24e..85ccc7a 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -59,6 +59,7 @@ endif () ################################################################################# # If filter plugin tests can be tested ################################################################################# +if (BUILD_SHARED_LIBS) # make plugins dir file (MAKE_DIRECTORY "${CMAKE_BINARY_DIR}/testdir1") file (MAKE_DIRECTORY "${CMAKE_BINARY_DIR}/testdir2") @@ -124,6 +125,7 @@ endif () "${CMAKE_BINARY_DIR}/testdir2/$<TARGET_FILE_NAME:${HDF5_TEST_PLUGIN_TARGET}>" ) endforeach () +endif () ################################################################################# # Test program sources diff --git a/test/CMakeTests.cmake b/test/CMakeTests.cmake index 5fb8c93..a19d0ca 100644 --- a/test/CMakeTests.cmake +++ b/test/CMakeTests.cmake @@ -798,19 +798,21 @@ endif () ############################################################################## ### F I L T E R P L U G I N T E S T S ############################################################################## -if (WIN32) - set (CMAKE_SEP "\;") - set (BIN_REL_PATH "../../") -else () - set (CMAKE_SEP ":") - set (BIN_REL_PATH "../") -endif () +if (BUILD_SHARED_LIBS AND TEST_SHARED_PROGRAMS) + if (WIN32) + set (CMAKE_SEP "\;") + set (BIN_REL_PATH "../../") + else () + set (CMAKE_SEP ":") + set (BIN_REL_PATH "../") + endif () -add_test (NAME H5PLUGIN-plugin COMMAND $<TARGET_FILE:filter_plugin>) -set_tests_properties (H5PLUGIN-plugin PROPERTIES - ENVIRONMENT "HDF5_PLUGIN_PATH=${CMAKE_BINARY_DIR}/testdir1${CMAKE_SEP}${CMAKE_BINARY_DIR}/testdir2;srcdir=${HDF5_TEST_BINARY_DIR}" - WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR} -) + add_test (NAME H5PLUGIN-plugin COMMAND $<TARGET_FILE:filter_plugin>) + set_tests_properties (H5PLUGIN-plugin PROPERTIES + ENVIRONMENT "HDF5_PLUGIN_PATH=${CMAKE_BINARY_DIR}/testdir1${CMAKE_SEP}${CMAKE_BINARY_DIR}/testdir2;srcdir=${HDF5_TEST_BINARY_DIR}" + WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR} + ) +endif () ############################################################################## ############################################################################## |