Package org.opensearch.test.hamcrest
Class TupleMatchers
java.lang.Object
org.opensearch.test.hamcrest.TupleMatchers
public class TupleMatchers
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description TupleMatchers() -
Method Summary
Modifier and Type Method Description static <V1, V2> org.opensearch.test.hamcrest.TupleMatchers.TupleMatcher<? extends V1,? extends V2>isTuple(org.hamcrest.Matcher<? super V1> v1Matcher, org.hamcrest.Matcher<? super V2> v2Matcher)Creates a matcher that matches iff: 1.
-
Constructor Details
-
TupleMatchers
public TupleMatchers()
-
-
Method Details
-
isTuple
public static <V1, V2> org.opensearch.test.hamcrest.TupleMatchers.TupleMatcher<? extends V1,? extends V2> isTuple(org.hamcrest.Matcher<? super V1> v1Matcher, org.hamcrest.Matcher<? super V2> v2Matcher)Creates a matcher that matches iff: 1. the examined tuple'sv1()matches the specifiedv1Matcherand 2. the examined tuple'sv2()matches the specifiedv2MatcherFor example:assertThat(Tuple.tuple("myValue1", "myValue2"), isTuple(startsWith("my"), containsString("Val")))
-