Package org.mockito.internal.util
Class MockUtil
java.lang.Object
org.mockito.internal.util.MockUtil
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
areSameMocks
(Object mockA, Object mockB) static void
static <T> MockMaker.ConstructionMockControl
<T> createConstructionMock
(Class<T> type, Function<MockedConstruction.Context, MockCreationSettings<T>> settingsFactory, MockedConstruction.MockInitializer<T> mockInitializer) static <T> T
createMock
(MockCreationSettings<T> settings) static <T> MockMaker.StaticMockControl
<T> createStaticMock
(Class<T> type, MockCreationSettings<T> settings) static InvocationContainerImpl
getInvocationContainer
(Object mock) static MockHandler
<?> getMockHandler
(Object mock) static MockMaker
getMockMaker
(String mockMaker) static MockName
getMockName
(Object mock) static MockCreationSettings
getMockSettings
(Object mock) static boolean
static boolean
static void
maybeRedefineMockName
(Object mock, String newName) static void
static MockMaker.TypeMockability
typeMockabilityOf
(Class<?> type, String mockMaker)
-
Method Details
-
getMockMaker
-
typeMockabilityOf
-
createMock
-
resetMock
-
getMockHandler
-
getInvocationContainer
-
isSpy
-
isMock
-
areSameMocks
-
getMockName
-
maybeRedefineMockName
-
getMockSettings
-
createStaticMock
public static <T> MockMaker.StaticMockControl<T> createStaticMock(Class<T> type, MockCreationSettings<T> settings) -
createConstructionMock
public static <T> MockMaker.ConstructionMockControl<T> createConstructionMock(Class<T> type, Function<MockedConstruction.Context, MockCreationSettings<T>> settingsFactory, MockedConstruction.MockInitializer<T> mockInitializer) -
clearAllCaches
public static void clearAllCaches()
-