### Question:
GrpcTccClientMessageSender implements TccMessageSender { @Override public AlphaResponse coordinate(CoordinatedEvent coordinatedEvent) { GrpcAck grpcAck = tccBlockingEventService.onTccCoordinated(convertTo(coordinatedEvent)); return new AlphaResponse(grpcAck.getAborted()); } GrpcTccClientMessageSender(ServiceConfig serviceConfig,
      ManagedChannel channel,
      String address,
      TccMessageHandler handler,
      LoadBalanceContext loadContext); @Override void onConnected(); @Override void onDisconnected(); @Override ServerMeta onGetServerMeta(); @Override void close(); @Override String target(); @Override AlphaResponse participationStart(ParticipationStartedEvent participationStartedEvent); @Override AlphaResponse participationEnd(ParticipationEndedEvent participationEndedEvent); @Override AlphaResponse tccTransactionStart(TccStartedEvent tccStartEvent); @Override AlphaResponse tccTransactionStop(TccEndedEvent tccEndEvent); @Override AlphaResponse coordinate(CoordinatedEvent coordinatedEvent);  }### Answer:
@Test public void serviceOnCoordinateTest() { final GrpcTccCoordinatedEvent[] requestCaptor = new GrpcTccCoordinatedEvent[1]; CoordinatedEvent event = new CoordinatedEvent(globalTxId,localTxId, parentTxId, methodName, TransactionStatus.Succeed); TccEventServiceImplBase serviceImpl = new TccEventServiceImplBase() { public void onTccCoordinated(GrpcTccCoordinatedEvent request, io.grpc.stub.StreamObserver<GrpcAck> responseObserver) { requestCaptor[0] = request; responseObserver.onNext(ack); responseObserver.onCompleted(); } }; serviceRegistry.addService(serviceImpl); AlphaResponse response =service.coordinate(event); assertThat(requestCaptor[0].getServiceName(), is(serviceConfig.serviceName())); assertThat(requestCaptor[0].getInstanceId(), is(serviceConfig.instanceId())); assertThat(requestCaptor[0].getGlobalTxId(), is(globalTxId)); assertThat(requestCaptor[0].getLocalTxId(), is(localTxId)); assertThat(requestCaptor[0].getMethodName(), is(methodName)); assertThat(requestCaptor[0].getStatus(), is(TransactionStatus.Succeed.toString())); assertThat(response.aborted(), is(false)); }