assertTrue(x instanceof y) to assertInstanceOf(y.class, x)

MSAL

Migrate JUnit 4 (or JUnit 5) assertions in the form of assertTrue(x instanceof y) to assertInstanceOf(y.class, x).

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

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