diff options
author | kmu <kmu@hdfgroup.org> | 2020-01-16 16:42:24 (GMT) |
---|---|---|
committer | kmu <kmu@hdfgroup.org> | 2020-01-16 16:42:24 (GMT) |
commit | 7e93acd94f20c73d27bb2eb4f7b4389d88cfb299 (patch) | |
tree | cc3e04bdcb987e194bb481540fca17a2e2ea914a /examples/CMakeTests.cmake | |
parent | 7366709e4000a96a9942934da0d13474213567f3 (diff) | |
parent | 024f7ba09250110c19b070c9699cfbc0f9dc2b96 (diff) | |
download | hdf5-7e93acd94f20c73d27bb2eb4f7b4389d88cfb299.zip hdf5-7e93acd94f20c73d27bb2eb4f7b4389d88cfb299.tar.gz hdf5-7e93acd94f20c73d27bb2eb4f7b4389d88cfb299.tar.bz2 |
Merge branch 'develop' of https://bitbucket.hdfgroup.org/scm/hdffv/hdf5 into develop
Diffstat (limited to 'examples/CMakeTests.cmake')
-rw-r--r-- | examples/CMakeTests.cmake | 60 |
1 files changed, 31 insertions, 29 deletions
diff --git a/examples/CMakeTests.cmake b/examples/CMakeTests.cmake index ea3b2c5..fd7f1dc 100644 --- a/examples/CMakeTests.cmake +++ b/examples/CMakeTests.cmake @@ -64,38 +64,40 @@ set (test_ex_CLEANFILES vds-eiger.h5 ) -# Remove any output file left over from previous test run -add_test ( - NAME EXAMPLES-clear-objects - COMMAND ${CMAKE_COMMAND} -E remove ${test_ex_CLEANFILES} -) -set_tests_properties (EXAMPLES-clear-objects PROPERTIES FIXTURES_SETUP clear_EXAMPLES) +if (HDF5_TEST_SERIAL) + # Remove any output file left over from previous test run + add_test ( + NAME EXAMPLES-clear-objects + COMMAND ${CMAKE_COMMAND} -E remove ${test_ex_CLEANFILES} + ) + set_tests_properties (EXAMPLES-clear-objects PROPERTIES FIXTURES_SETUP clear_EXAMPLES) -foreach (example ${examples}) - if (HDF5_ENABLE_USING_MEMCHECKER) - add_test (NAME EXAMPLES-${example} COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $<TARGET_FILE:${example}>) - else () - add_test (NAME EXAMPLES-${example} COMMAND "${CMAKE_COMMAND}" - -D "TEST_EMULATOR=${CMAKE_CROSSCOMPILING_EMULATOR}" - -D "TEST_PROGRAM=$<TARGET_FILE:${example}>" - -D "TEST_ARGS:STRING=" - -D "TEST_EXPECT=0" - -D "TEST_SKIP_COMPARE=TRUE" - -D "TEST_OUTPUT=${example}.txt" - #-D "TEST_REFERENCE=${example}.out" - -D "TEST_FOLDER=${PROJECT_BINARY_DIR}" - -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" - ) - endif () - set_tests_properties (EXAMPLES-${example} PROPERTIES FIXTURES_REQUIRED clear_EXAMPLES) - if (last_test) - set_tests_properties (EXAMPLES-${example} PROPERTIES DEPENDS ${last_test}) - endif () - set (last_test "EXAMPLES-${example}") -endforeach () + foreach (example ${examples}) + if (HDF5_ENABLE_USING_MEMCHECKER) + add_test (NAME EXAMPLES-${example} COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $<TARGET_FILE:${example}>) + else () + add_test (NAME EXAMPLES-${example} COMMAND "${CMAKE_COMMAND}" + -D "TEST_EMULATOR=${CMAKE_CROSSCOMPILING_EMULATOR}" + -D "TEST_PROGRAM=$<TARGET_FILE:${example}>" + -D "TEST_ARGS:STRING=" + -D "TEST_EXPECT=0" + -D "TEST_SKIP_COMPARE=TRUE" + -D "TEST_OUTPUT=${example}.txt" + #-D "TEST_REFERENCE=${example}.out" + -D "TEST_FOLDER=${PROJECT_BINARY_DIR}" + -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" + ) + endif () + set_tests_properties (EXAMPLES-${example} PROPERTIES FIXTURES_REQUIRED clear_EXAMPLES) + if (last_test) + set_tests_properties (EXAMPLES-${example} PROPERTIES DEPENDS ${last_test}) + endif () + set (last_test "EXAMPLES-${example}") + endforeach () +endif () ### Windows pops up a modal permission dialog on this test -if (H5_HAVE_PARALLEL AND NOT WIN32) +if (H5_HAVE_PARALLEL AND HDF5_TEST_PARALLEL AND NOT WIN32) if (HDF5_ENABLE_USING_MEMCHECKER) add_test (NAME MPI_TEST_EXAMPLES-ph5example COMMAND ${MPIEXEC_EXECUTABLE} ${MPIEXEC_NUMPROC_FLAG} ${MPIEXEC_MAX_NUMPROCS} ${MPIEXEC_PREFLAGS} $<TARGET_FILE:ph5example> ${MPIEXEC_POSTFLAGS}) else () |