summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2019-07-03 15:14:50 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2019-07-03 15:15:07 (GMT)
commitce92a647163db7929d04b333b26eebc8b81a089a (patch)
tree273a5b5c1bc2ae49bb81716a5a5da7733ba5135f /tools
parentd0bc570c2cdc4cbbb42cc1d4dac61aba67e20892 (diff)
downloadhdf5-ce92a647163db7929d04b333b26eebc8b81a089a.zip
hdf5-ce92a647163db7929d04b333b26eebc8b81a089a.tar.gz
hdf5-ce92a647163db7929d04b333b26eebc8b81a089a.tar.bz2
Add missing test
Diffstat (limited to 'tools')
-rw-r--r--tools/test/perform/CMakeLists.txt15
-rw-r--r--tools/test/perform/CMakeTests.cmake16
2 files changed, 31 insertions, 0 deletions
diff --git a/tools/test/perform/CMakeLists.txt b/tools/test/perform/CMakeLists.txt
index 5a45d34..e6c4626 100644
--- a/tools/test/perform/CMakeLists.txt
+++ b/tools/test/perform/CMakeLists.txt
@@ -132,6 +132,21 @@ else ()
endif ()
set_target_properties (zip_perf PROPERTIES FOLDER perform)
+#-- Adding test for perf
+set (perf_SOURCES
+ ${HDF5_TOOLS_TEST_PERFORM_SOURCE_DIR}/perf.c
+)
+add_executable (perf ${perf_SOURCES})
+target_include_directories (perf PRIVATE "${HDF5_TEST_SRC_DIR};${HDF5_SRC_DIR};${HDF5_BINARY_DIR};$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_C_INCLUDE_DIRS}>")
+if (NOT BUILD_SHARED_LIBS)
+ TARGET_C_PROPERTIES (perf STATIC)
+ target_link_libraries (perf PRIVATE ${HDF5_TOOLS_LIB_TARGET} ${HDF5_TEST_LIB_TARGET} ${HDF5_LIB_TARGET})
+else ()
+ TARGET_C_PROPERTIES (perf SHARED)
+ target_link_libraries (perf PRIVATE ${HDF5_TOOLS_LIBSH_TARGET} ${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET})
+endif ()
+set_target_properties (perf PROPERTIES FOLDER perform)
+
if (H5_HAVE_PARALLEL AND BUILD_TESTING)
#-- Adding test for h5perf
set (h5perf_SOURCES
diff --git a/tools/test/perform/CMakeTests.cmake b/tools/test/perform/CMakeTests.cmake
index 36172d1..d079402 100644
--- a/tools/test/perform/CMakeTests.cmake
+++ b/tools/test/perform/CMakeTests.cmake
@@ -169,6 +169,22 @@ else ()
endif ()
set_tests_properties (PERFORM_zip_perf PROPERTIES DEPENDS "PERFORM_zip_perf_help;PERFORM_h5perform-clearall-objects")
+if (HDF5_ENABLE_USING_MEMCHECKER)
+ add_test (NAME PERFORM_perf COMMAND $<TARGET_FILE:perf>)
+else ()
+ add_test (NAME PERFORM_perf COMMAND "${CMAKE_COMMAND}"
+ -D "TEST_PROGRAM=$<TARGET_FILE:perf>"
+ -D "TEST_ARGS:STRING="
+ -D "TEST_EXPECT=0"
+ -D "TEST_SKIP_COMPARE=TRUE"
+ -D "TEST_OUTPUT=perf.txt"
+ #-D "TEST_REFERENCE=perf.out"
+ -D "TEST_FOLDER=${PROJECT_BINARY_DIR}"
+ -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+ )
+endif ()
+set_tests_properties (PERFORM_perf PROPERTIES DEPENDS "PERFORM_h5perform-clearall-objects")
+
if (H5_HAVE_PARALLEL)
add_test (NAME MPI_TEST_PERFORM_h5perf COMMAND ${MPIEXEC_EXECUTABLE} ${MPIEXEC_NUMPROC_FLAG} ${MPIEXEC_MAX_NUMPROCS} ${MPIEXEC_PREFLAGS} $<TARGET_FILE:h5perf> ${MPIEXEC_POSTFLAGS})