CDash now supports lots of files in coverage. So, show all files.

Prior to this commit the mumps coverage only showed files that
had at least one line of coverage. Now 0% covered files are shown
as well.
This commit is contained in:
Bill Hoffman 2012-05-11 15:22:25 -04:00
parent 761d93129f
commit c806b23cfe
4 changed files with 5 additions and 18 deletions

View File

@ -771,6 +771,9 @@ int cmCTestCoverageHandler::HandleMumpsCoverage(
"/gtm_coverage.mcov";
if(cmSystemTools::FileExists(coverageFile.c_str()))
{
cmCTestLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
"Parsing Cache Coverage: " << coverageFile
<< std::endl);
cov.ReadCoverageFile(coverageFile.c_str());
return static_cast<int>(cont->TotalCoverage.size());
}

View File

@ -44,11 +44,10 @@ bool cmParseCacheCoverage::LoadCoverageData(const char* d)
}
}
}
// now remove files wht no actual coverage...
this->RemoveUnCoveredFiles();
return true;
}
// not currently used, but leave it in case we want it in the future
void cmParseCacheCoverage::RemoveUnCoveredFiles()
{
// loop over the coverage data computed and remove all files
@ -195,15 +194,6 @@ bool cmParseCacheCoverage::ReadCMCovFile(const char* file)
{
continue;
}
// routine and filepath should be set at this point.
// see if we have visited this file before, and if not
// call InitializeMumpsFile
if( this->Coverage.TotalCoverage[filepath].size() == 0)
{
// hack, this should be done on every file, but for now
// just do it on the ones that have coverage at all
this->InitializeMumpsFile(filepath);
}
// now we are ready to set the coverage from the line of data
cmCTestCoverageHandlerContainer::SingleFileCoverageVector&
coverageVector = this->Coverage.TotalCoverage[filepath];

View File

@ -103,12 +103,6 @@ bool cmParseGTMCoverage::ReadMCovFile(const char* file)
function,
lineoffset))
{
// hack, this should be done on every file, but for now
// just do it on the ones that have coverage at all
if( this->Coverage.TotalCoverage[filepath].size() == 0)
{
this->InitializeMumpsFile(filepath);
}
cmCTestCoverageHandlerContainer::SingleFileCoverageVector&
coverageVector = this->Coverage.TotalCoverage[filepath];
coverageVector[lineoffset + linenumber] += count;

View File

@ -131,7 +131,7 @@ bool cmParseMumpsCoverage::LoadPackages(const char* d)
this->RoutineToDirectory[name.substr(0, name.size()-2)] = *fileIt;
// initialze each file, this is left out until CDash is fixed
// to handle large numbers of files
// this->InitializeMumpsFile(*fileIt);
this->InitializeMumpsFile(*fileIt);
}
return true;
}