void testStreamingGrpcCallAndVerifyMappedException(final Status expectedStatus, final Metadata expectedMetadata) {

        final AwaitableStreamObserver<SomeType> responseObserver = new AwaitableStreamObserver<>();
        final StreamObserver<SomeType> requestObserver = this.testServiceStub.echo(responseObserver);
        requestObserver.onNext(SOME_TYPE);
        requestObserver.onCompleted();

        final StatusRuntimeException error =
                (StatusRuntimeException) assertDoesNotThrow(() -> responseObserver.getError());
        verifyStatusAndMetadata(error, expectedStatus, expectedMetadata);

    }
Test template call to check for every exception.

@param expectedStatus The status to expect.
@param expectedMetadata The metadata to expect.
tests/src/test/java/net/devh/boot/grpc/test/advice/AbstractSimpleServerClientTest.java