JUnit 6 migration from JUnit 5.x

MSAL

Migrates JUnit 5.x tests to JUnit 6.x.

org.openrewrite.java.testing.junit6.JUnit5to6Migration
mod run . --recipe=org.openrewrite.java.testing.junit6.JUnit5to6Migration

Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.

Recipe list

It runs these recipes, in this order.

  1. Upgrade to JUnit 5.14
  2. Remove a Gradle or Maven dependency org.junit.platform:junit-platform-jfr
  3. Remove a Gradle or Maven dependency org.junit.platform:junit-platform-runner
  4. Remove a Gradle or Maven dependency org.junit.platform:junit-platform-suite-commons
  5. Remove JUnit Jupiter migrationsupport
  6. Upgrade Gradle or Maven dependency versions org.junit:junit-bom:6.x
  7. Upgrade Gradle or Maven dependency versions org.junit.jupiter:junit-jupiter*:6.x
  8. Upgrade Gradle or Maven dependency versions org.junit.platform:*:6.x
  9. Upgrade Gradle or Maven dependency versions org.junit.vintage:*:6.x
  10. Add Gradle dependency org.junit.platform:junit-platform-launcher:6.x
  11. Upgrade Maven plugin version org.apache.maven.plugins:maven-failsafe-plugin:3.x
  12. Upgrade Maven plugin version org.apache.maven.plugins:maven-surefire-plugin:3.x
  13. Remove annotation attribute @CsvFileSource(lineSeparator)
  14. Migrate JUnit JRE conditions 17
  15. Change method name org.junit.jupiter.api.extension.ExtensionContext.Store getOrComputeIfAbsent(..) to computeIfAbsent
  16. Migrate MethodOrderer.Alphanumeric to MethodOrderer.MethodName
  17. Migrate JUnit Pioneer extensions to native JUnit Jupiter equivalents
  18. Migrate the two-argument InvocationInterceptor.interceptDynamicTest
  19. Change type org.junit.jupiter.engine.Constants to org.junit.jupiter.api.Constants
  20. Change method name org.junit.platform.testkit.engine.Executions started() to finished
  21. Delete property by key junit.jupiter.tempdir.scope
  22. Delete property by key junit.jupiter.params.arguments.conversion.locale.format
  23. Upgrade WireMock to 3.x