### Question:
IndexingJobStepExecutionListener implements StepExecutionListener { @Override public void beforeStep(StepExecution stepExecution) { try { log.info("Deleting judgments from index without corresponding judgment in database"); judgmentIndexDeleter.deleteFromIndexWithoutCorrespondingJudgmentInDb(); } catch (SolrServerException | IOException e) { throw new RuntimeException(e); } }  @Override void beforeStep(StepExecution stepExecution); @Override ExitStatus afterStep(StepExecution stepExecution); @Autowired void setJudgmentIndexDeleter(JudgmentIndexDeleter judgmentIndexDeleter);  }### Answer:
@Test public void beforeStep() throws SolrServerException, IOException { indexingJobStepExecutionListener.beforeStep(stepExecution); verify(judgmentIndexDeleter).deleteFromIndexWithoutCorrespondingJudgmentInDb(); }