public interface MockCreationSettings<T>
MockSettings.| Modifier and Type | Method and Description |
|---|---|
Answer |
getDefaultAnswer()
the default answer for this mock, see
MockSettings.defaultAnswer(org.mockito.stubbing.Answer). |
java.util.Set<java.lang.Class> |
getExtraInterfaces()
the extra interfaces the mock object should implement.
|
java.util.List<InvocationListener> |
getInvocationListeners()
The invocation listeners attached to this mock, see
MockSettings.invocationListeners(org.mockito.listeners.InvocationListener...). |
MockName |
getMockName()
the name of this mock, as printed on verification errors; see
MockSettings.name(java.lang.String). |
java.lang.Object |
getOuterClassInstance()
Used when mocking non-static inner classes in conjunction with
isUsingConstructor() |
SerializableMode |
getSerializableMode() |
java.lang.Object |
getSpiedInstance()
the spied instance - needed for spies.
|
java.lang.Class<T> |
getTypeToMock()
Mocked type.
|
boolean |
isSerializable()
if the mock is serializable, see
MockSettings.serializable(). |
boolean |
isStubOnly()
Whether the mock is only for stubbing, i.e.
|
boolean |
isUsingConstructor()
Informs whether the mock instance should be created via constructor
|
java.lang.Class<T> getTypeToMock()
java.util.Set<java.lang.Class> getExtraInterfaces()
MockName getMockName()
MockSettings.name(java.lang.String).Answer getDefaultAnswer()
MockSettings.defaultAnswer(org.mockito.stubbing.Answer).java.lang.Object getSpiedInstance()
boolean isSerializable()
MockSettings.serializable().SerializableMode getSerializableMode()
boolean isStubOnly()
java.util.List<InvocationListener> getInvocationListeners()
MockSettings.invocationListeners(org.mockito.listeners.InvocationListener...).@Incubating boolean isUsingConstructor()
@Incubating java.lang.Object getOuterClassInstance()
isUsingConstructor()