Package | Description |
---|---|
org.mockito |
Mockito is a mock library for java - see Mockito class for for usage.
|
org.mockito.configuration |
Mockito configuration utilities
|
org.mockito.internal.configuration |
Mockito configuration
|
org.mockito.internal.stubbing.answers |
Answers for stubbed calls
|
Modifier and Type | Method and Description |
---|---|
static <T> T |
Mockito.mock(java.lang.Class<T> classToMock,
ReturnValues returnValues)
Deprecated.
Please use mock(Foo.class, defaultAnswer);
|
Modifier and Type | Method and Description |
---|---|
ReturnValues |
DefaultMockitoConfiguration.getReturnValues()
Deprecated.
|
ReturnValues |
IMockitoConfiguration.getReturnValues()
Deprecated.
Please use
IMockitoConfiguration.getDefaultAnswer()
Steps: 1. Leave the implementation of getReturnValues() method empty - it's not going to be used anyway. 2. Implement getDefaultAnswer() instead. In rare cases your code might not compile with recent deprecation & changes. Very sorry for inconvenience but it had to be done in order to keep framework consistent.
See javadoc Allows configuring the default return values of unstubbed invocations
See javadoc for |
Modifier and Type | Method and Description |
---|---|
ReturnValues |
GlobalConfiguration.getReturnValues() |
Constructor and Description |
---|
AnswerReturnValuesAdapter(ReturnValues returnValues) |