Bulk extends AbstractAction<BulkResult> { @Override public int hashCode() { return Objects.hash(super.hashCode(), this.bulkableActions); } protected  Bulk(Builder builder); @Override String getRestMethodName(); @Override String getData(Gson gson); @Override String getPathToResult(); @Override BulkResult createNewElasticSearchResult(String responseBody, int statusCode, String reasonPhrase, Gson gson); @Override boolean equals(Object obj); @Override int hashCode();  }
@Test public void testHashCodeWithUnequalActions() { final String index = "twitter"; final String type = "tweet"; final Object leftPayload = Collections.singletonMap("field", "value"); final Update leftAction = new Update.Builder(leftPayload).build(); final Bulk left = new Bulk.Builder() .addAction(leftAction).defaultIndex(index).defaultType(type) .build(); final Bulk right = new Bulk.Builder() .defaultIndex(index).defaultType(type) .build(); assertNotEquals(left.hashCode(), right.hashCode()); }