Search in sources :

Example 1 with MockitoNewInvocationControl

use of org.powermock.api.mockito.internal.invocation.MockitoNewInvocationControl in project powermock by powermock.

the class VerifyNoMoreInteractions method verifyNoMoreInteractions.

private static void verifyNoMoreInteractions(Class<?>... types) {
    for (Class<?> type : types) {
        final MockitoMethodInvocationControl invocationHandler = (MockitoMethodInvocationControl) MockRepository.getStaticMethodInvocationControl(type);
        if (invocationHandler != null) {
            invocationHandler.verifyNoMoreInteractions();
        }
        MockitoNewInvocationControl<?> newInvocationControl = (MockitoNewInvocationControl<?>) MockRepository.getNewInstanceControl(type);
        if (newInvocationControl != null) {
            newInvocationControl.verifyNoMoreInteractions();
        }
    }
}
Also used : MockitoNewInvocationControl(org.powermock.api.mockito.internal.invocation.MockitoNewInvocationControl) MockitoMethodInvocationControl(org.powermock.api.mockito.internal.invocation.MockitoMethodInvocationControl)

Aggregations

MockitoMethodInvocationControl (org.powermock.api.mockito.internal.invocation.MockitoMethodInvocationControl)1 MockitoNewInvocationControl (org.powermock.api.mockito.internal.invocation.MockitoNewInvocationControl)1