How to get coverage info of .Net dlls?

How to get coverage info of .Net dlls?

Hi,

I need to get coverage info of .Net dlls such as mscorlib.dll and System.XML.dll. I remove all entries under "<ncover.systemAssemblies>" of the NCover.Console.exe.config file, but I still cannot get the coverage info. For System.XML, I can see an entry, but the entry does not show any coverage info. For classes declared in mscorlib.dll (e.g., System.String), I cannot even see an entry. Can somebody help me out?

Thanks in advance.


RE: How to get coverage info of .Net dlls?

ackel,

What does your console log report? If you like, I can take a look at it for you. Just pass it to me through support@ncover.com. I'm interested to know what system you're running (32- or 64-bit). If you're trying to run 32-bit NCover on a 64-bit system, perhaps you're editing the wrong config file. There's another one for the 32-bit, usually installed at C:\Program Files (x86)\NCover.


RE: How to get coverage info of .Net dlls?

I can see the System item under the Explore view of NCover. However, the Sytem item is gray, and no coverage info is presented. I also try NUnit, but the same result. My console log for MSTest is as follows:

NCover Complete Trial v3.4.12.6869 x86 (Administrator) Copyright (c) 2007 - 2010 Gnoso Inc. ... Command: D:\Program Files\devtools\Microsoft Visual Studio 10.0\Common7\IDE\MSTest.exe Command Args: /noisolation /testcontainer:"G:\tmp1\TranslatedCSharpProject.dll" Working Directory: D:\Program Files\devtools\Microsoft Visual Studio 10.0\Common7\IDE Included Assemblies: mscorlib;TranslatedCSharpProject;System

Program Output Process 'MSTest' [PID 5808] has begun profiling. Microsoft (R) Test Execution Command Line Tool Version 10.0.30319.1 Copyright (c) Microsoft Corporation. All rights reserved.

Loading G:\tmp1\TranslatedCSharpProject.dll... Starting execution...

Summary

Test Run Failed. Passed 1271

Failed 3500

Total 4771 Results file: D:\Program Files\devtools\Microsoft Visual Studio 10.0\Common7\IDE\TestResults\zhonghao_CHINA-595A30F3B 2010-08-07 06_50_04.trx Test Settings: Default Test Settings Process 'MSTest' [PID 5808] has finished profiling.

End Program Output

Execution Time: 37.0938 s Symbol Coverage: 73.20% Branch Coverage: 3.87%

Coverage File: D:\Program Files\devtools\Microsoft Visual Studio 10.0\Common7\IDE\coverage.nccov Trend File: D:\Program Files\devtools\Microsoft Visual Studio 10.0\Common7\IDE\coverage.trend

1 is returning exit code #MSTest.exe Either there was an invalid command line, or some tests failed, or MSTest encountered an unexprected exception.


RE: How to get coverage info of .Net dlls?

Please check your mail box. I send my dll files for you.


RE: How to get coverage info of .Net dlls?

Thanks, ackel! Got it. I'll be reviewing these and getting back with you soon.