TFS update 4 (and possibly previous updates) run code coverage works one way and not the other.
I’ve got a couple of unit tests setup and I want TFS build code coverage .
I turned on code coverage as below and got no results with the TFS build.
The following way using the Add/Edit dialog from the ellipsis (…) as below does work.
So editing the build definition in this specific way. Process -> 1.Automated tests –> 1.Test source. Then using the ellipsis (…) pop up the Add/Edit dialog and then under Options dropdown change it from None to Enable Code Coverage.
Now I get code coverage results.
And now I can see code coverage in the reports.