Content from 2021

By devin, 17 June, 2021

My team is currently migrating one of our Java codebases from junit 4 to 5, and with it we lost two of our favourite features: mocking static methods with PowerMock, and Theories. I'll leave Theories alone in this post so I can focus on PowerMock.

PowerMock has served us well but has some drawbacks, mainly around its slow performance and arcane errors due to the way PowerMock changes your classloading.