Remove trailing whitespace
This commit is contained in:
parent
e0d64d5cb1
commit
a1711f1c6b
|
@ -164,7 +164,7 @@ cmCTestScriptHandler::~cmCTestScriptHandler()
|
||||||
|
|
||||||
//----------------------------------------------------------------------
|
//----------------------------------------------------------------------
|
||||||
// just adds an argument to the vector
|
// just adds an argument to the vector
|
||||||
void cmCTestScriptHandler::AddConfigurationScript(const char *script,
|
void cmCTestScriptHandler::AddConfigurationScript(const char *script,
|
||||||
bool pscope)
|
bool pscope)
|
||||||
{
|
{
|
||||||
this->ConfigurationScripts.push_back(script);
|
this->ConfigurationScripts.push_back(script);
|
||||||
|
@ -224,12 +224,12 @@ int cmCTestScriptHandler::ExecuteScript(const std::string& total_script_arg)
|
||||||
argv.push_back("-SR");
|
argv.push_back("-SR");
|
||||||
argv.push_back(total_script_arg.c_str());
|
argv.push_back(total_script_arg.c_str());
|
||||||
|
|
||||||
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
|
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
|
||||||
"Executable for CTest is: " <<
|
"Executable for CTest is: " <<
|
||||||
this->CTest->GetCTestExecutable() << "\n");
|
this->CTest->GetCTestExecutable() << "\n");
|
||||||
|
|
||||||
// now pass through all the other arguments
|
// now pass through all the other arguments
|
||||||
std::vector<cmStdString> &initArgs =
|
std::vector<cmStdString> &initArgs =
|
||||||
this->CTest->GetInitialCommandLineArguments();
|
this->CTest->GetInitialCommandLineArguments();
|
||||||
//*** need to make sure this does not have the current script ***
|
//*** need to make sure this does not have the current script ***
|
||||||
for(size_t i=1; i < initArgs.size(); ++i)
|
for(size_t i=1; i < initArgs.size(); ++i)
|
||||||
|
@ -252,7 +252,7 @@ int cmCTestScriptHandler::ExecuteScript(const std::string& total_script_arg)
|
||||||
int pipe = cmSystemTools::WaitForLine(cp, line, 100.0, out, err);
|
int pipe = cmSystemTools::WaitForLine(cp, line, 100.0, out, err);
|
||||||
while(pipe != cmsysProcess_Pipe_None)
|
while(pipe != cmsysProcess_Pipe_None)
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, "Output: "
|
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, "Output: "
|
||||||
<< line << "\n");
|
<< line << "\n");
|
||||||
if(pipe == cmsysProcess_Pipe_STDERR)
|
if(pipe == cmsysProcess_Pipe_STDERR)
|
||||||
{
|
{
|
||||||
|
@ -264,7 +264,7 @@ int cmCTestScriptHandler::ExecuteScript(const std::string& total_script_arg)
|
||||||
}
|
}
|
||||||
pipe = cmSystemTools::WaitForLine(cp, line, 100, out, err);
|
pipe = cmSystemTools::WaitForLine(cp, line, 100, out, err);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Properly handle output of the build command
|
// Properly handle output of the build command
|
||||||
cmsysProcess_WaitForExit(cp, 0);
|
cmsysProcess_WaitForExit(cp, 0);
|
||||||
int result = cmsysProcess_GetState(cp);
|
int result = cmsysProcess_GetState(cp);
|
||||||
|
@ -278,7 +278,7 @@ int cmCTestScriptHandler::ExecuteScript(const std::string& total_script_arg)
|
||||||
{
|
{
|
||||||
retVal = cmsysProcess_GetExitException(cp);
|
retVal = cmsysProcess_GetExitException(cp);
|
||||||
cmCTestLog(this->CTest, ERROR_MESSAGE, "\tThere was an exception: "
|
cmCTestLog(this->CTest, ERROR_MESSAGE, "\tThere was an exception: "
|
||||||
<< cmsysProcess_GetExceptionString(cp) << " " <<
|
<< cmsysProcess_GetExceptionString(cp) << " " <<
|
||||||
retVal << std::endl);
|
retVal << std::endl);
|
||||||
failed = true;
|
failed = true;
|
||||||
}
|
}
|
||||||
|
@ -338,7 +338,7 @@ void cmCTestScriptHandler::CreateCMake()
|
||||||
this->Makefile->SetStartDirectory(cwd.c_str());
|
this->Makefile->SetStartDirectory(cwd.c_str());
|
||||||
this->Makefile->SetStartOutputDirectory(cwd.c_str());
|
this->Makefile->SetStartOutputDirectory(cwd.c_str());
|
||||||
|
|
||||||
// remove all cmake commands which are not scriptable, since they can't be
|
// remove all cmake commands which are not scriptable, since they can't be
|
||||||
// used in ctest scripts
|
// used in ctest scripts
|
||||||
this->CMake->RemoveUnscriptableCommands();
|
this->CMake->RemoveUnscriptableCommands();
|
||||||
|
|
||||||
|
@ -418,17 +418,17 @@ int cmCTestScriptHandler::ReadInScript(const std::string& total_script_arg)
|
||||||
this->Makefile->AddFunctionBlocker(f);
|
this->Makefile->AddFunctionBlocker(f);
|
||||||
|
|
||||||
|
|
||||||
/* Execute CTestScriptMode.cmake, which loads CMakeDetermineSystem and
|
/* Execute CTestScriptMode.cmake, which loads CMakeDetermineSystem and
|
||||||
CMakeSystemSpecificInformation, so
|
CMakeSystemSpecificInformation, so
|
||||||
that variables like CMAKE_SYSTEM and also the search paths for libraries,
|
that variables like CMAKE_SYSTEM and also the search paths for libraries,
|
||||||
header and executables are set correctly and can be used. Makes new-style
|
header and executables are set correctly and can be used. Makes new-style
|
||||||
ctest scripting easier. */
|
ctest scripting easier. */
|
||||||
std::string systemFile =
|
std::string systemFile =
|
||||||
this->Makefile->GetModulesFile("CTestScriptMode.cmake");
|
this->Makefile->GetModulesFile("CTestScriptMode.cmake");
|
||||||
if (!this->Makefile->ReadListFile(0, systemFile.c_str()) ||
|
if (!this->Makefile->ReadListFile(0, systemFile.c_str()) ||
|
||||||
cmSystemTools::GetErrorOccuredFlag())
|
cmSystemTools::GetErrorOccuredFlag())
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, ERROR_MESSAGE, "Error in read:"
|
cmCTestLog(this->CTest, ERROR_MESSAGE, "Error in read:"
|
||||||
<< systemFile.c_str() << "\n");
|
<< systemFile.c_str() << "\n");
|
||||||
return 2;
|
return 2;
|
||||||
}
|
}
|
||||||
|
@ -440,8 +440,8 @@ int cmCTestScriptHandler::ReadInScript(const std::string& total_script_arg)
|
||||||
cmCTestLog(this->CTest, ERROR_MESSAGE, "Error in read script: "
|
cmCTestLog(this->CTest, ERROR_MESSAGE, "Error in read script: "
|
||||||
<< script.c_str()
|
<< script.c_str()
|
||||||
<< std::endl);
|
<< std::endl);
|
||||||
// Reset the error flag so that it can run more than
|
// Reset the error flag so that it can run more than
|
||||||
// one script with an error when you
|
// one script with an error when you
|
||||||
// use ctest_run_script
|
// use ctest_run_script
|
||||||
cmSystemTools::ResetErrorOccuredFlag();
|
cmSystemTools::ResetErrorOccuredFlag();
|
||||||
return 2;
|
return 2;
|
||||||
|
@ -880,7 +880,7 @@ int cmCTestScriptHandler::RunConfigurationDashboard()
|
||||||
// put the initial cache into the bin dir
|
// put the initial cache into the bin dir
|
||||||
if (!this->InitialCache.empty())
|
if (!this->InitialCache.empty())
|
||||||
{
|
{
|
||||||
if (!this->WriteInitialCache(this->BinaryDir.c_str(),
|
if (!this->WriteInitialCache(this->BinaryDir.c_str(),
|
||||||
this->InitialCache.c_str()))
|
this->InitialCache.c_str()))
|
||||||
{
|
{
|
||||||
this->RestoreBackupDirectories();
|
this->RestoreBackupDirectories();
|
||||||
|
@ -986,7 +986,7 @@ int cmCTestScriptHandler::RunConfigurationDashboard()
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
bool cmCTestScriptHandler::WriteInitialCache(const char* directory,
|
bool cmCTestScriptHandler::WriteInitialCache(const char* directory,
|
||||||
const char* text)
|
const char* text)
|
||||||
{
|
{
|
||||||
std::string cacheFile = directory;
|
std::string cacheFile = directory;
|
||||||
|
@ -1032,7 +1032,7 @@ void cmCTestScriptHandler::RestoreBackupDirectories()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool cmCTestScriptHandler::RunScript(cmCTest* ctest, const char *sname,
|
bool cmCTestScriptHandler::RunScript(cmCTest* ctest, const char *sname,
|
||||||
bool InProcess, int* returnValue)
|
bool InProcess, int* returnValue)
|
||||||
{
|
{
|
||||||
cmCTestScriptHandler* sh = new cmCTestScriptHandler();
|
cmCTestScriptHandler* sh = new cmCTestScriptHandler();
|
||||||
|
@ -1076,13 +1076,13 @@ double cmCTestScriptHandler::GetRemainingTimeAllowed()
|
||||||
|
|
||||||
const char *timelimitS
|
const char *timelimitS
|
||||||
= this->Makefile->GetDefinition("CTEST_TIME_LIMIT");
|
= this->Makefile->GetDefinition("CTEST_TIME_LIMIT");
|
||||||
|
|
||||||
if (!timelimitS)
|
if (!timelimitS)
|
||||||
{
|
{
|
||||||
return 1.0e7;
|
return 1.0e7;
|
||||||
}
|
}
|
||||||
|
|
||||||
double timelimit = atof(timelimitS);
|
double timelimit = atof(timelimitS);
|
||||||
|
|
||||||
return timelimit - cmSystemTools::GetTime() + this->ScriptStartTime;
|
return timelimit - cmSystemTools::GetTime() + this->ScriptStartTime;
|
||||||
}
|
}
|
||||||
|
|
|
@ -296,7 +296,7 @@ bool cmCTestSubmitHandler::SubmitUsingFTP(const cmStdString& localprefix,
|
||||||
*this->LogFile << " Error when uploading file: "
|
*this->LogFile << " Error when uploading file: "
|
||||||
<< local_file.c_str()
|
<< local_file.c_str()
|
||||||
<< std::endl
|
<< std::endl
|
||||||
<< " Error message was: "
|
<< " Error message was: "
|
||||||
<< error_buffer << std::endl
|
<< error_buffer << std::endl
|
||||||
<< " Curl output was: ";
|
<< " Curl output was: ";
|
||||||
// avoid dereference of empty vector
|
// avoid dereference of empty vector
|
||||||
|
@ -364,13 +364,13 @@ bool cmCTestSubmitHandler::SubmitUsingHTTP(const cmStdString& localprefix,
|
||||||
{
|
{
|
||||||
if(verifyPeerOff)
|
if(verifyPeerOff)
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
|
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
|
||||||
" Set CURLOPT_SSL_VERIFYPEER to off\n");
|
" Set CURLOPT_SSL_VERIFYPEER to off\n");
|
||||||
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, 0);
|
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, 0);
|
||||||
}
|
}
|
||||||
if(verifyHostOff)
|
if(verifyHostOff)
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
|
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
|
||||||
" Set CURLOPT_SSL_VERIFYHOST to off\n");
|
" Set CURLOPT_SSL_VERIFYHOST to off\n");
|
||||||
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, 0);
|
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, 0);
|
||||||
}
|
}
|
||||||
|
@ -601,7 +601,7 @@ bool cmCTestSubmitHandler::SubmitUsingHTTP(const cmStdString& localprefix,
|
||||||
*this->LogFile << " Error when uploading file: "
|
*this->LogFile << " Error when uploading file: "
|
||||||
<< local_file.c_str()
|
<< local_file.c_str()
|
||||||
<< std::endl
|
<< std::endl
|
||||||
<< " Error message was: " << error_buffer
|
<< " Error message was: " << error_buffer
|
||||||
<< std::endl;
|
<< std::endl;
|
||||||
// avoid deref of begin for zero size array
|
// avoid deref of begin for zero size array
|
||||||
if(chunk.size())
|
if(chunk.size())
|
||||||
|
@ -763,7 +763,7 @@ bool cmCTestSubmitHandler::TriggerUsingHTTP(
|
||||||
<< error_buffer << std::endl);
|
<< error_buffer << std::endl);
|
||||||
*this->LogFile << "\tTriggering failed with error: " << error_buffer
|
*this->LogFile << "\tTriggering failed with error: " << error_buffer
|
||||||
<< std::endl
|
<< std::endl
|
||||||
<< " Error message was: " << error_buffer
|
<< " Error message was: " << error_buffer
|
||||||
<< std::endl;
|
<< std::endl;
|
||||||
if(chunk.size())
|
if(chunk.size())
|
||||||
{
|
{
|
||||||
|
@ -913,8 +913,8 @@ bool cmCTestSubmitHandler::SubmitUsingCP(
|
||||||
{
|
{
|
||||||
if ( !localprefix.size() ||
|
if ( !localprefix.size() ||
|
||||||
!files.size() || !remoteprefix.size() || !destination.size() )
|
!files.size() || !remoteprefix.size() || !destination.size() )
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, ERROR_MESSAGE,
|
cmCTestLog(this->CTest, ERROR_MESSAGE,
|
||||||
"Missing arguments for submit via cp:\n"
|
"Missing arguments for submit via cp:\n"
|
||||||
<< "\tlocalprefix: " << localprefix << "\n"
|
<< "\tlocalprefix: " << localprefix << "\n"
|
||||||
<< "\tNumber of files: " << files.size() << "\n"
|
<< "\tNumber of files: " << files.size() << "\n"
|
||||||
|
@ -1285,7 +1285,7 @@ int cmCTestSubmitHandler::ProcessHandler()
|
||||||
<< std::endl);
|
<< std::endl);
|
||||||
ofs << " Problems when submitting via FTP" << std::endl;
|
ofs << " Problems when submitting via FTP" << std::endl;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
if(!this->CDash)
|
if(!this->CDash)
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, HANDLER_OUTPUT, " Using HTTP trigger method"
|
cmCTestLog(this->CTest, HANDLER_OUTPUT, " Using HTTP trigger method"
|
||||||
|
@ -1369,7 +1369,7 @@ int cmCTestSubmitHandler::ProcessHandler()
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, HANDLER_OUTPUT, " Submission successful" <<
|
cmCTestLog(this->CTest, HANDLER_OUTPUT, " Submission successful" <<
|
||||||
(this->HasWarnings ? ", with warnings." : "") << std::endl);
|
(this->HasWarnings ? ", with warnings." : "") << std::endl);
|
||||||
ofs << " Submission successful" <<
|
ofs << " Submission successful" <<
|
||||||
(this->HasWarnings ? ", with warnings." : "") << std::endl;
|
(this->HasWarnings ? ", with warnings." : "") << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1439,20 +1439,20 @@ int cmCTestSubmitHandler::ProcessHandler()
|
||||||
{
|
{
|
||||||
std::string location
|
std::string location
|
||||||
= this->CTest->GetCTestConfiguration("DropLocation");
|
= this->CTest->GetCTestConfiguration("DropLocation");
|
||||||
|
|
||||||
|
|
||||||
// change to the build directory so that we can uses a relative path
|
// change to the build directory so that we can uses a relative path
|
||||||
// on windows since scp dosn't support "c:" a drive in the path
|
// on windows since scp dosn't support "c:" a drive in the path
|
||||||
std::string
|
std::string
|
||||||
oldWorkingDirectory = cmSystemTools::GetCurrentWorkingDirectory();
|
oldWorkingDirectory = cmSystemTools::GetCurrentWorkingDirectory();
|
||||||
cmSystemTools::ChangeDirectory(buildDirectory.c_str());
|
cmSystemTools::ChangeDirectory(buildDirectory.c_str());
|
||||||
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, " Change directory: "
|
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT, " Change directory: "
|
||||||
<< buildDirectory.c_str() << std::endl);
|
<< buildDirectory.c_str() << std::endl);
|
||||||
|
|
||||||
if ( !this->SubmitUsingCP(
|
if ( !this->SubmitUsingCP(
|
||||||
"Testing/"+this->CTest->GetCurrentTag(),
|
"Testing/"+this->CTest->GetCurrentTag(),
|
||||||
files,
|
files,
|
||||||
prefix,
|
prefix,
|
||||||
location) )
|
location) )
|
||||||
{
|
{
|
||||||
cmSystemTools::ChangeDirectory(oldWorkingDirectory.c_str());
|
cmSystemTools::ChangeDirectory(oldWorkingDirectory.c_str());
|
||||||
|
|
|
@ -108,7 +108,7 @@ bool cmCTestSubdirCommand
|
||||||
// does the CTestTestfile.cmake exist ?
|
// does the CTestTestfile.cmake exist ?
|
||||||
testFilename = "CTestTestfile.cmake";
|
testFilename = "CTestTestfile.cmake";
|
||||||
}
|
}
|
||||||
else if( cmSystemTools::FileExists("DartTestfile.txt") )
|
else if( cmSystemTools::FileExists("DartTestfile.txt") )
|
||||||
{
|
{
|
||||||
// does the DartTestfile.txt exist ?
|
// does the DartTestfile.txt exist ?
|
||||||
testFilename = "DartTestfile.txt";
|
testFilename = "DartTestfile.txt";
|
||||||
|
@ -121,7 +121,7 @@ bool cmCTestSubdirCommand
|
||||||
}
|
}
|
||||||
fname += "/";
|
fname += "/";
|
||||||
fname += testFilename;
|
fname += testFilename;
|
||||||
bool readit =
|
bool readit =
|
||||||
this->Makefile->ReadListFile(this->Makefile->GetCurrentListFile(),
|
this->Makefile->ReadListFile(this->Makefile->GetCurrentListFile(),
|
||||||
fname.c_str());
|
fname.c_str());
|
||||||
cmSystemTools::ChangeDirectory(cwd.c_str());
|
cmSystemTools::ChangeDirectory(cwd.c_str());
|
||||||
|
@ -212,7 +212,7 @@ bool cmCTestAddSubdirectoryCommand
|
||||||
}
|
}
|
||||||
fname += "/";
|
fname += "/";
|
||||||
fname += testFilename;
|
fname += testFilename;
|
||||||
bool readit =
|
bool readit =
|
||||||
this->Makefile->ReadListFile(this->Makefile->GetCurrentListFile(),
|
this->Makefile->ReadListFile(this->Makefile->GetCurrentListFile(),
|
||||||
fname.c_str());
|
fname.c_str());
|
||||||
cmSystemTools::ChangeDirectory(cwd.c_str());
|
cmSystemTools::ChangeDirectory(cwd.c_str());
|
||||||
|
@ -538,7 +538,7 @@ int cmCTestTestHandler::ProcessHandler()
|
||||||
this->UseExcludeRegExp();
|
this->UseExcludeRegExp();
|
||||||
this->SetExcludeRegExp(val);
|
this->SetExcludeRegExp(val);
|
||||||
}
|
}
|
||||||
|
|
||||||
this->TestResults.clear();
|
this->TestResults.clear();
|
||||||
|
|
||||||
cmCTestLog(this->CTest, HANDLER_OUTPUT,
|
cmCTestLog(this->CTest, HANDLER_OUTPUT,
|
||||||
|
@ -616,7 +616,7 @@ int cmCTestTestHandler::ProcessHandler()
|
||||||
cmCTestLog(this->CTest, HANDLER_OUTPUT, std::endl
|
cmCTestLog(this->CTest, HANDLER_OUTPUT, std::endl
|
||||||
<< "The following tests FAILED:" << std::endl);
|
<< "The following tests FAILED:" << std::endl);
|
||||||
this->StartLogFile("TestsFailed", ofs);
|
this->StartLogFile("TestsFailed", ofs);
|
||||||
|
|
||||||
std::vector<cmCTestTestHandler::cmCTestTestResult>::iterator ftit;
|
std::vector<cmCTestTestHandler::cmCTestTestResult>::iterator ftit;
|
||||||
for(ftit = this->TestResults.begin();
|
for(ftit = this->TestResults.begin();
|
||||||
ftit != this->TestResults.end(); ++ftit)
|
ftit != this->TestResults.end(); ++ftit)
|
||||||
|
@ -625,9 +625,9 @@ int cmCTestTestHandler::ProcessHandler()
|
||||||
{
|
{
|
||||||
ofs << ftit->TestCount << ":" << ftit->Name << std::endl;
|
ofs << ftit->TestCount << ":" << ftit->Name << std::endl;
|
||||||
cmCTestLog(this->CTest, HANDLER_OUTPUT, "\t" << std::setw(3)
|
cmCTestLog(this->CTest, HANDLER_OUTPUT, "\t" << std::setw(3)
|
||||||
<< ftit->TestCount << " - "
|
<< ftit->TestCount << " - "
|
||||||
<< ftit->Name.c_str() << " ("
|
<< ftit->Name.c_str() << " ("
|
||||||
<< this->GetTestStatus(ftit->Status) << ")"
|
<< this->GetTestStatus(ftit->Status) << ")"
|
||||||
<< std::endl);
|
<< std::endl);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -696,18 +696,18 @@ void cmCTestTestHandler::PrintLabelSummary()
|
||||||
// fill maps
|
// fill maps
|
||||||
for(; ri != this->TestResults.end(); ++ri)
|
for(; ri != this->TestResults.end(); ++ri)
|
||||||
{
|
{
|
||||||
cmCTestTestResult &result = *ri;
|
cmCTestTestResult &result = *ri;
|
||||||
cmCTestTestProperties& p = *result.Properties;
|
cmCTestTestProperties& p = *result.Properties;
|
||||||
if(p.Labels.size() != 0)
|
if(p.Labels.size() != 0)
|
||||||
{
|
{
|
||||||
for(std::vector<std::string>::iterator l = p.Labels.begin();
|
for(std::vector<std::string>::iterator l = p.Labels.begin();
|
||||||
l != p.Labels.end(); ++l)
|
l != p.Labels.end(); ++l)
|
||||||
{
|
{
|
||||||
labelTimes[*l] += result.ExecutionTime;
|
labelTimes[*l] += result.ExecutionTime;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// now print times
|
// now print times
|
||||||
if(labels.size())
|
if(labels.size())
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, HANDLER_OUTPUT, "\nLabel Time Summary:");
|
cmCTestLog(this->CTest, HANDLER_OUTPUT, "\nLabel Time Summary:");
|
||||||
|
@ -728,7 +728,7 @@ void cmCTestTestHandler::PrintLabelSummary()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(labels.size())
|
if(labels.size())
|
||||||
{
|
{
|
||||||
if(this->LogFile)
|
if(this->LogFile)
|
||||||
{
|
{
|
||||||
*this->LogFile << "\n";
|
*this->LogFile << "\n";
|
||||||
|
@ -840,7 +840,7 @@ void cmCTestTestHandler::ComputeTestList()
|
||||||
// Now create a final list of tests to run
|
// Now create a final list of tests to run
|
||||||
int cnt = 0;
|
int cnt = 0;
|
||||||
inREcnt = 0;
|
inREcnt = 0;
|
||||||
std::string last_directory = "";
|
std::string last_directory = "";
|
||||||
ListOfTests finalList;
|
ListOfTests finalList;
|
||||||
for ( it = this->TestList.begin(); it != this->TestList.end(); it ++ )
|
for ( it = this->TestList.begin(); it != this->TestList.end(); it ++ )
|
||||||
{
|
{
|
||||||
|
@ -888,13 +888,13 @@ void cmCTestTestHandler::ComputeTestList()
|
||||||
max = p.Name.size();
|
max = p.Name.size();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(static_cast<std::string::size_type>(this->CTest->GetMaxTestNameWidth())
|
if(static_cast<std::string::size_type>(this->CTest->GetMaxTestNameWidth())
|
||||||
!= max)
|
!= max)
|
||||||
{
|
{
|
||||||
this->CTest->SetMaxTestNameWidth(static_cast<int>(max));
|
this->CTest->SetMaxTestNameWidth(static_cast<int>(max));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool cmCTestTestHandler::GetValue(const char* tag,
|
bool cmCTestTestHandler::GetValue(const char* tag,
|
||||||
int& value,
|
int& value,
|
||||||
std::ifstream& fin)
|
std::ifstream& fin)
|
||||||
|
@ -984,7 +984,7 @@ bool cmCTestTestHandler::GetValue(const char* tag,
|
||||||
ret = cmSystemTools::GetLineFromStream(fin, line); // read blank line
|
ret = cmSystemTools::GetLineFromStream(fin, line); // read blank line
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
cmCTestLog(this->CTest, ERROR_MESSAGE,
|
cmCTestLog(this->CTest, ERROR_MESSAGE,
|
||||||
"parse error: missing tag: "
|
"parse error: missing tag: "
|
||||||
<< tag << " found [" << line.c_str() << "]" << std::endl);
|
<< tag << " found [" << line.c_str() << "]" << std::endl);
|
||||||
|
@ -1036,7 +1036,7 @@ void cmCTestTestHandler::ProcessDirectory(std::vector<cmStdString> &passed,
|
||||||
|
|
||||||
cmCTestMultiProcessHandler::TestMap tests;
|
cmCTestMultiProcessHandler::TestMap tests;
|
||||||
cmCTestMultiProcessHandler::PropertiesMap properties;
|
cmCTestMultiProcessHandler::PropertiesMap properties;
|
||||||
|
|
||||||
bool randomSchedule = this->CTest->GetScheduleType() == "Random";
|
bool randomSchedule = this->CTest->GetScheduleType() == "Random";
|
||||||
if(randomSchedule)
|
if(randomSchedule)
|
||||||
{
|
{
|
||||||
|
@ -1045,7 +1045,7 @@ void cmCTestTestHandler::ProcessDirectory(std::vector<cmStdString> &passed,
|
||||||
|
|
||||||
for (ListOfTests::iterator it = this->TestList.begin();
|
for (ListOfTests::iterator it = this->TestList.begin();
|
||||||
it != this->TestList.end(); ++it)
|
it != this->TestList.end(); ++it)
|
||||||
{
|
{
|
||||||
cmCTestTestProperties& p = *it;
|
cmCTestTestProperties& p = *it;
|
||||||
cmCTestMultiProcessHandler::TestSet depends;
|
cmCTestMultiProcessHandler::TestSet depends;
|
||||||
|
|
||||||
|
@ -1158,7 +1158,7 @@ void cmCTestTestHandler::GenerateDartOutput(std::ostream& os)
|
||||||
<< result->ExecutionTime
|
<< result->ExecutionTime
|
||||||
<< "</Value></NamedMeasurement>\n";
|
<< "</Value></NamedMeasurement>\n";
|
||||||
if(result->Reason.size())
|
if(result->Reason.size())
|
||||||
{
|
{
|
||||||
const char* reasonType = "Pass Reason";
|
const char* reasonType = "Pass Reason";
|
||||||
if(result->Status != cmCTestTestHandler::COMPLETED &&
|
if(result->Status != cmCTestTestHandler::COMPLETED &&
|
||||||
result->Status != cmCTestTestHandler::NOT_RUN)
|
result->Status != cmCTestTestHandler::NOT_RUN)
|
||||||
|
@ -1195,7 +1195,7 @@ void cmCTestTestHandler::GenerateDartOutput(std::ostream& os)
|
||||||
os
|
os
|
||||||
<< "\t\t\t<Measurement>\n"
|
<< "\t\t\t<Measurement>\n"
|
||||||
<< "\t\t\t\t<Value"
|
<< "\t\t\t\t<Value"
|
||||||
<< (result->CompressOutput ?
|
<< (result->CompressOutput ?
|
||||||
" encoding=\"base64\" compression=\"gzip\">"
|
" encoding=\"base64\" compression=\"gzip\">"
|
||||||
: ">");
|
: ">");
|
||||||
os << cmXMLSafe(result->Output);
|
os << cmXMLSafe(result->Output);
|
||||||
|
@ -1278,7 +1278,7 @@ void cmCTestTestHandler::AttachFiles(std::ostream& os,
|
||||||
result->Properties->AttachOnFail.begin(),
|
result->Properties->AttachOnFail.begin(),
|
||||||
result->Properties->AttachOnFail.end());
|
result->Properties->AttachOnFail.end());
|
||||||
}
|
}
|
||||||
for(std::vector<std::string>::const_iterator file =
|
for(std::vector<std::string>::const_iterator file =
|
||||||
result->Properties->AttachedFiles.begin();
|
result->Properties->AttachedFiles.begin();
|
||||||
file != result->Properties->AttachedFiles.end(); ++file)
|
file != result->Properties->AttachedFiles.end(); ++file)
|
||||||
{
|
{
|
||||||
|
@ -1322,7 +1322,7 @@ std::string cmCTestTestHandler::EncodeFile(std::string file)
|
||||||
|
|
||||||
unsigned long rlen
|
unsigned long rlen
|
||||||
= cmsysBase64_Encode(file_buffer, len, encoded_buffer, 1);
|
= cmsysBase64_Encode(file_buffer, len, encoded_buffer, 1);
|
||||||
|
|
||||||
std::string base64 = "";
|
std::string base64 = "";
|
||||||
for(unsigned long i = 0; i < rlen; i++)
|
for(unsigned long i = 0; i < rlen; i++)
|
||||||
{
|
{
|
||||||
|
@ -1370,7 +1370,7 @@ std::string cmCTestTestHandler::FindTheExecutable(const char *exe)
|
||||||
|
|
||||||
// add additional configurations to the search path
|
// add additional configurations to the search path
|
||||||
void cmCTestTestHandler
|
void cmCTestTestHandler
|
||||||
::AddConfigurations(cmCTest *ctest,
|
::AddConfigurations(cmCTest *ctest,
|
||||||
std::vector<std::string> &attempted,
|
std::vector<std::string> &attempted,
|
||||||
std::vector<std::string> &attemptedConfigs,
|
std::vector<std::string> &attemptedConfigs,
|
||||||
std::string filepath,
|
std::string filepath,
|
||||||
|
@ -1378,7 +1378,7 @@ void cmCTestTestHandler
|
||||||
{
|
{
|
||||||
std::string tempPath;
|
std::string tempPath;
|
||||||
|
|
||||||
if (filepath.size() &&
|
if (filepath.size() &&
|
||||||
filepath[filepath.size()-1] != '/')
|
filepath[filepath.size()-1] != '/')
|
||||||
{
|
{
|
||||||
filepath += "/";
|
filepath += "/";
|
||||||
|
@ -1386,7 +1386,7 @@ void cmCTestTestHandler
|
||||||
tempPath = filepath + filename;
|
tempPath = filepath + filename;
|
||||||
attempted.push_back(tempPath);
|
attempted.push_back(tempPath);
|
||||||
attemptedConfigs.push_back("");
|
attemptedConfigs.push_back("");
|
||||||
|
|
||||||
if(ctest->GetConfigType().size())
|
if(ctest->GetConfigType().size())
|
||||||
{
|
{
|
||||||
tempPath = filepath;
|
tempPath = filepath;
|
||||||
|
@ -1425,7 +1425,7 @@ void cmCTestTestHandler
|
||||||
tempPath = filepath;
|
tempPath = filepath;
|
||||||
tempPath += "RelWithDebInfo/";
|
tempPath += "RelWithDebInfo/";
|
||||||
tempPath += filename;
|
tempPath += filename;
|
||||||
attempted.push_back(tempPath);
|
attempted.push_back(tempPath);
|
||||||
attemptedConfigs.push_back("RelWithDebInfo");
|
attemptedConfigs.push_back("RelWithDebInfo");
|
||||||
tempPath = filepath;
|
tempPath = filepath;
|
||||||
tempPath += "Deployment/";
|
tempPath += "Deployment/";
|
||||||
|
@ -1472,8 +1472,8 @@ std::string cmCTestTestHandler
|
||||||
attemptedConfigs,
|
attemptedConfigs,
|
||||||
localfilepath,filename);
|
localfilepath,filename);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// if extraPaths are provided and we were not passed a full path, try them,
|
// if extraPaths are provided and we were not passed a full path, try them,
|
||||||
// try any extra paths
|
// try any extra paths
|
||||||
if (filepath.size() == 0)
|
if (filepath.size() == 0)
|
||||||
|
@ -1489,8 +1489,8 @@ std::string cmCTestTestHandler
|
||||||
filepathExtra,
|
filepathExtra,
|
||||||
filenameExtra);
|
filenameExtra);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// store the final location in fullPath
|
// store the final location in fullPath
|
||||||
std::string fullPath;
|
std::string fullPath;
|
||||||
|
|
||||||
|
@ -1523,7 +1523,7 @@ std::string cmCTestTestHandler
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// if everything else failed, check the users path, but only if a full path
|
// if everything else failed, check the users path, but only if a full path
|
||||||
// wasn't specified
|
// wasn't specified
|
||||||
if (fullPath.size() == 0 && filepath.size() == 0)
|
if (fullPath.size() == 0 && filepath.size() == 0)
|
||||||
|
@ -1547,7 +1547,7 @@ std::string cmCTestTestHandler
|
||||||
i->c_str() << "\n");
|
i->c_str() << "\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return fullPath;
|
return fullPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1589,13 +1589,13 @@ void cmCTestTestHandler::GetListOfTests()
|
||||||
cm.AddCommand(newCom1);
|
cm.AddCommand(newCom1);
|
||||||
|
|
||||||
// Add handler for SUBDIRS
|
// Add handler for SUBDIRS
|
||||||
cmCTestSubdirCommand* newCom2 =
|
cmCTestSubdirCommand* newCom2 =
|
||||||
new cmCTestSubdirCommand;
|
new cmCTestSubdirCommand;
|
||||||
newCom2->TestHandler = this;
|
newCom2->TestHandler = this;
|
||||||
cm.AddCommand(newCom2);
|
cm.AddCommand(newCom2);
|
||||||
|
|
||||||
// Add handler for ADD_SUBDIRECTORY
|
// Add handler for ADD_SUBDIRECTORY
|
||||||
cmCTestAddSubdirectoryCommand* newCom3 =
|
cmCTestAddSubdirectoryCommand* newCom3 =
|
||||||
new cmCTestAddSubdirectoryCommand;
|
new cmCTestAddSubdirectoryCommand;
|
||||||
newCom3->TestHandler = this;
|
newCom3->TestHandler = this;
|
||||||
cm.AddCommand(newCom3);
|
cm.AddCommand(newCom3);
|
||||||
|
@ -2156,7 +2156,7 @@ bool cmCTestTestHandler::SetTestsProperties(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ( key == "ENVIRONMENT" )
|
if ( key == "ENVIRONMENT" )
|
||||||
{
|
{
|
||||||
std::vector<std::string> lval;
|
std::vector<std::string> lval;
|
||||||
cmSystemTools::ExpandListArgument(val.c_str(), lval);
|
cmSystemTools::ExpandListArgument(val.c_str(), lval);
|
||||||
std::vector<std::string>::iterator crit;
|
std::vector<std::string>::iterator crit;
|
||||||
|
@ -2272,7 +2272,7 @@ bool cmCTestTestHandler::AddTest(const std::vector<std::string>& args)
|
||||||
test.Directory = cmSystemTools::GetCurrentWorkingDirectory();
|
test.Directory = cmSystemTools::GetCurrentWorkingDirectory();
|
||||||
cmCTestLog(this->CTest, DEBUG, "Set test directory: "
|
cmCTestLog(this->CTest, DEBUG, "Set test directory: "
|
||||||
<< test.Directory << std::endl);
|
<< test.Directory << std::endl);
|
||||||
|
|
||||||
test.IsInBasedOnREOptions = true;
|
test.IsInBasedOnREOptions = true;
|
||||||
test.WillFail = false;
|
test.WillFail = false;
|
||||||
test.RunSerial = false;
|
test.RunSerial = false;
|
||||||
|
|
|
@ -126,7 +126,7 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
// add configuraitons to a search path for an executable
|
// add configuraitons to a search path for an executable
|
||||||
static void AddConfigurations(cmCTest *ctest,
|
static void AddConfigurations(cmCTest *ctest,
|
||||||
std::vector<std::string> &attempted,
|
std::vector<std::string> &attempted,
|
||||||
std::vector<std::string> &attemptedConfigs,
|
std::vector<std::string> &attemptedConfigs,
|
||||||
std::string filepath,
|
std::string filepath,
|
||||||
|
@ -205,7 +205,7 @@ private:
|
||||||
// compute the lists of tests that will actually run
|
// compute the lists of tests that will actually run
|
||||||
// based on union regex and -I stuff
|
// based on union regex and -I stuff
|
||||||
void ComputeTestList();
|
void ComputeTestList();
|
||||||
|
|
||||||
bool GetValue(const char* tag,
|
bool GetValue(const char* tag,
|
||||||
std::string& value,
|
std::string& value,
|
||||||
std::ifstream& fin);
|
std::ifstream& fin);
|
||||||
|
|
Loading…
Reference in New Issue