DeliveryOutcomeHandler implements FormSubmissionHandler { @Override public void handle(FormSubmission submission) { motherService.deliveryOutcome(submission); childService.register(submission); } DeliveryOutcomeHandler(MotherService motherService, ChildService childService); @Override void handle(FormSubmission submission);  }
@Test public void shouldDelegateFormSubmissionHandlingToMotherService() throws Exception { FormSubmission submission = create().withFormName("delivery_outcome").withInstanceId("instance id 1").withVersion("122").build(); handler.handle(submission); verify(motherService).deliveryOutcome(submission); verify(childService).register(submission); }