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

Junit XML Parser of bamboo does not separate test cases by their test suites

Kashyap November 5, 2014

Junit XML Parser of bamboo does not separate test cases by their test suites while displaying test results on bamboo. Basically all test cases found under XML files are either go to failed test OR successful tests but there is not further categorization by test suites under those two categories. XML results file does have testsuite information why bamboo does not group test cases by test suites. Does anyone have any example XML file which does that. My xml file looks like following which has 2 test passed tests in 2 different test suites.

 

<?xml version="1.0" encoding="UTF-8"?>

<testsuites>

<testsuite hostname="cp-cip3" timestamp="Thu Oct 30 20:42:59 EDT 2014" package="com.olf.cxplugins.test.trayport" time="2000" ignored="0" failures="0" successful="1" tests="1" name="TrayPortSuite2">

<testcase time="32.735" name="tpCommPhysGasNBPPrompt" classname="com.olf.cxplugins.test.trayport.TPCommPhysGasNBPPrompt">

</testcase>

</testsuite>

 <testsuite hostname="cp-cip3" timestamp="Thu Oct 30 20:42:59 EDT 2014" package="com.olf.cxplugins.test.trayport.test" time="2000" ignored="0" failures="0" successful="1" tests="1" name="TrayportSuite">

<testcase time="135.782" name="tpDeleteDeals" classname="com.olf.cxplugins.test.trayport.test.TPDeleteDeals">

</testcase>

</testsuite>

 </testsuites>

<?xml

2 answers

0 votes
Krystian Brazulewicz
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 12, 2014

Yeah, we're flattening the structure. I think it would only matter to distinguish between testsuites if you were running the same tests in each of them but testsuite would provide different runtime conditions/input values.

Is this your case?

Christian Auby July 26, 2015

We use test suites to organize tests by category, GUI, DataLayer and so on. Once you go above 100 tests the test page gets quite unwieldy. It would be great if the test page in Bamboo grouped tests by the test suites and showed the number of passed / failed / total tests per suite.

0 votes
pradhyumna shrestha November 5, 2014

You are right .. the bamboo xslt transform template ignores the testsuites. 

 

this is what bamboo thoughts the xml is and transforms that accordingly. ignoring multiple testsuite to group test case as if there were just one testsuite.

<testsuite>

<testcase>

</testcase>

</testsuite>

 

If you want to generate different report than t he one junit task generates in bamboo you might have to write your own plugin. 

or you can generate a report using own xslt transformation but bamboo won't be maintaining that as the test cases but you will have a artifact report that has better details. 

 

If you want to try custom report: use the following

http://sourceforge.net/p/junitstylexmltestviewer/code/ci/master/tree/

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events