Open anand188 opened 2 months ago
Hi @anand188 ; There's been a recent fix to the Powermock migration recipe in:
Would you mind trying again with the latest version? https://github.com/openrewrite/rewrite-testing-frameworks/releases/tag/v2.17.1
Beyond that your question lacks the details we need to replicate the issue; if the problems persist with the latest version I suggest you create a minimal reproducer.
@timtebeek tried 2.17.1 also doesn't seem to address the issue same not completing migrating.
PowerMockito.doThrow(new IllegalArgumentException()).when( xx.class,"abc",any())
these are still not migrated because when
in Mockito only takes single argument unlike PowerMockito
Ah yes that form is not yet support; that makes this sounds more like a feature request to expand coverage of our Powermock migration recipe. Would you be willing to help out with it's implementation?
The first step would be a draft pull request that adds your case to this unit test; we can collaborate from there: https://github.com/openrewrite/rewrite-testing-frameworks/blob/e9497f1a56e075d5359a10b6356d580dc0ac5874/src/test/java/org/openrewrite/java/testing/mockito/ReplacePowerMockitoIntegrationTest.java#L620-L661
@timtebeek thanks let me see if its possible for me to learn and update this
I am using
Is your project a single module or a multi-module project? Yes
Can you share your configuration so that we can rule out any configuration issues?
Is your project public? If so, can you share a link to it? no