JUnit 5 best practices

MSAL

Migrates JUnit 4 tests to JUnit 5, upgrades to JUnit 5.14 and applies the JUnit Jupiter best practices.

org.openrewrite.java.testing.junit5.JUnit5BestPractices
mod run . --recipe=org.openrewrite.java.testing.junit5.JUnit5BestPractices

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. JUnit Jupiter migration from JUnit 4.x
  2. Upgrade to JUnit 5.14
  3. JUnit Jupiter best practices