Do you know why Bamboo is having trouble parsing these JUnit.xml files?

I'm getting errors in my logs about parsing two junit.xml files.  What's strange is that it doesn't fail the build even though there are failures inside the files.  The files are below.  Any ideas? 


Glen Sonnenbeg

***

Filename: run-PDIMay9.xml

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

<testsuites tests="17" failures="10" errors="0" name="PDIMay9-Traffic Reports">

    <testsuite name="drill-down Traffic Reports" tests="4" failures="3" errors="0">

        <testcase name="exportingRouterToexportingLink" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/drill-down/tmp/exportingRouterToexportingLink-1304964300.res and ../databases/PDIMay9/drill-down/expected/1304964300/exportingRouterToexportingLink.out differ

" type="">

        </testcase>

        <testcase name="linkToflowRecorder" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/drill-down/tmp/linkToflowRecorder-1304964300.res and ../databases/PDIMay9/drill-down/expected/1304964300/linkToflowRecorder.out differ

" type="">

        </testcase>

        <testcase name="exportingRouterToegressPE" status="run" timestamp="1304964300">

        </testcase>

        <testcase name="exportingRouterToflow" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/drill-down/tmp/exportingRouterToflow-1304964300.res and ../databases/PDIMay9/drill-down/expected/1304964300/exportingRouterToflow.out differ

" type="">

        </testcase>

    </testsuite>

    <testsuite name="top-level Traffic Reports" tests="10" failures="5" errors="0">

        <testcase name="exportingLink" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/top-level/tmp/exportingLink-1304964300.res and ../databases/PDIMay9/top-level/expected/1304964300/exportingLink.out differ

" type="">

        </testcase>

        <testcase name="exportingRouter" status="run" timestamp="1304964300">

        </testcase>

        <testcase name="flowRecorder" status="run" timestamp="1304964300">

        </testcase>

        <testcase name="link" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/top-level/tmp/link-1304964300.res and ../databases/PDIMay9/top-level/expected/1304964300/link.out differ

" type="">

        </testcase>

        <testcase name="routerGroupTotal" status="run" timestamp="1304964300">

        </testcase>

        <testcase name="routerTotalTraffic" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/top-level/tmp/routerTotalTraffic-1304964300.res and ../databases/PDIMay9/top-level/expected/1304964300/routerTotalTraffic.out differ

" type="">

        </testcase>

        <testcase name="trafficType" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/top-level/tmp/trafficType-1304964300.res and ../databases/PDIMay9/top-level/expected/1304964300/trafficType.out differ

" type="">

        </testcase>

        <testcase name="tunnel" status="run" timestamp="1304964300">

        </testcase>

        <testcase name="cosGroup" status="run" timestamp="1304964300">

        </testcase>

        <testcase name="egressRouter" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/top-level/tmp/egressRouter-1304964300.res and ../databases/PDIMay9/top-level/expected/1304964300/egressRouter.out differ

" type="">

        </testcase>

    </testsuite>

    <testsuite name="other Traffic Reports" tests="3" failures="2" errors="0">

        <testcase name="exportingRouterToexportingLink" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/other/tmp/exportingRouterToexportingLink-1304964300.res and ../databases/PDIMay9/other/expected/1304964300/exportingRouterToexportingLink.out differ

" type="">

        </testcase>

        <testcase name="exportingRouterToegressPE" status="run" timestamp="1304964300">

        </testcase>

        <testcase name="linkToflowRecorder" status="run" timestamp="1304964300">

            <failure message="Files ../databases/PDIMay9/other/tmp/linkToflowRecorder-1304964300.res and ../databases/PDIMay9/other/expected/1304964300/linkToflowRecorder.out differ

" type="">

        </testcase>

    </testsuite>

</testsuites>

 

 

***

Filename: run-BTIrelandBkup.xml

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

<testsuites tests="14" failures="5" errors="0" name="BTIrelandBkup-Traffic Reports">

    <testsuite name="drill-down Traffic Reports" tests="4" failures="1" errors="0">

        <testcase name="exportingRouterToexportingLink" status="run" timestamp="1411905900">

        </testcase>

        <testcase name="exportingRouterToexportingLinkToflow" status="run" timestamp="1411905900">

            <failure message="Files ../databases/BTIrelandBkup/drill-down/tmp/exportingRouterToexportingLinkToflow-1411905900.res and ../databases/BTIrelandBkup/drill-down/expected/1411905900/exportingRouterToexportingLinkToflow.out differ

" type="">

        </testcase>

        <testcase name="linkToflowRecorder" status="run" timestamp="1411905900">

        </testcase>

        <testcase name="exportingRouterToflow" status="run" timestamp="1411905900">

        </testcase>

    </testsuite>

    <testsuite name="top-level Traffic Reports" tests="8" failures="4" errors="0">

        <testcase name="exportingLink" status="run" timestamp="1411905900">

        </testcase>

        <testcase name="exportingRouter" status="run" timestamp="1411905900">

        </testcase>

        <testcase name="flowRecorder" status="run" timestamp="1411905900">

        </testcase>

        <testcase name="link" status="run" timestamp="1411905900">

            <failure message="Files ../databases/BTIrelandBkup/top-level/tmp/link-1411905900.res and ../databases/BTIrelandBkup/top-level/expected/1411905900/link.out differ

" type="">

        </testcase>

        <testcase name="routerTotalTraffic" status="run" timestamp="1411905900">

            <failure message="Files ../databases/BTIrelandBkup/top-level/tmp/routerTotalTraffic-1411905900.res and ../databases/BTIrelandBkup/top-level/expected/1411905900/routerTotalTraffic.out differ

" type="">

        </testcase>

        <testcase name="trafficType" status="run" timestamp="1411905900">

            <failure message="Files ../databases/BTIrelandBkup/top-level/tmp/trafficType-1411905900.res and ../databases/BTIrelandBkup/top-level/expected/1411905900/trafficType.out differ

" type="">

        </testcase>

        <testcase name="tunnel" status="run" timestamp="1411905900">

        </testcase>

        <testcase name="egressRouter" status="run" timestamp="1411905900">

            <failure message="Files ../databases/BTIrelandBkup/top-level/tmp/egressRouter-1411905900.res and ../databases/BTIrelandBkup/top-level/expected/1411905900/egressRouter.out differ

" type="">

        </testcase>

    </testsuite>

    <testsuite name="other Traffic Reports" tests="2" failures="0" errors="0">

        <testcase name="exportingRouterToexportingLink" status="run" timestamp="1411905900">

        </testcase>

        <testcase name="linkToflowRecorder" status="run" timestamp="1411905900">

        </testcase>

    </testsuite>

</testsuites>

 

 

1 answer

1 votes
Marcin Oles Atlassian Team Nov 13, 2014

It looks like your JUnit report files are not valid XML files. There are "<failure>" tags which aren't closed. Bamboo won't be able to parse them.

In Bamboo you can see this:

Failed to parse test result file "&lt;path-to-xml-file&gt;"

In application logs you can find this:

org.xml.sax.SAXParseException; lineNumber: 7; columnNumber: 11; The element type "failure" must be terminated by the matching end-tag "&lt;/failure&gt;".

I've tested it and if you close all the invalid tags (either way: "<failure></failure>" or "<failure/>"), Bamboo parses those results properly.

Suggest an answer

Log in or Join to answer
Community showcase
Renan Battaglin
Published May 18, 2017 in Bamboo

FAQ: How to Upgrade Bamboo Server

Bamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...

1,077 views 0 5
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