summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/CTest/cmCTestSubmitCommand.cxx15
-rw-r--r--Source/CTest/cmCTestSubmitCommand.h2
2 files changed, 16 insertions, 1 deletions
diff --git a/Source/CTest/cmCTestSubmitCommand.cxx b/Source/CTest/cmCTestSubmitCommand.cxx
index e1fe765..00c0610 100644
--- a/Source/CTest/cmCTestSubmitCommand.cxx
+++ b/Source/CTest/cmCTestSubmitCommand.cxx
@@ -15,7 +15,9 @@ class cmExecutionStatus;
cmCTestGenericHandler* cmCTestSubmitCommand::InitializeHandler()
{
- const char* submitURL = this->Makefile->GetDefinition("CTEST_SUBMIT_URL");
+ const char* submitURL = !this->SubmitURL.empty()
+ ? this->SubmitURL.c_str()
+ : this->Makefile->GetDefinition("CTEST_SUBMIT_URL");
if (submitURL) {
this->CTest->SetCTestConfiguration("SubmitURL", submitURL, this->Quiet);
@@ -174,6 +176,11 @@ bool cmCTestSubmitCommand::CheckArgumentKeyword(std::string const& arg)
return true;
}
+ if (arg == "SUBMIT_URL") {
+ this->ArgumentDoing = ArgumentDoingSubmitURL;
+ return true;
+ }
+
if (arg == "INTERNAL_TEST_CHECKSUM") {
this->InternalTest = true;
return true;
@@ -239,6 +246,12 @@ bool cmCTestSubmitCommand::CheckArgumentValue(std::string const& arg)
return true;
}
+ if (this->ArgumentDoing == ArgumentDoingSubmitURL) {
+ this->ArgumentDoing = ArgumentDoingNone;
+ this->SubmitURL = arg;
+ return true;
+ }
+
// Look for other arguments.
return this->Superclass::CheckArgumentValue(arg);
}
diff --git a/Source/CTest/cmCTestSubmitCommand.h b/Source/CTest/cmCTestSubmitCommand.h
index c4b84ce..0caccd6 100644
--- a/Source/CTest/cmCTestSubmitCommand.h
+++ b/Source/CTest/cmCTestSubmitCommand.h
@@ -71,6 +71,7 @@ protected:
ArgumentDoingCDashUpload,
ArgumentDoingCDashUploadType,
ArgumentDoingHttpHeader,
+ ArgumentDoingSubmitURL,
ArgumentDoingLast2
};
@@ -85,6 +86,7 @@ protected:
std::string CDashUploadFile;
std::string CDashUploadType;
std::vector<std::string> HttpHeaders;
+ std::string SubmitURL;
};
#endif