public class VerificationDataImpl extends Object implements VerificationData
Constructor and Description |
---|
VerificationDataImpl(InvocationContainerImpl invocations,
InvocationMatcher wanted) |
Modifier and Type | Method and Description |
---|---|
List<Invocation> |
getAllInvocations()
All invocations recorded on the mock object that is being verified.
|
MatchableInvocation |
getTarget()
The target or wanted invocation.
|
InvocationMatcher |
getWanted() |
public VerificationDataImpl(InvocationContainerImpl invocations, InvocationMatcher wanted)
public List<Invocation> getAllInvocations()
VerificationData
getAllInvocations
in interface VerificationData
public MatchableInvocation getTarget()
VerificationData
mock.foo(); // <- invocation 1
mock.bar(); // <- invocation 2
verify(mock).bar(); // <- target invocation
Target invocation can contain argument matchers therefore the returned type is MatchableInvocation
and not Invocation
.getTarget
in interface VerificationData
public InvocationMatcher getWanted()
getWanted
in interface VerificationData
Copyright © 2018. All rights reserved.