diff options
author | Allen Byrne <50328838+byrnHDF@users.noreply.github.com> | 2023-03-23 00:37:04 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-23 00:37:04 (GMT) |
commit | 7b4387df4322c3a953f5747c3ffbf907875ca815 (patch) | |
tree | a2f3147456059ebb06b3fbe9675c5fc83b87863a /config/cmake | |
parent | 98728706dd800e365cee6f601873b515e5f8822c (diff) | |
download | hdf5-7b4387df4322c3a953f5747c3ffbf907875ca815.zip hdf5-7b4387df4322c3a953f5747c3ffbf907875ca815.tar.gz hdf5-7b4387df4322c3a953f5747c3ffbf907875ca815.tar.bz2 |
Merge CMake cleanup process from develop (#2622)
* Merge CMake cleanup process from develop
* Update test script files
Diffstat (limited to 'config/cmake')
-rw-r--r-- | config/cmake/CTestCustom.cmake | 15 | ||||
-rw-r--r-- | config/cmake/grepTest.cmake | 16 | ||||
-rw-r--r-- | config/cmake/jrunTest.cmake | 16 | ||||
-rw-r--r-- | config/cmake/runTest.cmake | 16 | ||||
-rw-r--r-- | config/cmake/vfdTest.cmake | 16 |
5 files changed, 79 insertions, 0 deletions
diff --git a/config/cmake/CTestCustom.cmake b/config/cmake/CTestCustom.cmake index 959e262..aac9d27 100644 --- a/config/cmake/CTestCustom.cmake +++ b/config/cmake/CTestCustom.cmake @@ -64,19 +64,32 @@ set (CTEST_CUSTOM_MEMCHECK_IGNORE H5TEST-vds_env-clear-objects PERFORM_h5perform-clear-objects HL_test-clear-objects + HL_test-clean-objects HL_FORTRAN_test-clear-objects + HL_FORTRAN_test-clean-objects FORTRAN_testhdf5-clear-objects + FORTRAN_testhdf5-clean-objects FORTRAN_flush1-clear-objects + FORTRAN_flush1-clean-objects CPP_testhdf5-clear-objects + CPP_testhdf5-clean-objects ######### examples ######### EXAMPLES-clear-objects + EXAMPLES-clean-objects CPP_ex-clear-objects + CPP_ex-clean-objects CPP_ex_tutr-clear-objects + CPP_ex_tutr-clean-objects HL_ex-clear-objects + HL_ex-clean-objects f90_ex-clear-objects + f90_ex-clean-objects HL_CPP_ptableTest-clear-objects + HL_CPP_ptableTest-clean-objects HL_CPP_ex_ptExampleFL-clear-objects + HL_CPP_ex_ptExampleFL-clean-objects HL_FORTRAN_f90_ex-clear-objects + HL_FORTRAN_f90_ex-clean-objects ######### tools/h5clear ######### H5CLEAR-clearall-objects H5CLEAR-h5clear_gentest # does not close ids by design @@ -194,5 +207,7 @@ set (CTEST_CUSTOM_MEMCHECK_IGNORE PERFORM_h5perform-clearall-objects ######### hl/tools ######### HL_TOOLS-clear-objects + HL_TOOLS-clean-objects H5WATCH-clearall-objects + H5WATCH-cleanall-objects ) diff --git a/config/cmake/grepTest.cmake b/config/cmake/grepTest.cmake index 631fca6..3b0baf5 100644 --- a/config/cmake/grepTest.cmake +++ b/config/cmake/grepTest.cmake @@ -190,6 +190,22 @@ if (TEST_FILTER) endif () endif () +if (NOT DEFINED ENV{HDF5_NOCLEANUP}) + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}") + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}) + endif () + + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}.err") + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}.err) + endif () + + if (TEST_DELETE_LIST) + foreach (dfile in ${TEST_DELETE_LIST}) + file (REMOVE ${dfile}) + endforeach () + endif () +endif () + # everything went fine... message (STATUS "Passed: The output of ${TEST_PROGRAM} matched") diff --git a/config/cmake/jrunTest.cmake b/config/cmake/jrunTest.cmake index 2ca1b75..bbf1191 100644 --- a/config/cmake/jrunTest.cmake +++ b/config/cmake/jrunTest.cmake @@ -293,6 +293,22 @@ if (TEST_SKIP_COMPARE AND NOT TEST_NO_DISPLAY) endif () endif () +if (NOT DEFINED ENV{HDF5_NOCLEANUP}) + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}") + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}) + endif () + + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}.err") + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}.err) + endif () + + if (TEST_DELETE_LIST) + foreach (dfile in ${TEST_DELETE_LIST}) + file (REMOVE ${dfile}) + endforeach () + endif () +endif () + # everything went fine... message (STATUS "${TEST_PROGRAM} Passed") diff --git a/config/cmake/runTest.cmake b/config/cmake/runTest.cmake index b373fe4..ad72a9e 100644 --- a/config/cmake/runTest.cmake +++ b/config/cmake/runTest.cmake @@ -376,6 +376,22 @@ if (TEST_SKIP_COMPARE AND NOT TEST_NO_DISPLAY) ) endif () +if (NOT DEFINED ENV{HDF5_NOCLEANUP}) + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}" AND NOT TEST_SAVE) + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}) + endif () + + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}.err") + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}.err) + endif () + + if (TEST_DELETE_LIST) + foreach (dfile in ${TEST_DELETE_LIST}) + file (REMOVE ${dfile}) + endforeach () + endif () +endif () + # everything went fine... message (STATUS "${TEST_PROGRAM} Passed") diff --git a/config/cmake/vfdTest.cmake b/config/cmake/vfdTest.cmake index f5a4e3e..fadc67f 100644 --- a/config/cmake/vfdTest.cmake +++ b/config/cmake/vfdTest.cmake @@ -72,5 +72,21 @@ endif () message (STATUS "COMMAND Error: ${TEST_ERROR}") +if (NOT DEFINED ENV{HDF5_NOCLEANUP}) + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}") + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}) + endif () + + if (EXISTS "${TEST_FOLDER}/${TEST_OUTPUT}.err") + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}.err) + endif () + + if (TEST_DELETE_LIST) + foreach (dfile in ${TEST_DELETE_LIST}) + file (REMOVE ${dfile}) + endforeach () + endif () +endif () + # everything went fine... message (STATUS "Passed: The ${TEST_PROGRAM} program used vfd ${TEST_VFD}") |