On June 27, 2011, Khai Do wrote: > I would be surprised that removing 'testsuites' would break compatibility > with Jenkins. I have Jenkins running maven (java) projects with lots of > junit tests. When maven executes the tests it generates lots of > individual junit xml reports, none of which contain the 'testsuites' > element. All the individual xml reports get fed to Jenkins and Jenkins > seems to generate its test results page just fine.
What breaks under Hudson/Jenkins, is that if the JUnit XML contains _multiple_ <testsuite> elements, it needs to be nested under a single parent <testsuites> element in order for Hudson/Jenkins to parse it. Failure to wrap it with a <testsuites> element results in an error thrown indicating, "The markup in the document following the root element must be well-formed". If you're using PERL_TEST_HARNESS_DUMP_TAP to create individual JUnit XML files, you'll get one test suite per file. If you're capturing the full output from TAP::Formatter::JUnit, however, you'll get multiple suites in the resulting JUnit XML stream. -- Graham TerMarsch