AbstractFilterResult implements FilterResult { @Override public int hashCode() { int hash = 7; hash = 59 * hash + Objects.hashCode(this.filterType); hash = 59 * hash + Objects.hashCode(this.status); return hash; } 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 testHashCode() { FilterResult instance = new FailFilterResult(FilterType.INTERVAL_FILTER); FilterResult another = new FailFilterResult(FilterType.INTERVAL_FILTER); int expResult = another.hashCode(); int result = instance.hashCode(); assertThat(result, equalTo(expResult)); }