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

maven-plugin insists on Surefire to run tests

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • maven-plugin
    • None

      The current implementation of Hudson's Maven support needlessly requires the use of maven-surefire-plugin for executing tests. If an alternative test runner plugin is used, Hudson's maven-plugin will not recognize test results, meaning that UNSTABLE builds are wrongly considered to be FAILED builds, and also that build status does not include test result reports.

      This behavior is due to the fact that the SurefireArchiver class includes conditional logic that insists that the test runner plugin is Surefire. If this conditional check is removed, then test results are correctly found and interpreted, and unstable builds are no longer considered failed builds.

      I've attached a simple patch that demonstrates this. Even though the contents of the patch may not be the correct fix, it at least illustrates the nature of the problem.

        1. maven-plugin-kutzi.hpi
          8.82 MB
          Alexander Bertram
        2. SurfireArchiver.patch
          0.7 kB
          jvoegele

            kutzi kutzi
            jvoegele jvoegele
            Votes:
            2 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: