JUnitPerf
JUnitPerf copied to clipboard
Support for Mockito
Hello noconnor,
When JUnitPerfRule is used together with Mockito (annotation @RunWith(MockitoJUnitRunner.class)), the mock objects defined on the test are not used anymore, and real objects are used instead. It's like JUnitPerfRule enforces the usage of real objects.
Could you please add support for Mockito?
e.g.
@RunWith(org.mockito.junit.MockitoJUnitRunner.class) public class TestCase { @Rule public JUnitPerfRule perfTestRule = new JUnitPerfRule();
@InjectMocks
ClassToMock mock;
@Spy
Factory partialMock;
.......
Thanks and best regards, bmiranda