Package org.mockito.internal.listeners
Class VerificationStartedNotifier.Event
java.lang.Object
org.mockito.internal.listeners.VerificationStartedNotifier.Event
- All Implemented Interfaces:
VerificationStartedEvent
- Enclosing class:
- VerificationStartedNotifier
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
originalMockingDetails
-
mock
-
-
Constructor Details
-
Event
-
-
Method Details
-
setMock
Description copied from interface:VerificationStartedEvent
Replaces existing mock object for verification with a different one. Needed for very advanced framework integrations. For all the details, including how and why seeVerificationStartedListener
.If this method is used to replace the mock the sibling method
VerificationStartedEvent.getMock()
will return the new value. CAVEAT: ifsetMock(Object)
is invoked multiple times from one or many listeners the sibling methodVerificationStartedEvent.getMock()
will return mock that was set by most recent invocation ofsetMock(Object)
.- Specified by:
setMock
in interfaceVerificationStartedEvent
- Parameters:
mock
- to be used for verification.
-
getMock
Description copied from interface:VerificationStartedEvent
The mock object that will be used during verification. See sibling methodVerificationStartedEvent.setMock(Object)
for more details. Please seeVerificationStartedListener
for all details of verification started listeners.- Specified by:
getMock
in interfaceVerificationStartedEvent
-