diff options
author | Allen Byrne <50328838+byrnHDF@users.noreply.github.com> | 2022-08-07 04:59:31 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-07 04:59:31 (GMT) |
commit | 956282fa6f5f5b7df92be6f14c12681f7ecabbc9 (patch) | |
tree | 262418febb0a037f752e577ab632accd358edd93 /c++/examples | |
parent | 7127d8912c8fa601d59b4e8ce522eaf149c02344 (diff) | |
download | hdf5-956282fa6f5f5b7df92be6f14c12681f7ecabbc9.zip hdf5-956282fa6f5f5b7df92be6f14c12681f7ecabbc9.tar.gz hdf5-956282fa6f5f5b7df92be6f14c12681f7ecabbc9.tar.bz2 |
Develop cmake clean (#1971)
Diffstat (limited to 'c++/examples')
-rw-r--r-- | c++/examples/CMakeTests.cmake | 63 |
1 files changed, 45 insertions, 18 deletions
diff --git a/c++/examples/CMakeTests.cmake b/c++/examples/CMakeTests.cmake index a7fc9b8..2a3bef5 100644 --- a/c++/examples/CMakeTests.cmake +++ b/c++/examples/CMakeTests.cmake @@ -16,17 +16,31 @@ ############################################################################## ############################################################################## # Remove any output file left over from previous test run +set (CPP_EX_CLEANFILES + Group.h5 + SDS.h5 + SDScompound.h5 + SDSextendible.h5 + Select.h5 +) add_test ( NAME CPP_ex-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove - Group.h5 - SDS.h5 - SDScompound.h5 - SDSextendible.h5 - Select.h5 + -E remove ${CPP_EX_CLEANFILES} +) +set_tests_properties (CPP_ex-clear-objects PROPERTIES + FIXTURES_SETUP clear_cppex + WORKING_DIRECTORY ${PROJECT_BINARY_DIR} +) +add_test ( + NAME CPP_ex-clean-objects + COMMAND ${CMAKE_COMMAND} + -E remove ${CPP_EX_CLEANFILES} +) +set_tests_properties (CPP_ex-clean-objects PROPERTIES + FIXTURES_CLEANUP clear_cppex + WORKING_DIRECTORY ${PROJECT_BINARY_DIR} ) -set_tests_properties (CPP_ex-clear-objects PROPERTIES FIXTURES_SETUP clear_cppex) foreach (example ${examples}) if (HDF5_ENABLE_USING_MEMCHECKER) @@ -53,19 +67,32 @@ endforeach () #the following dependencies are handled by the order of the files # SET_TESTS_PROPERTIES(CPP_ex_readdata PROPERTIES DEPENDS CPP_ex_create) # SET_TESTS_PROPERTIES(CPP_ex_chunks PROPERTIES DEPENDS CPP_ex_extend_ds) - +set (CPP_EX_TUTR_CLEANFILES + h5tutr_cmprss.h5 + h5tutr_dset.h5 + h5tutr_extend.h5 + h5tutr_group.h5 + h5tutr_groups.h5 + h5tutr_subset.h5 +) add_test ( NAME CPP_ex_tutr-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove - h5tutr_cmprss.h5 - h5tutr_dset.h5 - h5tutr_extend.h5 - h5tutr_group.h5 - h5tutr_groups.h5 - h5tutr_subset.h5 + -E remove ${CPP_EX_TUTR_CLEANFILES} +) +set_tests_properties (CPP_ex_tutr-clear-objects PROPERTIES + FIXTURES_SETUP clear_cppex_tutr + WORKING_DIRECTORY ${PROJECT_BINARY_DIR} +) +add_test ( + NAME CPP_ex_tutr-clean-objects + COMMAND ${CMAKE_COMMAND} + -E remove ${CPP_EX_TUTR_CLEANFILES} +) +set_tests_properties (CPP_ex_tutr-clean-objects PROPERTIES + FIXTURES_CLEANUP clear_cppex_tutr + WORKING_DIRECTORY ${PROJECT_BINARY_DIR} ) -set_tests_properties (CPP_ex_tutr-clear-objects PROPERTIES FIXTURES_SETUP clear_cppex_tutr) foreach (example ${tutr_examples}) if (HDF5_ENABLE_USING_MEMCHECKER) @@ -77,8 +104,8 @@ foreach (example ${tutr_examples}) -D "TEST_ARGS:STRING=" -D "TEST_EXPECT=0" -D "TEST_SKIP_COMPARE=TRUE" - -D "TEST_OUTPUT=cpp_ex_${example}.txt" - #-D "TEST_REFERENCE=cpp_ex_${example}.out" + -D "TEST_OUTPUT=tutr_cpp_ex_${example}.txt" + #-D "TEST_REFERENCE=cpp_ex_tutr_${example}.out" -D "TEST_FOLDER=${PROJECT_BINARY_DIR}" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) |