when(listenableActionFutureMocked.actionGet()).thenReturn(bulkResponseMocked);
when(bulkResponseMocked.hasFailures()).thenReturn(true);
Iterator<BulkItemResponse> iteratorMocked = mock(Iterator.class);
when(bulkResponseMocked.iterator()).thenReturn(iteratorMocked);
BulkItemResponse response1 = mock(BulkItemResponse.class);
when(response1.isFailed()).thenReturn(true);
when(iteratorMocked.hasNext()).thenReturn(true, false);
when(iteratorMocked.next()).thenReturn(response1);
// Action
entityDao.executeBulkRequest(bulkRequestBuilderMocked);