BeamFnDataGrpcMultiplexer implements AutoCloseable { public StreamObserver<BeamFnApi.Elements> getOutboundObserver() { return outboundObserver; } BeamFnDataGrpcMultiplexer(
      Endpoints.@Nullable ApiServiceDescriptor apiServiceDescriptor,
      OutboundObserverFactory outboundObserverFactory,
      OutboundObserverFactory.BasicFactory<Elements, Elements> baseOutboundObserverFactory); @Override String toString(); StreamObserver<BeamFnApi.Elements> getInboundObserver(); StreamObserver<BeamFnApi.Elements> getOutboundObserver(); void registerConsumer(
      LogicalEndpoint inputLocation, BiConsumer<ByteString, Boolean> bytesReceiver); @Override void close();  }
@Test public void testOutboundObserver() { final Collection<BeamFnApi.Elements> values = new ArrayList<>(); BeamFnDataGrpcMultiplexer multiplexer = new BeamFnDataGrpcMultiplexer( DESCRIPTOR, OutboundObserverFactory.clientDirect(), inboundObserver -> TestStreams.withOnNext(values::add).build()); multiplexer.getOutboundObserver().onNext(ELEMENTS); assertThat(values, contains(ELEMENTS)); }