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

Support for NUnit3 which uses a different XML format by NUnit2

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Major Major
    • xunit-plugin
    • None
    • Jenkins 1.625.3
      xUnit plugin 1.101

      xUnit appears to be incompatible with the test results report generated by NUnit 3. This is a snippet of the log produced when it tries to process the results file:

      10:00:44 [xUnit] [INFO] - Starting to record.
      10:00:44 [xUnit] [INFO] - Processing NUnit-Version N/A (default)
      10:00:45 [xUnit] [INFO] - [NUnit-Version N/A (default)] - 1 test report file(s) were found with the pattern 'UnitTestResults.xml' relative to 'E:\JPPSlave\workspace\Complete.Build.UT.NUnit3' for the testing framework 'NUnit-Version N/A (default)'.
      10:01:02 [xUnit] [ERROR] - The converted file for the result file 'E:\JPPSlave\workspace\Complete.Build.UT.NUnit3\UnitTestResults.xml' (during conversion process for the metric 'NUnit') is not valid. The report file has been skipped.
      10:01:02 [xUnit] [ERROR] - Content is not allowed in prolog.
      10:01:02 [xUnit] [ERROR] - Content is not allowed in prolog.
      10:01:02 [xUnit] [INFO] - Failing BUILD because 'set build failed if errors' option is activated.
      10:01:02 [xUnit] [INFO] - There are errors when processing test results.
      10:01:02 [xUnit] [INFO] - Skipping tests recording.
      10:01:02 [xUnit] [INFO] - Stop build.
      10:01:02 Build step 'Publish xUnit test result report' changed build result to FAILURE

      Initially we had this issue using quite an old version of xUnit (1.60) but the issue still persists after upgrading to the latest version (1.101). This is a blocker for us upgrading our code-base to NUnit 3 because we rely on the xUnit plugin processing our report file in order to pass or fail builds based on unit test success.

      The most recent comment on JENKINS-27043 seems to relate to the same issue but as that bug wasn't reported for the same reason I thought it would be best to create this as a stand-alone issue as it's quite specifically a compatibility problem with NUnit 3.

            nfalco Nikolas Falco
            willapp Will Appleby
            Votes:
            13 Vote for this issue
            Watchers:
            15 Start watching this issue

              Created:
              Updated:
              Resolved: