From: Matthias Maier Date: Tue, 11 Jul 2023 15:53:21 +0000 (-0500) Subject: Testsuite: print summary also for SKIP_SUBMISSION=true X-Git-Tag: relicensing~696^2~3 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1706b269fdbf15e9ee090e6ea5ad966905830574;p=dealii.git Testsuite: print summary also for SKIP_SUBMISSION=true --- diff --git a/tests/run_testsuite.cmake b/tests/run_testsuite.cmake index 9b5f374002..a9e68bad62 100644 --- a/tests/run_testsuite.cmake +++ b/tests/run_testsuite.cmake @@ -534,7 +534,7 @@ if("${_res}" STREQUAL "0") set(CTEST_BUILD_CONFIGURATION "${JOB_BUILD_CONFIGURATION}") endif() - message("-- Running CTEST_TESTS()") + message("-- Running ctest_tests()") ctest_test() if(COVERAGE) @@ -579,41 +579,47 @@ endif() if(NOT SKIP_SUBMISSION) message("-- Running ctest_submit()") ctest_submit(RETURN_VALUE _res BUILD_ID _build_id) - if("${_res}" STREQUAL "0") message("-- Submission successful.") + set(_cdash_url "https://cdash.dealii.org/build/${_build_id}") + else() + message("-- Submission failed.") + set(_cdash_url "-- submission failed --") + endif() +else() + set(_cdash_url "-- submission skipped --") +endif() - # - # Grab git revision from our revision.log: - # - file(STRINGS "${CTEST_BINARY_DIRECTORY}/revision.log" _revision REGEX "Revision:") - string(REGEX REPLACE "#.*Revision: " "" _revision "${_revision}") - - # - # Configure or build errors are easy, but determining whether we - # encountered configure or build warnings, or test failures is - # remarkably tricky. None of the ctest_* commands return a value that - # would help us :-( - # - if("${_status}" STREQUAL "neutral") - # grab tag: - file(STRINGS ${CTEST_BINARY_DIRECTORY}/Testing/TAG _tag LIMIT_COUNT 1) - set(_path "${CTEST_BINARY_DIRECTORY}/Testing/${_tag}") - if(EXISTS ${_path}) - - else() - message(WARNING "Unable to locate test submission files from TAG.") - endif() - endif() - message("### +# +# Grab git revision from our revision.log: +# +file(STRINGS "${CTEST_BINARY_DIRECTORY}/revision.log" _revision REGEX "Revision:") +string(REGEX REPLACE "#.*Revision: " "" _revision "${_revision}") + +# +# Configure or build errors are easy, but determining whether we +# encountered configure or build warnings, or test failures is remarkably +# tricky. None of the ctest_* commands return a value that would help us +# :-( +# +if("${_status}" STREQUAL "neutral") + # grab tag: + file(STRINGS ${CTEST_BINARY_DIRECTORY}/Testing/TAG _tag LIMIT_COUNT 1) + set(_path "${CTEST_BINARY_DIRECTORY}/Testing/${_tag}") + if(EXISTS ${_path}) + + else() + message(WARNING "Unable to locate test submission files from TAG.") + endif() +endif() + +message("### # # Revision: ${_revision} # Site: ${CTEST_SITE} # Configuration: ${CTEST_BUILD_NAME} -# Results: https://cdash.dealii.org/build/${_build_id} +# CDash URL: ${_cdash_url} # Status: ${_status} # ###") - endif() -endif()