Package org.assertj.core.error
Class ShouldMatch
- java.lang.Object
-
- org.assertj.core.error.BasicErrorMessageFactory
-
- org.assertj.core.error.ShouldMatch
-
- All Implemented Interfaces:
ErrorMessageFactory
public class ShouldMatch extends BasicErrorMessageFactory
Creates an error message indicating that an assertion that verifies that a value satisfies a
failed.Predicate
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ADVICE
-
Fields inherited from class org.assertj.core.error.BasicErrorMessageFactory
arguments, format, formatter
-
-
Constructor Summary
Constructors Modifier Constructor Description private
ShouldMatch(java.lang.Object actual, java.util.function.Predicate<?> predicate, PredicateDescription description)
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> ErrorMessageFactory
shouldMatch(T actual, java.util.function.Predicate<? super T> predicate, PredicateDescription predicateDescription)
Creates a newShouldMatch
.-
Methods inherited from class org.assertj.core.error.BasicErrorMessageFactory
create, create, create, equals, hashCode, toString, unquotedString
-
-
-
-
Constructor Detail
-
ShouldMatch
private ShouldMatch(java.lang.Object actual, java.util.function.Predicate<?> predicate, PredicateDescription description)
-
-
Method Detail
-
shouldMatch
public static <T> ErrorMessageFactory shouldMatch(T actual, java.util.function.Predicate<? super T> predicate, PredicateDescription predicateDescription)
Creates a newShouldMatch
.- Type Parameters:
T
- guarantees that the type of the actual value and the generic type of thePredicate
are the same.- Parameters:
actual
- the actual value in the failed assertion.predicate
- thePredicate
.predicateDescription
- predicate description to include in the error message- Returns:
- the created
ErrorMessageFactory
.
-
-