### Question:
AuthorisationProcessor { public AuthorisationProcessorResponse apply(AuthorisationProcessorRequest request) { AuthorisationProcessorResponse processorResponse = process(request); getProcessorService(request).updateAuthorisation(request, processorResponse); return processorResponse; } AuthorisationProcessor(ApplicationContext applicationContext); void setNext(AuthorisationProcessor nextProcessor); abstract ScaStatus getScaStatus(); AuthorisationProcessorResponse apply(AuthorisationProcessorRequest request);  }### Answer:
@Test void apply_currentProcessor() { request.setScaStatus(ScaStatus.RECEIVED); AuthorisationProcessorResponse processorResponse = new AuthorisationProcessorResponse(); when(applicationContext.getBean(AisAuthorisationProcessorServiceImpl.class)).thenReturn(aisAuthorisationProcessorServiceImpl); when(aisAuthorisationProcessorServiceImpl.doScaReceived(request)).thenReturn(processorResponse); doNothing().when(aisAuthorisationProcessorServiceImpl).updateAuthorisation(request, processorResponse); authorisationProcessor.apply(request); verify(applicationContext, times(2)).getBean(AisAuthorisationProcessorServiceImpl.class); verify(aisAuthorisationProcessorServiceImpl, times(1)).doScaReceived(request); verify(aisAuthorisationProcessorServiceImpl, times(1)).updateAuthorisation(request, processorResponse); }