Status: Resolved (View Workflow)
Resolution: Not A Defect
Jenkins 2.60.3, Windows Server 2016
I upgraded to MSTest 0.20 yesterday and noticed that Emma coverage reports were no longer being copied to the build directory, thus we were no longer seeing coverage data in Jenkins.
Downgrading to MSTest 0.19 resolved the issue for us. This is not a major issue, but we would like to provide coverage data to our users.
nilleb yes, that sounds like what I am seeing.
Console log from last build where coverage report was included in build report (MSTest 0.19):
16:44:24 [MSTEST-PLUGIN] Processing test results in file(s) **/*.trx 16:44:24 MSTest: B:\jenkins\workspace\App\Test\Mgmt\Solution\TestResults\2017-09-13 16_44_21.trx 16:44:25 Emma: looking for coverage reports in the entire workspace: B:\jenkins\workspace\App\Test\Mgmt\Solution 16:44:25 Emma: found 1 report files: 16:44:25 B:\jenkins\workspace\App\Test\Mgmt\Solution\TestResults\emma\coverage.xml 16:44:25 Emma: stored 1 report files in the build folder: C:\Program Files (x86)\Jenkins\jobs\App\jobs\Test\jobs\Mgmt\jobs\Solution\builds\54\emma 16:44:25 Emma: Coverage: Classes 181/539 (34%). Methods 549/1076 (51%). Blocks 3805/5997 (63%). Lines 2851/4016 (71%).
Console log from first build where coverage report was not included in build report (MSTest 0.20):
15:47:31 [MSTEST-PLUGIN] INFO processing test results in file(s) **/*.trx 15:47:31 [MSTEST-PLUGIN] INFO processing report file: B:\jenkins\workspace\App\Test\Mgmt\Solution\TestResults\2017-09-14 15_47_29.trx 15:47:31 [MSTEST-PLUGIN] WARNING Unable to delete the file B:\jenkins\workspace\App\Test\Mgmt\Solution\temporary-junit-reports 15:47:31 [MSTEST-PLUGIN] INFO This file is a reserved temporary file. You can delete it safely. 15:47:31 [MSTEST-PLUGIN] INFO XML coverage: transforming 'B:\jenkins\workspace\App\Test\Mgmt\Solution\TestResults\vstest.coveragexml' to 'B:\jenkins\workspace\App\Test\Mgmt\Solution\TestResults\emma\coverage.xml'
After updating the MSTest plugin to 0.20 and adding a the "Record Emma Coverage Report" post-build action, the coverage report is once again being included in the build report.
I really appreciate your assistance with this!
Perhaps I am wrong, but I think that the file containing the emma coverage report has been produced, but you are not getting the coverage report in the build report. This is by design with mstest-0.20.
Please, I need:
In order to get the emma reports associated to the coverage files produced by the mstest report, you should add the emma plugin to your instance and enable it for your build.
Feel free to contact me by email to provide the requested data and ask for advices.