KAFKA-12947: Replace EasyMock and PowerMock with Mockito for StreamsMetricsImplTest
Based on the Replace EasyMock and PowerMock with Mockito Jira ticket:
Development of EasyMock and PowerMock has stagnated while Mockito continues to be actively developed. With the new Java cadence, it's a problem to depend on libraries that do bytecode generation and are not actively maintained. In addition, Mockito is also easier to use.
Since the original PR #10881 (KAFKA-12947 Replace EasyMock and PowerMock with Mockito for Streams…) author is no longer accessible, this PR is created to fix what was started more than a year ago.
Each test change has a separate commit (which can make it a little bit easier to review).
Committer Checklist (excluded from commit message)
- [ ] Verify design and implementation
- [ ] Verify test coverage and CI build status
- [ ] Verify documentation (including upgrade notes)
@ableegoldman, @cadonna could you please help review this changes in the streams test domain?
@cadonna, @clolov can you please help me get this PR merged (if/when you have time, ofc)?
Hello @dplavcic and @cadonna, how is this pull request fairing? Is there something outstanding as a review or comments to be addressed?
Hello @dplavcic and @cadonna, how is this pull request fairing? Is there something outstanding as a review or comments to be addressed?
@clolov , I will work on this during the next two weeks. Apologies for a delayed response.
@dplavcic It would be nice to get this over the line. Are you still willing to work on this?
It's also worth mentioning that this is the last remaining Streams test that uses PowerMock.
@ijuma , @clolov fixed this in the https://github.com/apache/kafka/pull/14623 . Tnx @clolov 🙌