Migrate Hamcrest JUnit's ExpectedException to AssertJ
MSALHamcrest JUnit's ExpectedException is a copy of JUnit 4's rule that takes Hamcrest matchers. Migrate its uses to AssertJ's assertThatExceptionOfType(..), which also leaves the test independent of the JUnit 4 rule that removing Hamcrest JUnit would take off the classpath.
org. openrewrite. java. testing. hamcrest. MigrateHamcrestJUnitExpectedExceptionToAssertJmod run . --recipe= org. openrewrite. java. testing. hamcrest. MigrateHamcrestJUnitExpectedExceptionToAssertJInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.