Package | Description |
---|---|
org.mockito |
Mockito is a mock library for java - see
Mockito class for usage. |
org.mockito.internal |
Internal classes, not to be used by clients.
|
org.mockito.internal.progress |
Mocking progress stateful classes.
|
org.mockito.internal.stubbing |
Stubbing logic.
|
org.mockito.stubbing |
Stubbing related classes.
|
Modifier and Type | Field and Description |
---|---|
private OngoingStubbing<T> |
BDDMockito.BDDOngoingStubbingImpl.mockitoOngoingStubbing |
Modifier and Type | Method and Description |
---|---|
static <T> OngoingStubbing<T> |
Mockito.when(T methodCall)
Enables stubbing methods.
|
Constructor and Description |
---|
BDDOngoingStubbingImpl(OngoingStubbing<T> ongoingStubbing) |
Modifier and Type | Method and Description |
---|---|
<T> OngoingStubbing<T> |
MockitoCore.when(T methodCall) |
Modifier and Type | Field and Description |
---|---|
private OngoingStubbing<?> |
MockingProgressImpl.ongoingStubbing |
Modifier and Type | Method and Description |
---|---|
OngoingStubbing<?> |
MockingProgressImpl.pullOngoingStubbing() |
OngoingStubbing<?> |
MockingProgress.pullOngoingStubbing() |
Modifier and Type | Method and Description |
---|---|
void |
MockingProgressImpl.reportOngoingStubbing(OngoingStubbing ongoingStubbing) |
void |
MockingProgress.reportOngoingStubbing(OngoingStubbing<?> ongoingStubbing) |
Modifier and Type | Class and Description |
---|---|
class |
BaseStubbing<T> |
class |
ConsecutiveStubbing<T> |
class |
OngoingStubbingImpl<T> |
Modifier and Type | Method and Description |
---|---|
OngoingStubbing<T> |
BaseStubbing.then(Answer<?> answer) |
OngoingStubbing<T> |
ConsecutiveStubbing.thenAnswer(Answer<?> answer) |
OngoingStubbing<T> |
OngoingStubbingImpl.thenAnswer(Answer<?> answer) |
OngoingStubbing<T> |
BaseStubbing.thenCallRealMethod() |
OngoingStubbing<T> |
BaseStubbing.thenReturn(T value) |
OngoingStubbing<T> |
BaseStubbing.thenReturn(T value,
T... values) |
OngoingStubbing<T> |
BaseStubbing.thenThrow(java.lang.Class<? extends java.lang.Throwable> throwableType) |
OngoingStubbing<T> |
BaseStubbing.thenThrow(java.lang.Class<? extends java.lang.Throwable> toBeThrown,
java.lang.Class<? extends java.lang.Throwable>... nextToBeThrown) |
OngoingStubbing<T> |
BaseStubbing.thenThrow(java.lang.Throwable... throwables) |
private OngoingStubbing<T> |
BaseStubbing.thenThrow(java.lang.Throwable throwable) |
<T> OngoingStubbing<T> |
DefaultLenientStubber.when(T methodCall) |
Modifier and Type | Method and Description |
---|---|
OngoingStubbing<T> |
OngoingStubbing.then(Answer<?> answer)
Sets a generic Answer for the method.
|
OngoingStubbing<T> |
OngoingStubbing.thenAnswer(Answer<?> answer)
Sets a generic Answer for the method.
|
OngoingStubbing<T> |
OngoingStubbing.thenCallRealMethod()
Sets the real implementation to be called when the method is called on a mock object.
|
OngoingStubbing<T> |
OngoingStubbing.thenReturn(T value)
Sets a return value to be returned when the method is called.
|
OngoingStubbing<T> |
OngoingStubbing.thenReturn(T value,
T... values)
Sets consecutive return values to be returned when the method is called.
|
OngoingStubbing<T> |
OngoingStubbing.thenThrow(java.lang.Class<? extends java.lang.Throwable> throwableType)
Sets a Throwable type to be thrown when the method is called.
|
OngoingStubbing<T> |
OngoingStubbing.thenThrow(java.lang.Class<? extends java.lang.Throwable> toBeThrown,
java.lang.Class<? extends java.lang.Throwable>... nextToBeThrown)
Sets Throwable classes to be thrown when the method is called.
|
OngoingStubbing<T> |
OngoingStubbing.thenThrow(java.lang.Throwable... throwables)
Sets Throwable objects to be thrown when the method is called.
|
<T> OngoingStubbing<T> |
LenientStubber.when(T methodCall)
Allows declaring the method to stub.
|