Been digging into grpc. I found the grpc-java library which has some additional test cases.
I'm thinking
Given THESE exact proto files
https://github.com/grpc/grpc-java/tree/master/testing-proto/src/main/proto/io/grpc/testing/integration
Need some matching integration test cases in swift
https://github.com/grpc/grpc-java/tree/master/testing-proto/src/generated/main/grpc/io/grpc/testing/integration
test for these conditions
-
A service used to control reconnect server.
-
A simple service NOT implemented at servers so clients can test for
-
that case.
-
A simple service to test the various types of RPCs and experiment with
-
performance with various types of payload.
etc
EMPTY_UNARY("empty (zero bytes) request and response"),
CACHEABLE_UNARY("cacheable unary rpc sent using GET"),
LARGE_UNARY("single request and (large) response"),
CLIENT_STREAMING("request streaming with single response"),
SERVER_STREAMING("single request with response streaming"),
PING_PONG("full-duplex ping-pong streaming"),
EMPTY_STREAM("A stream that has zero-messages in both directions"),
COMPUTE_ENGINE_CREDS("large_unary with service_account auth"),
SERVICE_ACCOUNT_CREDS("large_unary with compute engine auth"),
JWT_TOKEN_CREDS("JWT-based auth"),
OAUTH2_AUTH_TOKEN("raw oauth2 access token auth"),
PER_RPC_CREDS("per rpc raw oauth2 access token auth"),
CUSTOM_METADATA("unary and full duplex calls with metadata"),
STATUS_CODE_AND_MESSAGE("request error code and message"),
UNIMPLEMENTED_METHOD("call an unimplemented RPC method"),
UNIMPLEMENTED_SERVICE("call an unimplemented RPC service"),
CANCEL_AFTER_BEGIN("cancel stream after starting it"),
CANCEL_AFTER_FIRST_RESPONSE("cancel on first response"),
TIMEOUT_ON_SLEEPING_SERVER("timeout before receiving a response");
@ericgribkoff - @timburks - consider that there should be a hello world standard for integration test cases. perhaps even spat out as automatic code to test against. As in the test cases + code doing integration testing against
https://github.com/grpc/grpc-java/blob/master/testing-proto/src/main/proto/io/grpc/testing/integration/test.proto
is? valid in other languages.
I've managed to spit out a bunch of swift code that's generated out for tensorflow - but now need to start climbing - and need to have some sanity checks on service. I imagine for any grpc generated code - having a base test harness for grpc service would help troubleshoot lower level things.