FPChangeHandler implements FormSubmissionHandler { @Override public void handle(FormSubmission submission) { ecService.reportFPChange(submission); } @Autowired  FPChangeHandler(ECService ecService); @Override void handle(FormSubmission submission);  }
@Test public void shouldDelegateFormSubmissionHandlingToECService() throws Exception { FormSubmission submission = new FormSubmission("anm id 1", "instance id 1", "postpartum_family_planning", "entity id 1", 0L, "1", null, 0L); handler.handle(submission); verify(ecService).reportFPChange(submission); }