This project has moved. For the latest updates, please go here.

Hide none covered assemblies

Mar 31, 2012 at 12:23 PM

Hi,

I use ReportGenerator with opencover and mstest with the command line :

OpenCover.Console.exe -target:"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\MSTest.exe"  -targetargs:"/nologo /usestderr /testSettings:\"%WORKSPACE%\Local.testsettings\" /resultsfile:MSTestResults.trx  /testcontainer:\"%WORKSPACE%\Test.MonProjet.Assembly1\bin\Debug\Test.MonProjet.Assembly1.dll\" /testcontainer:\"%WORKSPACE%\Test.MonProjet.Assembly2\bin\Debug\Test.MonProjet.Assembly2.dll\"" -mergebyhash -filter:"+[MonProjet.*]*" -output:"coverage_report.xml"
reportgenerator coverage_report.xml coverage_report

But when I look the report generated by ReportGenerator, lots (!) of assemblies (from the .Net framework and my unit test assemblies) which are not covered are displayed (with the cover value 0%). Part of the list :

MSTest.exe, QTAgent32.exe, Microsoft.VisualStudio.QualityTools.AgentObject.dll, System.Xml.dll, System.dll, ...

and my unit test assemblies (which I have not included in the coverage using the -filter parameter) :

Test.MonProjet.Assembly1.dll, Test.MonProjet.Assembly2.dll

Is there a way to hide theses lines? They are not wanted!

I don't think it's the problem of opencover because the cover report seems ok. All the modules are "skipped due to filter".

An part of the cover report :

    <Module skippedDueTo="Filter" hash="50-32-F6-CF-63-6F-60-E9-50-47-20-32-39-1D-A0-04-E2-51-E0-19">
      <FullName>C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\QTAgent32.exe</FullName>
      <ModuleName>QTAgent32</ModuleName>
      <Classes />
    </Module>

Thanks in advance for the answer!

MSTest.exe 0%
 
Microsoft.TeamFoundation.TestManagement.Controller.dll 0%
 
Microsoft.VisualStudio.Enterprise.AspNetHelper.dll 0%
 
Microsoft.VisualStudio.TeamSystem.Licensing.dll 0%
 
QTAgent32.exe 0%
 
Microsoft.VisualStudio.QualityTools.AgentObject.dll 0%
 
Microsoft.VisualStudio.QualityTools.AgentProcessManager.dll 0%
 
Microsoft.VisualStudio.QualityTools.Common.dll 0%
 
Microsoft.VisualStudio.QualityTools.ControllerObject.dll 0%
 
Microsoft.VisualStudio.QualityTools.ExecutionCommon.dll 0%
 
Microsoft.VisualStudio.QualityTools.Resource.resources.dll 0%
 
Microsoft.VisualStudio.QualityTools.Resource.dll 0%
 
Microsoft.VisualStudio.QualityTools.Tips.UnitTest.AssemblyResolver.dll 0%
 
Microsoft.VisualStudio.QualityTools.TMI.dll 0%
 
mscorlib.dll 0%
 
System.Data.dll 0%
 
System.Web.dll 0%
 
Microsoft.VisualStudio.QualityTools.CommandLine.dll 0%
 
Microsoft.VisualStudio.QualityTools.Tips.UnitTest.Adapter.dll 0%
 
Microsoft.VisualStudio.QualityTools.Tips.UnitTest.ObjectModel.dll 0%
 
Microsoft.VisualStudio.QualityTools.Tips.UnitTest.Tip.dll 0%
 
Microsoft.VisualStudio.QualityTools.UnitTestFramework.resources.dll 0%
 
Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll 0%
 
mscorlib.resources.dll 0%
 
System.Configuration.dll 0%
 
System.Core.dll 0%
 
System.Numerics.dll 0%
 
System.resources.dll 0%
 
System.Runtime.Remoting.dll 0%
 
System.Xml.dll 0%
 
System.dll
Coordinator
Mar 31, 2012 at 9:56 PM
Edited Mar 31, 2012 at 9:57 PM

Could you please provide me your opencover report? That makes it easier for me to take a look at the problem.

Just upload it somewhere and let me know the link or open an issue and attach the report.

Thanks

Apr 1, 2012 at 2:46 PM

No problem!

Here is a link to the file : http://dl.dropbox.com/u/6554477/ReportGenerator/coverage_report.xml

Thanks for your promptness!

Coordinator
Apr 1, 2012 at 5:14 PM

When I run ReportGenerator (Version: 1.2.7.0) the following assemblies/classes are included in the report:

  • MonProjet.Assembly1Details  
  • MonProjet.Assembly1.Class1   
  • MonProjet.Assembly2
  • MonProjet.Assembly2.Classs2

All other assemblies/classes are excluded, since an attribute skippedDueTo="Filter" is applied to the modules.

Do you get the same result with your sample report?

What would you expect?

So far I'm not able so see an error. 

Apr 1, 2012 at 6:44 PM

Hi,

I was using an older version 1.2.1.0 and I just upgraded to the last one and there is no problem at all (just the good assemblies are displayed).

I have the results I expected.

I'm very sorry for the time spent on this problem...

Thank you very much!!!