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

Wrong number of tests

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • junit-plugin
    • None

      Hi guys,

      I discovered a bug in how hudson counts tests executed in a build (In my case this is a maven job but I don't know if the problem is the same for others types of jobs).
      The problem is when in maven we launch in a module several executions of surefire.
      For example I have a first surefire execution, exec1,with 4 tests and a second one, exec2, with 3 tests. In that case hudson will count exec1 results 2 times and will report 4+(4+3)=11 tests instead of 7.
      This occurs with any number of surefire executions > 1. hudson will add for each execution the number of all tests executed and not the number of tests executed in the execution itself.
      You can see the problem here :
      http://builder.exoplatform.org/hudson/job/jcr-1.10.x-ci/org.exoplatform.jcr$exo.jcr.component.core/2377/testReport/
      I have 2 executions (and before I had 5 that's why I didn't understand what happened), exec1=918 tests and exec2=1037 tests thus hudson reports 2873 tests (=918+(918+1037))

            Unassigned Unassigned
            aheritier Arnaud Héritier
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: