NCover Reporting in Bamboo

So Bamboo Reporting allows me to select NCover reports as a custom report type, but all the documentation says about NCover anywhere is "DO not select this ['NCover Output will be produced'] option" in "Configuring Miscellaneous Settings for a Job". So has anyone out there implemented NCOver with a Bamboo build? Did you do it by adding it as a task in your MSBuild (or NAnt) script? We are movign from CCNet and had CCNet run NCover as a task. I don't see that anyone has done a plugin for NCover for Bamboo yet, so thinking that we will need to run it as the MSBuild task (or find a bunch of extra time to create our own plugin).

3 answers

Hi benrice,

Recently, an NCover customer who was using Bamboo figured out how to display an NCover report by trial-and-error and ingenuity -- as you observed, the Bamboo documentation isn't much help, and NCover doesn't offer a plug-in, so he figured it out on his own.

Based on the steps he described to me, I put together a short knowledge base article that may help you:

Best regards,

NCover Support

I'm not sure what version of Bamboo that user used, but Command is not an option one can select in the Miscellaneous configuration of the job in Bamboo 3.4.1. However, I could point that configuration option to an NCover coverage.xml file. I then created a Command task in the job to be run after my build task. I set NCover.Console to the executable to be run and give it the parameters to run MSTest: "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\MSTest.exe" /testcontainer:.\ProjectTests\bin\debug\ProjectTests.dll // .\coverage\coverage.xml

That works to create my coverage file in the place I specified in the job's miscellaneous configuration. After running the build I can see the results when I go to Project > Plan >Build #> Job in the NCover tab that now appears. However, if I go to Project > Plan > Job (without the specific build) there is also an NCover tab that shows 'Line Rate Coverage' and a broken image, which I assume should be the coverage graph. Also, if I go to Reports and select NCover Code Coverage for the given plan no data is returned.

Same problem here benrice, did you ever end up getting this working?

This is the nant call that I am using:

<ncover program="${tools.NCover.Console.exe}"
testRunnerArgs="${}\${}.sln /xml=${}\unit\${}.xml"

(testRunnerArgs are actually on one line, Atlassian Answers has dropped it over two)

I can see this correctly gives me a coverage xml file at "\testresults\cover\xml\coverage.xml"

I then have the plan configured with "NCover output will be produced" ticked, and the directory as "testresults\cover\xml".

This results in a broken image for Line Rate Coverage for me too.

Understood and thanks for the detailed update.

Regarding the Line Rate Coverage, see the link below for some relevant info:

Maybe Atlassian has modifed this report, as it seems it was of limited usefulness before, but now it seems there may be another problem. I couldn't find details of how this issue was resolved.


I did not get that working. I ended up copying off the NCover reporting html files as artifacts, and the team can view them from there. I didn't work on getting trending to work at all though.


Suggest an answer

Log in or Join to answer
Community showcase
Alexey Matveev
Published Saturday in Jira

How to run Jira in a docker container

Everything below is tested on Ubuntu 17.10. I prefer to use Jira in a docker container because: 1. I can install Jira with a couple of commands. 2. I can start and stop Jira just by starting and s...

229 views 6 8
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot