Class Description
java.lang.Object
org.mockito.internal.verification.Description
- All Implemented Interfaces:
VerificationMode
Description verification mode wraps an existing verification mode and prepends
a custom message to the assertion error if verification fails.
- Since:
- 2.1.0
-
Constructor Summary
ConstructorsConstructorDescriptionDescription
(VerificationMode verification, String description) Constructs a verification mode which wraps the given verification mode. -
Method Summary
Modifier and TypeMethodDescriptionvoid
verify
(VerificationData data) Performs verification using the wrapped verification mode implementation.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.mockito.verification.VerificationMode
description
-
Constructor Details
-
Description
Constructs a verification mode which wraps the given verification mode.- Parameters:
verification
- The implementation to use for verificationdescription
- The failure message to prepend if verification fails
-
-
Method Details
-
verify
Performs verification using the wrapped verification mode implementation. Prepends the custom failure message if verification fails.- Specified by:
verify
in interfaceVerificationMode
- Parameters:
data
- the data to be verified
-