Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How to config the NUnit runner in bamboo to generate TestResult.xml for sonarqube report?

Harry Wang
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 6, 2022

Hi Sir/Madam,

I cannot properly config the NUnit runner in bamboo to generate TestResult.xml and need your help. And then I tend to show the report in Sonarqube side.

Any suggestion/feedback is welcome. Thanks.

  • My configs as below:

ConfigExample.png

 

  • The log as below with error:

... running command line:
D:
unit.consolerunner\3.15.2\tools
unit3-console.exe POS.NET\Base\POS.Classes.Test\bin\Debug
et451\POS.Classes.Test.dll --result=POS.NET\Base\POS.Classes.Test\TestResult.xml;format=nunit2
... in: D:\Atlassian\Application Data\bamboo-home\xml-data\build-dir\POS-VO86-COMPILE
... using extra environment variables:
bamboo_capability_system_builder_nunit3_MS_Build_4_7_1=D:\sonar-scanner-msbuild-4.7.1
bamboo_capability_system_builder_ant_apache_ant_1_9_3=C:\Apache\apache-ant-1.9.3
bamboo_capability_system_builder_ant_apache_ant_1_9_4=D:\apache-ant-1.9.4
bamboo_planRepository_1_branchDisplayName=20220625
bamboo_repository_revision_number=112149
bamboo_build_commandline_com_atlassian_bamboo_plugin_dotnet_msbuild_17=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\MSBuild.exe @D:\Atlassian\Bamboo\temp\POS-VO86-COMPILE-19-MsBuildTaskType-6654598253995590866.rsp

 12:16:04Unknown result format: nunit2
12:16:04Parsing test results under D:\Atlassian\Application Data\bamboo-home\xml-data\build-dir\POS-VO86-COMPILE...
 12:16:04Failing task since test cases were expected but none were found.
 12:16:04Finished task 'NUnit Runner' with result: Failed
 12:16:04Running post build plugin 'NCover Results Collector'
 12:16:04Running post build plugin 'Artifact Copier'
 12:16:04Running post build plugin 'npm Cache Cleanup'
 12:16:04Running post build plugin 'Clover Results Collector'
 12:16:04Running post build plugin 'Docker Container Cleanup'
 12:16:04Finalising the build...

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events