@Test public void canCompareNullValues() { final Matcher<Object> matcher = equalTo(null); assertMatches(matcher, null); assertDoesNotMatch(matcher, 2); assertDoesNotMatch(matcher, "hi"); assertDoesNotMatch(matcher, new String[] {"a", "b"}); }
public static <T> Matcher<T> equalTo(T operand) { return new IsEqual<>(operand); }
IsEqual extends BaseMatcher<T> { public static <T> Matcher<T> equalTo(T operand) { return new IsEqual<>(operand); } }
IsEqual extends BaseMatcher<T> { public static <T> Matcher<T> equalTo(T operand) { return new IsEqual<>(operand); } IsEqual(T equalArg); }
IsEqual extends BaseMatcher<T> { public static <T> Matcher<T> equalTo(T operand) { return new IsEqual<>(operand); } IsEqual(T equalArg); @Override boolean matches(Object actualValue); @Override void describeTo(Description description); static Matcher<T> equalTo(T operand); static Matcher<Object> equalToObject(Object operand); }
IsEqual extends BaseMatcher<T> { public static <T> Matcher<T> equalTo(T operand) { return new IsEqual<>(operand); } IsEqual(T equalArg); @Override boolean matches(Object actualValue); @Override void describeTo(Description description); static Matcher<T> equalTo(T operand); static Matcher<Object> equalToObject(Object operand);  }