AbstractFilterResult implements FilterResult { @Override public String toString() { return String.format(Locale.UK, "Filter=%s status=%s",filterType, status); } AbstractFilterResult(FilterType filterType, Status status); @Override FilterType getFilterType(); @Override boolean passed(); @Override boolean failed(); @Override boolean wasRun(); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString();  }
@Test public void testToString() { AbstractFilterResult instance = new PassFilterResult(FilterType.INTERVAL_FILTER); String expResult = "Filter=Interval status=PASS"; String result = instance.toString(); assertThat(result, equalTo(expResult)); }