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

dependenciesToScan Does Not Leverage Classpath Elements

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.20
    • 2.22.0
    • Maven Surefire Plugin
    • None

    Description

      The <dependenciesToScan> configuration attribute relies solely on installed artifacts. This is an issue when the targeted dependencies were built as part of the current session. The net result is that stale artifacts are used (i.e. if the dependency has changed since it was last installed) or the tests are not executed at all (if the dependency has not been previously installed.

      Attached is a sample project that illustrates this issue:

      Given I have a multi-module project
      And the first module built includes test classes as part of the project artifact
      And subsequent modules scan the first for unit tests to execute
      When I execute the test goal (prior to any install)
      Then the build should succeed
      And tests should be executed with each module

      Attachments

        1. scanned-dependencies-sample.zip
          14 kB
          Owen Farrell

        Activity

          People

            tibordigana Tibor Digana
            owen.farrell Owen Farrell
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Time Spent - 48h 20m Remaining Estimate - 23h 40m
                23h 40m
                Logged:
                Time Spent - 48h 20m Remaining Estimate - 23h 40m
                48h 20m