|
|
|
@ -54,34 +54,31 @@ DEFINE_string(server_host, "127.0.0.1", "Server host to connect to"); |
|
|
|
|
DEFINE_string(server_host_override, "foo.test.google.fr", |
|
|
|
|
"Override the server host which is sent in HTTP header"); |
|
|
|
|
DEFINE_string(test_case, "large_unary", |
|
|
|
|
"Configure different test cases. Valid options are: " |
|
|
|
|
"empty_unary : empty (zero bytes) request and response; " |
|
|
|
|
"large_unary : single request and (large) response; " |
|
|
|
|
|
|
|
|
|
"client_compressed_unary : single compressed request; " |
|
|
|
|
"server_compressed_unary : single compressed response; " |
|
|
|
|
|
|
|
|
|
"client_streaming : request streaming with single response; " |
|
|
|
|
"server_streaming : single request with response streaming; " |
|
|
|
|
"Configure different test cases. Valid options are:\n\n" |
|
|
|
|
"all : all test cases;\n" |
|
|
|
|
"cancel_after_begin : cancel stream after starting it;\n" |
|
|
|
|
"cancel_after_first_response: cancel on first response;\n" |
|
|
|
|
"client_compressed_streaming : compressed request streaming with " |
|
|
|
|
"single response; " |
|
|
|
|
"client_compressed_unary : single compressed request;\n" |
|
|
|
|
"client_streaming : request streaming with single response;\n" |
|
|
|
|
"compute_engine_creds: large_unary with compute engine auth;\n" |
|
|
|
|
"custom_metadata: server will echo custom metadata;\n" |
|
|
|
|
"empty_stream : bi-di stream with no request/response;\n" |
|
|
|
|
"empty_unary : empty (zero bytes) request and response;\n" |
|
|
|
|
"half_duplex : half-duplex streaming;\n" |
|
|
|
|
"jwt_token_creds: large_unary with JWT token auth;\n" |
|
|
|
|
"large_unary : single request and (large) response;\n" |
|
|
|
|
"oauth2_auth_token: raw oauth2 access token auth;\n" |
|
|
|
|
"per_rpc_creds: raw oauth2 access token on a single rpc;\n" |
|
|
|
|
"ping_pong : full-duplex streaming;\n" |
|
|
|
|
"response streaming;\n" |
|
|
|
|
"server_compressed_streaming : single request with compressed " |
|
|
|
|
"response streaming; " |
|
|
|
|
"slow_consumer : single request with response; " |
|
|
|
|
" streaming with slow client consumer; " |
|
|
|
|
"half_duplex : half-duplex streaming; " |
|
|
|
|
"ping_pong : full-duplex streaming; " |
|
|
|
|
"cancel_after_begin : cancel stream after starting it; " |
|
|
|
|
"cancel_after_first_response: cancel on first response; " |
|
|
|
|
"timeout_on_sleeping_server: deadline exceeds on stream; " |
|
|
|
|
"empty_stream : bi-di stream with no request/response; " |
|
|
|
|
"compute_engine_creds: large_unary with compute engine auth; " |
|
|
|
|
"jwt_token_creds: large_unary with JWT token auth; " |
|
|
|
|
"oauth2_auth_token: raw oauth2 access token auth; " |
|
|
|
|
"per_rpc_creds: raw oauth2 access token on a single rpc; " |
|
|
|
|
"status_code_and_message: verify status code & message; " |
|
|
|
|
"custom_metadata: server will echo custom metadata;" |
|
|
|
|
"all : all of above."); |
|
|
|
|
"server_compressed_unary : single compressed response;\n" |
|
|
|
|
"server_streaming : single request with response streaming;\n" |
|
|
|
|
"slow_consumer : single request with response streaming with " |
|
|
|
|
"slow client consumer;\n" |
|
|
|
|
"status_code_and_message: verify status code & message;\n" |
|
|
|
|
"timeout_on_sleeping_server: deadline exceeds on stream;\n"); |
|
|
|
|
DEFINE_string(default_service_account, "", |
|
|
|
|
"Email of GCE default service account"); |
|
|
|
|
DEFINE_string(service_account_key_file, "", |
|
|
|
@ -178,30 +175,29 @@ int main(int argc, char** argv) { |
|
|
|
|
} |
|
|
|
|
// compute_engine_creds only runs in GCE.
|
|
|
|
|
} else { |
|
|
|
|
const char* testcases[] = |
|
|
|
|
{ "all", |
|
|
|
|
"cancel_after_begin", |
|
|
|
|
"cancel_after_first_response", |
|
|
|
|
"client_compressed_streaming", |
|
|
|
|
"client_compressed_unary", |
|
|
|
|
"client_streaming", |
|
|
|
|
"compute_engine_creds", |
|
|
|
|
"custom_metadata", |
|
|
|
|
"empty_stream", |
|
|
|
|
"empty_unary", |
|
|
|
|
"half_duplex", |
|
|
|
|
"jwt_token_creds", |
|
|
|
|
"large_unary", |
|
|
|
|
"oauth2_auth_token", |
|
|
|
|
"oauth2_auth_token", |
|
|
|
|
"per_rpc_creds", |
|
|
|
|
"per_rpc_creds", |
|
|
|
|
"ping_pong", |
|
|
|
|
"server_compressed_streaming", |
|
|
|
|
"server_compressed_unary", |
|
|
|
|
"server_streaming", |
|
|
|
|
"status_code_and_message", |
|
|
|
|
"timeout_on_sleeping_server"}; |
|
|
|
|
const char* testcases[] = {"all", |
|
|
|
|
"cancel_after_begin", |
|
|
|
|
"cancel_after_first_response", |
|
|
|
|
"client_compressed_streaming", |
|
|
|
|
"client_compressed_unary", |
|
|
|
|
"client_streaming", |
|
|
|
|
"compute_engine_creds", |
|
|
|
|
"custom_metadata", |
|
|
|
|
"empty_stream", |
|
|
|
|
"empty_unary", |
|
|
|
|
"half_duplex", |
|
|
|
|
"jwt_token_creds", |
|
|
|
|
"large_unary", |
|
|
|
|
"oauth2_auth_token", |
|
|
|
|
"oauth2_auth_token", |
|
|
|
|
"per_rpc_creds", |
|
|
|
|
"per_rpc_creds", |
|
|
|
|
"ping_pong", |
|
|
|
|
"server_compressed_streaming", |
|
|
|
|
"server_compressed_unary", |
|
|
|
|
"server_streaming", |
|
|
|
|
"status_code_and_message", |
|
|
|
|
"timeout_on_sleeping_server"}; |
|
|
|
|
char* joined_testcases = |
|
|
|
|
gpr_strjoin_sep(testcases, GPR_ARRAY_SIZE(testcases), "\n", NULL); |
|
|
|
|
|
|
|
|
|