### Question:
ChargingStationOcpp12SoapClient implements ChargingStationOcpp12Client { @Override public boolean startTransaction(ChargingStationId id, IdentifyingToken identifyingToken, EvseId evseId) { LOG.info("Requesting remote start transaction on {}", id); ChargePointService chargePointService = this.createChargingStationService(id); RemoteStartTransactionRequest request = new RemoteStartTransactionRequest(); request.setIdTag(identifyingToken.getToken()); request.setConnectorId(evseId.getNumberedId()); RemoteStartTransactionResponse response = chargePointService.remoteStartTransaction(request, id.getId()); boolean willTransactionStart; switch (response.getStatus()) { case ACCEPTED: LOG.info("Remote start transaction request on {} has been accepted", id); willTransactionStart = true; break; case REJECTED: LOG.info("Remote start transaction request on {} has been rejected", id); willTransactionStart = false; break; default: throw new AssertionError("Start transaction returned unknown response status " + response.getStatus()); } return willTransactionStart; }  @Override boolean startTransaction(ChargingStationId id, IdentifyingToken identifyingToken, EvseId evseId); @Override boolean stopTransaction(ChargingStationId id, int transactionId); @Override boolean softReset(ChargingStationId id); @Override boolean hardReset(ChargingStationId id); @Override RequestResult unlockConnector(ChargingStationId id, EvseId evseId); @Override RequestResult changeAvailabilityToInoperative(ChargingStationId id, EvseId evseId); @Override RequestResult changeAvailabilityToOperative(ChargingStationId id, EvseId evseId); @Override boolean changeConfiguration(ChargingStationId id, ConfigurationItem configurationItem); @Override String getDiagnostics(ChargingStationId id, DiagnosticsUploadSettings diagnosticsUploadSettings); @Override boolean clearCache(ChargingStationId id); @Override void updateFirmware(ChargingStationId id, String downloadLocation, Date retrieveDate, Integer numRetries, Integer retryInterval); void setDomainService(DomainService domainService); void setChargingStationProxyFactory(ChargingStationProxyFactory chargingStationProxyFactory);  }### Answer:
@Test public void startTransactionAcceptedVerifyReturnValue() { when(chargePointService.remoteStartTransaction(any(RemoteStartTransactionRequest.class), anyString())).thenReturn(getRemoteStartTransactionResponse(RemoteStartStopStatus.ACCEPTED)); boolean willTransactionStart = client.startTransaction(CHARGING_STATION_ID, IDENTIFYING_TOKEN, EVSE_ID); assertTrue(willTransactionStart); }
@Test public void startTransactionRejectedVerifyReturnValue() { when(chargePointService.remoteStartTransaction(any(RemoteStartTransactionRequest.class), anyString())).thenReturn(getRemoteStartTransactionResponse(RemoteStartStopStatus.REJECTED)); boolean willTransactionStart = client.startTransaction(CHARGING_STATION_ID, IDENTIFYING_TOKEN, EVSE_ID); assertFalse(willTransactionStart); }
@Test public void startTransactionVerifyServiceCall() { when(chargePointService.remoteStartTransaction(any(RemoteStartTransactionRequest.class), anyString())).thenReturn(getRemoteStartTransactionResponse(RemoteStartStopStatus.ACCEPTED)); ArgumentCaptor<RemoteStartTransactionRequest> remoteStartTransactionRequestArgument = ArgumentCaptor.forClass(RemoteStartTransactionRequest.class); client.startTransaction(CHARGING_STATION_ID, IDENTIFYING_TOKEN, EVSE_ID); verify(chargePointService).remoteStartTransaction(remoteStartTransactionRequestArgument.capture(), eq(CHARGING_STATION_ID.getId())); assertEquals(IDENTIFYING_TOKEN.getToken(), remoteStartTransactionRequestArgument.getValue().getIdTag()); assertEquals(Integer.valueOf(EVSE_ID.getId()), remoteStartTransactionRequestArgument.getValue().getConnectorId()); }