Replace PowerMock.mockStatic() with Mockito.mockStatic()
MSALReplaces PowerMockito.mockStatic() by Mockito.mockStatic(), assigning the resulting MockedStatic to a field that is closed after each test, so the static mock stays active for exactly the same part of the test as before. Also migrates PowerMockito.verifyStatic() and static stubbing, and removes the @PrepareForTest annotation.
org. openrewrite. java. testing. mockito. PowerMockitoMockStaticToMockitomod run . --recipe= org. openrewrite. java. testing. mockito. PowerMockitoMockStaticToMockitoInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.