Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

See also: adaptTo Talk 2018: JUnit 5 and Sling/AEM Mocks

Solution

Surefire Version

  • Make sure to use the latest Version of the Maven Surefire Plugin

Dependencies in POM

Remove existing dependencies to JUnit 4 from your POMs:

...

Code Block
xml
xml
    <dependencyManagement>
      <dependency>
        <groupId>org.junit</groupId>
        <artifactId>junit-bom</artifactId>
        <version>5.3.0<1</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencyManagement>

...