Find assertThrows<X> { ... } calls — Kotest migration candidate
ProprietaryJUnit 5's assertThrows<X> { … } and Kotest's shouldThrow<X> { … } have the same shape. Migrating gives access to Kotest's shouldThrowExactly<X> (rejects subclass exceptions) and shouldThrowMessage(text) { … }, which are tighter than JUnit's catch-and-introspect pattern.
org. openrewrite. kotlin. testing. FindAssertThrowsCandidateForKotest$KtRecipemod run . --recipe= 'org. openrewrite. kotlin. testing. FindAssertThrowsCandidateForKotest$KtRecipe'Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.