Interface VerificationData
-
- All Known Implementing Classes:
VerificationDataImpl
public interface VerificationData
Data needed to perform verification of interactions. This interface is considered public even though it lives in private package. In the next major version of Mockito, this class will be moved to public space.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description java.util.List<Invocation>
getAllInvocations()
All invocations recorded on the mock object that is being verified.MatchableInvocation
getTarget()
The target or wanted invocation.InvocationMatcher
getWanted()
Deprecated.- This internal method leaks internal classInvocationMatcher
.
-
-
-
Method Detail
-
getAllInvocations
java.util.List<Invocation> getAllInvocations()
All invocations recorded on the mock object that is being verified. Does not include invocations recorded on other mock objects.
-
getTarget
MatchableInvocation getTarget()
The target or wanted invocation. Below example illustrates what is the 'target' invocation:
Target invocation can contain argument matchers therefore the returned type ismock.foo(); // <- invocation 1 mock.bar(); // <- invocation 2 verify(mock).bar(); // <- target invocation
MatchableInvocation
and notInvocation
.- Since:
- 2.2.12
-
getWanted
@Deprecated InvocationMatcher getWanted()
Deprecated.- This internal method leaks internal classInvocationMatcher
. Please usegetTarget()
instead. Deprecated since 2.2.12
-
-