@Test public void copesWithNullsAndUnknownTypes() { Matcher<Object> matcher = describedAs("irrelevant", anything()); assertNullSafe(matcher); assertUnknownTypeSafe(matcher); }
public DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values) { this.descriptionTemplate = descriptionTemplate; this.matcher = matcher; this.values = values.clone(); }
DescribedAs extends BaseMatcher<T> { public DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values) { this.descriptionTemplate = descriptionTemplate; this.matcher = matcher; this.values = values.clone(); } }
DescribedAs extends BaseMatcher<T> { public DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values) { this.descriptionTemplate = descriptionTemplate; this.matcher = matcher; this.values = values.clone(); } DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values); }
DescribedAs extends BaseMatcher<T> { public DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values) { this.descriptionTemplate = descriptionTemplate; this.matcher = matcher; this.values = values.clone(); } DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values); @Override boolean matches(Object o); @Override void describeTo(Description description); @Override void describeMismatch(Object item, Description description); static Matcher<T> describedAs(String description, Matcher<T> matcher, Object... values); }
DescribedAs extends BaseMatcher<T> { public DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values) { this.descriptionTemplate = descriptionTemplate; this.matcher = matcher; this.values = values.clone(); } DescribedAs(String descriptionTemplate, Matcher<T> matcher, Object[] values); @Override boolean matches(Object o); @Override void describeTo(Description description); @Override void describeMismatch(Object item, Description description); static Matcher<T> describedAs(String description, Matcher<T> matcher, Object... values);  }