Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-36182

junit - what is correct for testsuites?

    Details

    • Similar Issues:

      Description

      I have a problem with junit reports. So what is correct for testsuites?

      Okay this works:

       <?xml version="1.0" encoding="utf-8"?>
      <testsuites name="hallo">
      	<testsuite errors="0" failures="0" name="C:/workdir/cmodule2/io_circularbuffer/trunk/build/verify/source/result.testresult" skipped="0" tests="12" time="0">
      		<testcase classname="io_circularbuffer_selftest" name="test_init"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_empty"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_empty_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_normal"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_normal_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_circular"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_circular_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_full"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_full_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_push_pop"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_push_pop_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_index_overflow"/>
      	</testsuite>
      </testsuites>
      

      This works not:

      <?xml version="1.0" encoding="utf-8"?>
      <testsuites errors="0" failures="0" skipped="0" tests="12" time="0.0">
      	<testsuite errors="0" failures="0" name="C:/workdir/cmodule2/io_circularbuffer/trunk/build/verify/source/result.testresult" skipped="0" tests="12" time="0">
      		<testcase classname="io_circularbuffer_selftest" name="test_init"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_empty"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_empty_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_normal"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_normal_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_circular"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_circular_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_full"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_full_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_push_pop"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_push_pop_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_index_overflow"/>
      	</testsuite>
      </testsuites>
      

      Also this does not work:

      <?xml version="1.0" encoding="utf-8"?>
      <testsuites name="My suites" errors="0" failures="0" skipped="0" tests="12" time="0.0">
      	<testsuite errors="0" failures="0" name="C:/workdir/cmodule2/io_circularbuffer/trunk/build/verify/source/result.testresult" skipped="0" tests="12" time="0">
      		<testcase classname="io_circularbuffer_selftest" name="test_init"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_empty"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_empty_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_normal"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_normal_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_circular"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_circular_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_full"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_is_full_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_push_pop"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_push_pop_2"/>
      		<testcase classname="io_circularbuffer_selftest" name="test_index_overflow"/>
      	</testsuite>
      </testsuites>
      

      So what attributes are allowed in the note testsuites?

      xunit plugin with junit only accepts

      <testsuites name="Name"> 
      

      but the junit plugin also accepts

      <testsuites name="Name" errors="0" failures="0" skipped="0" tests="12" time="0.0">
      

      What is correct here?

      thanks

        Attachments

          Activity

            People

            • Assignee:
              nfalco Nikolas Falco
              Reporter:
              mgiaco82 Mathias Giacomuzzi
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: