PowerMock
-
Core Java
Mockito vs PowerMock: Which One to Choose for Mocking Static Methods?
When it comes to unit testing in Java, mocking is a crucial aspect of simulating behavior and controlling dependencies. However,…
Read More » -
Core Java
Using PowerMock to Mock Constructors
In my opinion, one of the main benefits of dependency injection is that you can inject mock and/or stub objects…
Read More » -
Enterprise Java
My Testing and Code Analysis Toolbox
Last week we kicked of a “Testing Skill Group” at LINEAS, a group for exchanging knowledge about testing. One question…
Read More » -
Core Java
Mock Static Methods with PowerMock
In a recent blog, I tried to highlight the benefits of using dependency injection and expressing the idea that one…
Read More » -
Core Java
Testing an Object’s Internal State with PowerMock
Most unit testing focuses on testing an object’s behaviour in order to prove that it works. This is achieved by…
Read More »