Due to some maintenance issues, this service has been switched in read-only mode, you can find more information about the why

and how to migrate your plugin documentation in this blogpost

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Current »

MSTest Coverage

MSTests can compute Code Coverage Statistics, but its only output is in binary form. To be able to generate reports, this binary must be transformed to XML. Thankfully, Microsoft provides an interface to do just so, and someone created a MSBuild task for this : http://code.msdn.microsoft.com/vscoveragetoxmltask

This MSBuild tasks creates a xml report that can now be exploited to create a nice Coverage Report.

In order to avoid writing a new hudson plugin from scratch, a XSL Transformation was devised that transformed MSTest's Coverage report into a Emma Coverage report, so the Emma hudson plug-in can display the reports.

The said XSL in attached to this page.

You have to run the XSLT yourself for now (an MSBuild Exec task can do it, provided you have msxsl at hand) :

<Exec Command="msxsl.exe $(SolutionDir)\$(RunConfig)\In\$(ComputerName)\data.xml $(DevToolsDir)\MSTestCoverageToEmma.xsl -o $(SolutionDir)\coverage.xml" />
  • No labels