Commit c0cedaa6 authored by Brad King's avatar Brad King Committed by Kitware Robot

Merge topic 'ctest-more_submit_params'

7f530cc5 ctest_submit: pass additional info to CDash
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Merge-request: !2380
parents 76a19eb6 7f530cc5
......@@ -425,6 +425,29 @@ bool cmCTestSubmitHandler::SubmitUsingHTTP(const std::string& localprefix,
((url.find('?') == std::string::npos) ? '?' : '&') +
"FileName=" + ofile;
cmCTestCurl ctest_curl(this->CTest);
upload_as += "&build=";
upload_as +=
ctest_curl.Escape(this->CTest->GetCTestConfiguration("BuildName"));
upload_as += "&site=";
upload_as +=
ctest_curl.Escape(this->CTest->GetCTestConfiguration("Site"));
upload_as += "&stamp=";
upload_as += ctest_curl.Escape(this->CTest->GetCurrentTag());
upload_as += "-";
upload_as += ctest_curl.Escape(this->CTest->GetTestModelString());
cmCTestScriptHandler* ch =
static_cast<cmCTestScriptHandler*>(this->CTest->GetHandler("script"));
cmake* cm = ch->GetCMake();
if (cm) {
const char* subproject =
cm->GetState()->GetGlobalProperty("SubProject");
if (subproject) {
upload_as += "&subproject=";
upload_as += ctest_curl.Escape(subproject);
}
}
upload_as += "&MD5=";
if (cmSystemTools::IsOn(this->GetOption("InternalTest"))) {
......
*Error message was: ([Cc]ould *n.t resolve host:? '?-no-site-'?.*|The requested URL returned error:.*)
Upload file: .* to http:\/\/-no-site-\?FileName=test-site___test-build-name___.*-Experimental___XML___Configure.xml&build=test-build-name&site=test-site&stamp=.*-Experimental&subproject=mysubproj&MD5=.* Size: .*
......@@ -30,6 +30,7 @@ run_ctest_submit(CDashUploadNone CDASH_UPLOAD)
run_ctest_submit(CDashUploadMissingFile CDASH_UPLOAD bad-upload)
run_ctest_submit(CDashUploadRetry CDASH_UPLOAD ${CMAKE_CURRENT_LIST_FILE} CDASH_UPLOAD_TYPE foo RETRY_COUNT 2 RETRY_DELAY 1 INTERNAL_TEST_CHECKSUM)
run_ctest_submit(CDashSubmitQuiet QUIET)
run_ctest_submit_debug(CDashSubmitVerbose)
run_ctest_submit_debug(CDashSubmitHeaders HTTPHEADER "Authorization: Bearer asdf")
run_ctest_submit_debug(CDashUploadHeaders CDASH_UPLOAD ${CMAKE_CURRENT_LIST_FILE} CDASH_UPLOAD_TYPE foo HTTPHEADER "Authorization: Bearer asdf")
......
......@@ -9,6 +9,7 @@ set(CTEST_CMAKE_GENERATOR_PLATFORM "@RunCMake_GENERATOR_PLATFORM@")
set(CTEST_CMAKE_GENERATOR_TOOLSET "@RunCMake_GENERATOR_TOOLSET@")
set(CTEST_BUILD_CONFIGURATION "$ENV{CMAKE_CONFIG_TYPE}")
set_property(GLOBAL PROPERTY SubProject "mysubproj")
ctest_start(Experimental)
ctest_configure()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment