What version of NUnit xml does the NUnit Parser require? I am able to run a custom script, that generates a TestResult.xml file, and the file is located. I can see in the file that most tests passed, none fail, and 2 are skipped. But in Bamboo, wherever the NUnit Parser reports the results, it claims every test has been skipped. My only explanation is that the XML format must not match. I am using NUnit Console v 3.10
Hi @Foong ,
I'm not the original author, but I am experiencing the same "skipped test" behavior. In my case, no, there is no "executed" value (see sample <test-case/>, below):
<test-case name="AMPSExceptionConstructorTest()" fullname="AMPS.Client.Tests.AMPSExceptionTest.AMPSExceptionConstructorTest" methodname="AMPSExceptionConstructorTest" classname="AMPS.Client.Tests.AMPSExceptionTest" result="Passed" duration="0.01" asserts="0" />
In my case, I ran NUnit 3 from a linux job using using the the .Net Core 2.2 framework and using the following package references to test & produce NUnit results files:
<PackageReference Include="nunit" Version="3.10.1" />
<PackageReference Include="NUnit3TestAdapter" Version="3.10.0" />
<PackageReference Include="NunitXml.TestLogger" Version="2.1.36" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.5.0" />
Failed tests show up properly, but any passing tests are instead marked as skipped.
FWIW, it appears that we are using Bamboo v6.2.3, if that factors into NUnit 2 vs 3 format support.
@Brandon Stack I can't speak for the version of NUnit supported by the parser as we use that parser to read XUnit test results. However, if you are getting results displayed it might not be the parsing of the results that is the issue, but the running of the NUnit tests on the Bamboo server. Have you checked the build output while the unit tests are running to see if they are being run or skipped?
This is a snippet example of what I can see in my own logs:
build 02-Apr-2019 14:29:04 Common.Tests Total: 224, Errors: 0, Failed: 0, Skipped: 8, Time: 8.984s
And yes we legitimately have 8 tests that are being skipped at the moment.
I hope that helps.
We did eventually figured this out. The answer was that we needed to use NUNit2 Format. We had tried formatting that way unsuccessfully and after going back over, a team member of mine noticed the example code had a bash control character in it (the ';', must have been meant for Windows). We enclosed it with double quotes:
Now it works and picks up all of the tests. Thank you for the replies!
G’day Community! As we gear up to introduce Bamboo Data Center to the world, we wanted to make sure that we shared a bit more about Bamboo, the product. Our team has put together an overview video ...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events