Uploaded image for project: 'Maven Surefire'
  1. Maven Surefire
  2. SUREFIRE-1098

runOrder=balanced is not working

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.12.2, 2.12.3, 2.12.4, 2.13, 2.14, 2.14.1, 2.15, 2.16, 2.17
    • Fix Version/s: 2.18
    • Component/s: Maven Surefire Plugin
    • Labels:
      None
    • Environment:
      JDK 7 on Linux
      JUnit 4.11

      Description

      It seems that the runOrder parameter with balanced value is not working.
      For example, I created a project with the following setting.

      <plugin>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>2.17</version>
        <configuration>
          <parallel>classes</parallel>
          <runOrder>balanced</runOrder>
          <threadCount>2</threadCount>
          <perCoreThreadCount>false</perCoreThreadCount>
        </configuration>
      </plugin>
      

      Then, execute the following tests.

      TestA: 1 second
      TestB: 2 seconds
      TestC: 3 seconds
      TestD: 4 seconds

      The expected order is the following from the second time.
      Thread 1: TestD → TestA
      Thread 2: TestC → TestB

      However, the actual order is the following.
      Thread 1: TestB → TestD
      Thread 2: TestC → TestA

        Attachments

          Activity

            People

            • Assignee:
              tibordigana Tibor Digana
              Reporter:
              miyajan Miyata Jumpei
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: