### Question:
SwitchValidateServiceImpl implements SwitchValidateService { @Override public void handleSwitchValidateRequest(String key, SwitchValidateRequest request) { SwitchValidateFsm fsm = builder.newStateMachine( SwitchValidateState.START, carrier, key, request, validationService, repositoryFactory); fsms.put(key, fsm); fsm.start(); handle(fsm, SwitchValidateEvent.NEXT, SwitchValidateContext.builder().build()); } SwitchValidateServiceImpl(
            SwitchManagerCarrier carrier, PersistenceManager persistenceManager, ValidationService validationService); @Override void handleSwitchValidateRequest(String key, SwitchValidateRequest request); @Override void handleFlowEntriesResponse(String key, SwitchFlowEntries data); @Override void handleGroupEntriesResponse(String key, SwitchGroupEntries data); @Override void handleExpectedDefaultFlowEntriesResponse(String key, SwitchExpectedDefaultFlowEntries data); @Override void handleExpectedDefaultMeterEntriesResponse(String key, SwitchExpectedDefaultMeterEntries data); @Override void handleMeterEntriesResponse(String key, SwitchMeterEntries data); @Override void handleMetersUnsupportedResponse(String key); @Override void handleTaskError(String key, ErrorMessage message); @Override void handleTaskTimeout(String key);  }### Answer:
@Test public void errorResponseOnSwitchNotFound() { request = SwitchValidateRequest .builder().switchId(SWITCH_ID_MISSING).performSync(true).processMeters(true).build(); service.handleSwitchValidateRequest(KEY, request); verify(carrier).cancelTimeoutCallback(eq(KEY)); verify(carrier).errorResponse( eq(KEY), eq(ErrorType.NOT_FOUND), eq(String.format("Switch '%s' not found", request.getSwitchId()))); verifyNoMoreInteractions(carrier); verifyNoMoreInteractions(validationService); }