Filter { @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + id; return result; } Filter(int id, String name, String product); int getId(); void setId(int id); String getName(); void setName(String name); String getProduct(); void setProduct(String product); @Override int hashCode(); @Override boolean equals(Object obj);  }
@Test public void testHashCode_1() throws Exception { Filter fixture = new Filter(1, "", ""); int result = fixture.hashCode(); }