Migrate JUnit Pioneer extensions to native JUnit Jupiter equivalents
MSALMigrates @DefaultLocale, @DefaultTimeZone, @SetSystemProperty, @ClearSystemProperty, @RestoreSystemProperties (and their @Reads.../@Writes... companions) from JUnit Pioneer to the native equivalents added in JUnit Jupiter 6.1. The junit-pioneer dependency is not removed since other Pioneer features (e.g. @RetryingTest, @CartesianTest) have no Jupiter equivalent.
org. openrewrite. java. testing. junit6. MigrateJUnitPioneerToJupitermod run . --recipe= org. openrewrite. java. testing. junit6. MigrateJUnitPioneerToJupiterInstall 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.
- Change type
org.junitpioneer.jupiter.DefaultLocaletoorg.junit.jupiter.api.util.DefaultLocale - Change type
org.junitpioneer.jupiter.DefaultTimeZonetoorg.junit.jupiter.api.util.DefaultTimeZone - Change type
org.junitpioneer.jupiter.SetSystemPropertytoorg.junit.jupiter.api.util.SetSystemProperty - Change type
org.junitpioneer.jupiter.ClearSystemPropertytoorg.junit.jupiter.api.util.ClearSystemProperty - Change type
org.junitpioneer.jupiter.RestoreSystemPropertiestoorg.junit.jupiter.api.util.RestoreSystemProperties - Change type
org.junitpioneer.jupiter.ReadsSystemPropertytoorg.junit.jupiter.api.util.ReadsSystemProperty - Change type
org.junitpioneer.jupiter.WritesSystemPropertytoorg.junit.jupiter.api.util.WritesSystemProperty - Change type
org.junitpioneer.jupiter.ReadsDefaultLocaletoorg.junit.jupiter.api.util.ReadsDefaultLocale - Change type
org.junitpioneer.jupiter.WritesDefaultLocaletoorg.junit.jupiter.api.util.WritesDefaultLocale - Change type
org.junitpioneer.jupiter.ReadsDefaultTimeZonetoorg.junit.jupiter.api.util.ReadsDefaultTimeZone - Change type
org.junitpioneer.jupiter.WritesDefaultTimeZonetoorg.junit.jupiter.api.util.WritesDefaultTimeZone