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

config with suiteXmlFile: groups/excludedGroups params are not ignored

    XMLWordPrintableJSON

Details

    Description

      surefire-plugin should ignore groups and excludedGroups parameters as documented here and here:
      This parameter is ignored if the suiteXmlFiles parameter is specified.

      the attached test project defines a TestNG suite and two tests which belong to different groups (group1 and group2)

      mvn test -Dgroups=group1 ==> Tests run: 1; excpected: Tests run: 2

      [INFO] -------------------------------------------------------
      [INFO]  T E S T S
      [INFO] -------------------------------------------------------
      [INFO] Running TestSuite
      [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.534 s -
       in TestSuite
      

      mvn test -DexcludedGroups=group1,group2 ==> Tests run: 0; expected: Tests run: 2

      [INFO] -------------------------------------------------------
      [INFO]  T E S T S
      [INFO] -------------------------------------------------------
      [INFO] Running TestSuite
      [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.505 s -
       in TestSuite
      

      mvn test ==> Tests run: 2

      [INFO] -------------------------------------------------------
      [INFO]  T E S T S
      [INFO] -------------------------------------------------------
      [INFO] Running TestSuite
      [INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.544 s -
       in TestSuite
      

      Attachments

        1. surefire-bug.zip
          2 kB
          Michael Schieder

        Activity

          People

            Unassigned Unassigned
            mschieder Michael Schieder
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: