ENH: add a check to make sure nightly start time was specified
This commit is contained in:
parent
6baaf296a5
commit
1a11a2d0c0
@ -312,7 +312,7 @@ int cmCTest::Initialize(const char* binary_dir, bool new_tag,
|
|||||||
cmCTestLog(this, DEBUG, "Here: " << __LINE__ << std::endl);
|
cmCTestLog(this, DEBUG, "Here: " << __LINE__ << std::endl);
|
||||||
if ( this->ProduceXML )
|
if ( this->ProduceXML )
|
||||||
{
|
{
|
||||||
cmCTestLog(this, DEBUG, "Here: " << __LINE__ << std::endl);
|
cmCTestLog(this, DEBUG, "Here: " << __LINE__ << std::endl);
|
||||||
cmCTestLog(this, OUTPUT,
|
cmCTestLog(this, OUTPUT,
|
||||||
" Site: " << this->GetCTestConfiguration("Site") << std::endl
|
" Site: " << this->GetCTestConfiguration("Site") << std::endl
|
||||||
<< " Build name: " << this->GetCTestConfiguration("BuildName")
|
<< " Build name: " << this->GetCTestConfiguration("BuildName")
|
||||||
@ -320,8 +320,10 @@ int cmCTest::Initialize(const char* binary_dir, bool new_tag,
|
|||||||
cmCTestLog(this, DEBUG, "Produce XML is on" << std::endl);
|
cmCTestLog(this, DEBUG, "Produce XML is on" << std::endl);
|
||||||
if ( this->GetCTestConfiguration("NightlyStartTime").empty() )
|
if ( this->GetCTestConfiguration("NightlyStartTime").empty() )
|
||||||
{
|
{
|
||||||
cmCTestLog(this, DEBUG, "No nightly start time" << std::endl);
|
cmCTestLog(this, ERROR_MESSAGE,
|
||||||
cmCTestLog(this, DEBUG, "Here: " << __LINE__ << std::endl);
|
"No nightly start time found please set in"
|
||||||
|
" CTestConfig.cmake or DartConfig.cmake" << std::endl);
|
||||||
|
cmCTestLog(this, DEBUG, "Here: " << __LINE__ << std::endl);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1217,6 +1219,13 @@ int cmCTest::RunTest(std::vector<const char*> argv,
|
|||||||
//----------------------------------------------------------------------
|
//----------------------------------------------------------------------
|
||||||
void cmCTest::StartXML(std::ostream& ostr)
|
void cmCTest::StartXML(std::ostream& ostr)
|
||||||
{
|
{
|
||||||
|
if(this->CurrentTag.empty())
|
||||||
|
{
|
||||||
|
cmCTestLog(this, ERROR_MESSAGE,
|
||||||
|
"Current Tag empty, this may mean"
|
||||||
|
" NightlStartTime was not set correctly." << std::endl);
|
||||||
|
cmSystemTools::SetFatalErrorOccured();
|
||||||
|
}
|
||||||
ostr << "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
|
ostr << "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
|
||||||
<< "<Site BuildName=\"" << this->GetCTestConfiguration("BuildName")
|
<< "<Site BuildName=\"" << this->GetCTestConfiguration("BuildName")
|
||||||
<< "\" BuildStamp=\"" << this->CurrentTag << "-"
|
<< "\" BuildStamp=\"" << this->CurrentTag << "-"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user