diff options
author | 2018-02-09 09:34:04 -0800 | |
---|---|---|
committer | 2018-02-09 09:34:04 -0800 | |
commit | 4d20a666850b732cf1562487fb5f46ab9654105f (patch) | |
tree | 9059162d0f125e02780f506c2476d5d9bbc0eb7d /test/core/end2end | |
parent | cddf6f838aa48c8d5c9f75cee5a8ed8abdcb25b9 (diff) |
Run clang fmt
Diffstat (limited to 'test/core/end2end')
57 files changed, 420 insertions, 231 deletions
diff --git a/test/core/end2end/bad_server_response_test.cc b/test/core/end2end/bad_server_response_test.cc index 124d05af47..79331bca6f 100644 --- a/test/core/end2end/bad_server_response_test.cc +++ b/test/core/end2end/bad_server_response_test.cc @@ -196,8 +196,8 @@ static void start_rpc(int target_port, grpc_status_code expected_status, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(state.call, ops, static_cast<size_t>(op - ops), tag(1), - nullptr); + error = grpc_call_start_batch(state.call, ops, static_cast<size_t>(op - ops), + tag(1), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); diff --git a/test/core/end2end/dualstack_socket_test.cc b/test/core/end2end/dualstack_socket_test.cc index a7f10e49bf..411d0f2308 100644 --- a/test/core/end2end/dualstack_socket_test.cc +++ b/test/core/end2end/dualstack_socket_test.cc @@ -128,8 +128,8 @@ void test_connect(const char* server_host, const char* client_host, int port, grpc_slice_buffer uri_parts; char** hosts_with_port; - uri_slice = - grpc_slice_new(const_cast<char*>(client_host), strlen(client_host), do_nothing); + uri_slice = grpc_slice_new(const_cast<char*>(client_host), + strlen(client_host), do_nothing); grpc_slice_buffer_init(&uri_parts); grpc_slice_split(uri_slice, ",", &uri_parts); hosts_with_port = @@ -199,7 +199,8 @@ void test_connect(const char* server_host, const char* client_host, int port, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); if (expect_ok) { @@ -227,8 +228,8 @@ void test_connect(const char* server_host, const char* client_host, int port, op->data.recv_close_on_server.cancelled = &was_cancelled; op->flags = 0; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/fixtures/http_proxy_fixture.cc b/test/core/end2end/fixtures/http_proxy_fixture.cc index 4776cfbc1b..63a15753a4 100644 --- a/test/core/end2end/fixtures/http_proxy_fixture.cc +++ b/test/core/end2end/fixtures/http_proxy_fixture.cc @@ -458,7 +458,8 @@ static void on_accept(void* arg, grpc_endpoint* endpoint, gpr_free(acceptor); grpc_end2end_http_proxy* proxy = static_cast<grpc_end2end_http_proxy*>(arg); // Instantiate proxy_connection. - proxy_connection* conn = static_cast<proxy_connection*>(gpr_zalloc(sizeof(*conn))); + proxy_connection* conn = + static_cast<proxy_connection*>(gpr_zalloc(sizeof(*conn))); gpr_ref(&proxy->users); conn->client_endpoint = endpoint; conn->proxy = proxy; @@ -533,7 +534,8 @@ grpc_end2end_http_proxy* grpc_end2end_http_proxy_create( GPR_ASSERT(error == GRPC_ERROR_NONE); // Bind to port. grpc_resolved_address resolved_addr; - struct sockaddr_in* addr = reinterpret_cast<struct sockaddr_in*>(resolved_addr.addr); + struct sockaddr_in* addr = + reinterpret_cast<struct sockaddr_in*>(resolved_addr.addr); memset(&resolved_addr, 0, sizeof(resolved_addr)); addr->sin_family = AF_INET; grpc_sockaddr_set_port(&resolved_addr, proxy_port); diff --git a/test/core/end2end/fixtures/proxy.cc b/test/core/end2end/fixtures/proxy.cc index d0a4bbb96e..918988d9dc 100644 --- a/test/core/end2end/fixtures/proxy.cc +++ b/test/core/end2end/fixtures/proxy.cc @@ -80,7 +80,8 @@ grpc_end2end_proxy* grpc_end2end_proxy_create(const grpc_end2end_proxy_def* def, int proxy_port = grpc_pick_unused_port_or_die(); int server_port = grpc_pick_unused_port_or_die(); - grpc_end2end_proxy* proxy = static_cast<grpc_end2end_proxy*>(gpr_malloc(sizeof(*proxy))); + grpc_end2end_proxy* proxy = + static_cast<grpc_end2end_proxy*>(gpr_malloc(sizeof(*proxy))); memset(proxy, 0, sizeof(*proxy)); gpr_join_host_port(&proxy->proxy_port, "localhost", proxy_port); diff --git a/test/core/end2end/fuzzers/api_fuzzer.cc b/test/core/end2end/fuzzers/api_fuzzer.cc index fa50c24ca5..dc1183b9a0 100644 --- a/test/core/end2end/fuzzers/api_fuzzer.cc +++ b/test/core/end2end/fuzzers/api_fuzzer.cc @@ -192,7 +192,9 @@ static grpc_byte_buffer* read_message(input_stream* inp) { return out; } -static int read_int(input_stream* inp) { return static_cast<int>(read_uint32(inp)); } +static int read_int(input_stream* inp) { + return static_cast<int>(read_uint32(inp)); +} static grpc_channel_args* read_args(input_stream* inp) { size_t n = next_byte(inp); @@ -532,7 +534,9 @@ static void assert_success_and_decrement(void* counter, bool success) { --*static_cast<int*>(counter); } -static void decrement(void* counter, bool success) { --*static_cast<int*>(counter); } +static void decrement(void* counter, bool success) { + --*static_cast<int*>(counter); +} typedef struct connectivity_watch { int* counter; diff --git a/test/core/end2end/goaway_server_test.cc b/test/core/end2end/goaway_server_test.cc index 20468ad0e5..09f0301c44 100644 --- a/test/core/end2end/goaway_server_test.cc +++ b/test/core/end2end/goaway_server_test.cc @@ -77,7 +77,8 @@ static void my_resolve_address(const char* addr, const char* default_port, (*addrs)->addrs = static_cast<grpc_resolved_address*>( gpr_malloc(sizeof(*(*addrs)->addrs))); memset((*addrs)->addrs, 0, sizeof(*(*addrs)->addrs)); - struct sockaddr_in* sa = reinterpret_cast<struct sockaddr_in*>((*addrs)->addrs[0].addr); + struct sockaddr_in* sa = + reinterpret_cast<struct sockaddr_in*>((*addrs)->addrs[0].addr); sa->sin_family = AF_INET; sa->sin_addr.s_addr = htonl(0x7f000001); sa->sin_port = htons(static_cast<uint16_t>(g_resolve_port)); diff --git a/test/core/end2end/h2_ssl_cert_test.cc b/test/core/end2end/h2_ssl_cert_test.cc index b4b3462c68..9e2082ce9d 100644 --- a/test/core/end2end/h2_ssl_cert_test.cc +++ b/test/core/end2end/h2_ssl_cert_test.cc @@ -333,7 +333,8 @@ static void simple_request_body(grpc_end2end_test_fixture f, op->flags = GRPC_INITIAL_METADATA_WAIT_FOR_READY; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), expected_result == SUCCESS); diff --git a/test/core/end2end/tests/authority_not_supported.cc b/test/core/end2end/tests/authority_not_supported.cc index 498fb5cf35..01a95e4e10 100644 --- a/test/core/end2end/tests/authority_not_supported.cc +++ b/test/core/end2end/tests/authority_not_supported.cc @@ -154,7 +154,8 @@ static void test_with_authority_header(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/bad_hostname.cc b/test/core/end2end/tests/bad_hostname.cc index 60097dfa4c..b6f06a20d6 100644 --- a/test/core/end2end/tests/bad_hostname.cc +++ b/test/core/end2end/tests/bad_hostname.cc @@ -133,7 +133,8 @@ static void simple_request_body(grpc_end2end_test_fixture f) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/bad_ping.cc b/test/core/end2end/tests/bad_ping.cc index 0972e86e9a..ddab3faa27 100644 --- a/test/core/end2end/tests/bad_ping.cc +++ b/test/core/end2end/tests/bad_ping.cc @@ -144,7 +144,8 @@ static void test_bad_ping(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -188,7 +189,8 @@ static void test_bad_ping(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/binary_metadata.cc b/test/core/end2end/tests/binary_metadata.cc index 1313ca4bea..e66b4da6cc 100644 --- a/test/core/end2end/tests/binary_metadata.cc +++ b/test/core/end2end/tests/binary_metadata.cc @@ -182,7 +182,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -205,7 +206,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -246,7 +248,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/call_creds.cc b/test/core/end2end/tests/call_creds.cc index cb65b18064..e9cbaa3088 100644 --- a/test/core/end2end/tests/call_creds.cc +++ b/test/core/end2end/tests/call_creds.cc @@ -219,7 +219,8 @@ static void request_response_with_payload_and_call_creds( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -253,7 +254,8 @@ static void request_response_with_payload_and_call_creds( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -279,7 +281,8 @@ static void request_response_with_payload_and_call_creds( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); @@ -443,7 +446,8 @@ static void test_request_with_server_rejecting_client_creds( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(error == GRPC_CALL_OK); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/cancel_after_accept.cc b/test/core/end2end/tests/cancel_after_accept.cc index 86c91c1580..ee1a0bbccc 100644 --- a/test/core/end2end/tests/cancel_after_accept.cc +++ b/test/core/end2end/tests/cancel_after_accept.cc @@ -186,7 +186,8 @@ static void test_cancel_after_accept(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = grpc_server_request_call(f.server, &s, &call_details, @@ -217,7 +218,8 @@ static void test_cancel_after_accept(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == mode.initiate_cancel(c, nullptr)); diff --git a/test/core/end2end/tests/cancel_after_client_done.cc b/test/core/end2end/tests/cancel_after_client_done.cc index 9e92c27f03..31c3ea6f74 100644 --- a/test/core/end2end/tests/cancel_after_client_done.cc +++ b/test/core/end2end/tests/cancel_after_client_done.cc @@ -164,7 +164,8 @@ static void test_cancel_after_accept_and_writes_closed( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = grpc_server_request_call(f.server, &s, &call_details, @@ -195,7 +196,8 @@ static void test_cancel_after_accept_and_writes_closed( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == mode.initiate_cancel(c, nullptr)); diff --git a/test/core/end2end/tests/cancel_after_round_trip.cc b/test/core/end2end/tests/cancel_after_round_trip.cc index 88aa63c7af..bf3be1c8b7 100644 --- a/test/core/end2end/tests/cancel_after_round_trip.cc +++ b/test/core/end2end/tests/cancel_after_round_trip.cc @@ -181,7 +181,8 @@ static void test_cancel_after_round_trip(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -208,7 +209,8 @@ static void test_cancel_after_round_trip(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -234,7 +236,8 @@ static void test_cancel_after_round_trip(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == mode.initiate_cancel(c, nullptr)); @@ -251,7 +254,8 @@ static void test_cancel_after_round_trip(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); diff --git a/test/core/end2end/tests/compressed_payload.cc b/test/core/end2end/tests/compressed_payload.cc index 0879d72368..85cfe16508 100644 --- a/test/core/end2end/tests/compressed_payload.cc +++ b/test/core/end2end/tests/compressed_payload.cc @@ -187,7 +187,8 @@ static void request_for_disabled_algorithm( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(101), true); @@ -205,7 +206,8 @@ static void request_for_disabled_algorithm( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), false); @@ -216,7 +218,8 @@ static void request_for_disabled_algorithm( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), true); @@ -338,7 +341,8 @@ static void request_with_payload_template( op->flags = client_send_flags_bitmask; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), true); } @@ -367,7 +371,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -403,7 +408,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); for (int i = 0; i < 2; i++) { @@ -418,8 +424,8 @@ static void request_with_payload_template( op->flags = client_send_flags_bitmask; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), + tag(2), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); } @@ -431,8 +437,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -450,8 +456,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(103), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -461,7 +467,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); @@ -495,7 +502,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -508,7 +516,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/default_host.cc b/test/core/end2end/tests/default_host.cc index fefb5a58d1..3191f76688 100644 --- a/test/core/end2end/tests/default_host.cc +++ b/test/core/end2end/tests/default_host.cc @@ -140,7 +140,8 @@ static void simple_request_body(grpc_end2end_test_fixture f) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(error == GRPC_CALL_OK); error = @@ -179,7 +180,8 @@ static void simple_request_body(grpc_end2end_test_fixture f) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(error == GRPC_CALL_OK); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/disappearing_server.cc b/test/core/end2end/tests/disappearing_server.cc index 9712b9f86e..d5b6f8fbf0 100644 --- a/test/core/end2end/tests/disappearing_server.cc +++ b/test/core/end2end/tests/disappearing_server.cc @@ -120,7 +120,8 @@ static void do_request_and_shutdown_server(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -154,7 +155,8 @@ static void do_request_and_shutdown_server(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/filter_call_init_fails.cc b/test/core/end2end/tests/filter_call_init_fails.cc index c63a5b938d..6f72a1843a 100644 --- a/test/core/end2end/tests/filter_call_init_fails.cc +++ b/test/core/end2end/tests/filter_call_init_fails.cc @@ -158,7 +158,8 @@ static void test_server_channel_filter(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -253,7 +254,8 @@ static void test_client_channel_filter(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); @@ -344,7 +346,8 @@ static void test_client_subchannel_filter(grpc_end2end_test_config config) { op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); @@ -368,7 +371,8 @@ static void test_client_subchannel_filter(grpc_end2end_test_config config) { nullptr); GPR_ASSERT(c); - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); diff --git a/test/core/end2end/tests/filter_causes_close.cc b/test/core/end2end/tests/filter_causes_close.cc index 07543f8e74..bc4cb8633d 100644 --- a/test/core/end2end/tests/filter_causes_close.cc +++ b/test/core/end2end/tests/filter_causes_close.cc @@ -152,7 +152,8 @@ static void test_request(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = diff --git a/test/core/end2end/tests/filter_latency.cc b/test/core/end2end/tests/filter_latency.cc index 42507ad41a..51f54c9742 100644 --- a/test/core/end2end/tests/filter_latency.cc +++ b/test/core/end2end/tests/filter_latency.cc @@ -165,7 +165,8 @@ static void test_request(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -196,7 +197,8 @@ static void test_request(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/filter_status_code.cc b/test/core/end2end/tests/filter_status_code.cc index 389c63b2ac..32cd95410e 100644 --- a/test/core/end2end/tests/filter_status_code.cc +++ b/test/core/end2end/tests/filter_status_code.cc @@ -164,7 +164,8 @@ static void test_request(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -199,7 +200,8 @@ static void test_request(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/graceful_server_shutdown.cc b/test/core/end2end/tests/graceful_server_shutdown.cc index 9a14476df4..3ef414f83c 100644 --- a/test/core/end2end/tests/graceful_server_shutdown.cc +++ b/test/core/end2end/tests/graceful_server_shutdown.cc @@ -135,7 +135,8 @@ static void test_early_server_shutdown_finishes_inflight_calls( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -169,7 +170,8 @@ static void test_early_server_shutdown_finishes_inflight_calls( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/high_initial_seqno.cc b/test/core/end2end/tests/high_initial_seqno.cc index cb67787e98..8767437802 100644 --- a/test/core/end2end/tests/high_initial_seqno.cc +++ b/test/core/end2end/tests/high_initial_seqno.cc @@ -139,7 +139,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -169,7 +170,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/hpack_size.cc b/test/core/end2end/tests/hpack_size.cc index 8f7f3e6a6c..b49736841e 100644 --- a/test/core/end2end/tests/hpack_size.cc +++ b/test/core/end2end/tests/hpack_size.cc @@ -293,7 +293,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -323,7 +324,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/idempotent_request.cc b/test/core/end2end/tests/idempotent_request.cc index c0eac683c7..56be2d6afe 100644 --- a/test/core/end2end/tests/idempotent_request.cc +++ b/test/core/end2end/tests/idempotent_request.cc @@ -144,7 +144,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -183,7 +184,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/invoke_large_request.cc b/test/core/end2end/tests/invoke_large_request.cc index 5705094a15..1aab34c2ce 100644 --- a/test/core/end2end/tests/invoke_large_request.cc +++ b/test/core/end2end/tests/invoke_large_request.cc @@ -176,7 +176,8 @@ static void test_invoke_large_request(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -198,7 +199,8 @@ static void test_invoke_large_request(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -224,7 +226,8 @@ static void test_invoke_large_request(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/keepalive_timeout.cc b/test/core/end2end/tests/keepalive_timeout.cc index 76beedb1ba..f0dd061e33 100644 --- a/test/core/end2end/tests/keepalive_timeout.cc +++ b/test/core/end2end/tests/keepalive_timeout.cc @@ -155,7 +155,8 @@ static void test_keepalive_timeout(grpc_end2end_test_config config) { op->op = GRPC_OP_RECV_MESSAGE; op->data.recv_message.recv_message = &response_payload_recv; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == grpc_server_request_call( @@ -172,7 +173,8 @@ static void test_keepalive_timeout(grpc_end2end_test_config config) { op->op = GRPC_OP_SEND_MESSAGE; op->data.send_message.send_message = response_payload; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -186,7 +188,8 @@ static void test_keepalive_timeout(grpc_end2end_test_config config) { op->data.recv_status_on_client.status = &status; op->data.recv_status_on_client.status_details = &details; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(3), 1); diff --git a/test/core/end2end/tests/large_metadata.cc b/test/core/end2end/tests/large_metadata.cc index 5e04161e08..da0615bf6e 100644 --- a/test/core/end2end/tests/large_metadata.cc +++ b/test/core/end2end/tests/large_metadata.cc @@ -160,7 +160,8 @@ static void test_request_with_large_metadata(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -184,7 +185,8 @@ static void test_request_with_large_metadata(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -207,7 +209,8 @@ static void test_request_with_large_metadata(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/load_reporting_hook.cc b/test/core/end2end/tests/load_reporting_hook.cc index de6b60c216..9e79d02be4 100644 --- a/test/core/end2end/tests/load_reporting_hook.cc +++ b/test/core/end2end/tests/load_reporting_hook.cc @@ -185,7 +185,8 @@ static void request_response_with_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -207,7 +208,8 @@ static void request_response_with_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -235,7 +237,8 @@ static void request_response_with_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/max_concurrent_streams.cc b/test/core/end2end/tests/max_concurrent_streams.cc index ed658a3507..789b3d4b77 100644 --- a/test/core/end2end/tests/max_concurrent_streams.cc +++ b/test/core/end2end/tests/max_concurrent_streams.cc @@ -135,7 +135,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -165,7 +166,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -274,7 +276,8 @@ static void test_max_concurrent_streams(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), tag(301), nullptr); + error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), + tag(301), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -292,7 +295,8 @@ static void test_max_concurrent_streams(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), tag(302), nullptr); + error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), + tag(302), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -306,7 +310,8 @@ static void test_max_concurrent_streams(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), tag(401), nullptr); + error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), + tag(401), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -324,7 +329,8 @@ static void test_max_concurrent_streams(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), tag(402), nullptr); + error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), + tag(402), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); got_client_start = 0; @@ -371,7 +377,8 @@ static void test_max_concurrent_streams(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s1, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s1, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -408,7 +415,8 @@ static void test_max_concurrent_streams(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s2, ops, static_cast<size_t>(op - ops), tag(202), nullptr); + error = grpc_call_start_batch(s2, ops, static_cast<size_t>(op - ops), + tag(202), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(live_call + 2), 1); @@ -514,7 +522,8 @@ static void test_max_concurrent_streams_with_timeout_on_first( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), tag(301), nullptr); + error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), + tag(301), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -532,7 +541,8 @@ static void test_max_concurrent_streams_with_timeout_on_first( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), tag(302), nullptr); + error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), + tag(302), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(101), 1); @@ -550,7 +560,8 @@ static void test_max_concurrent_streams_with_timeout_on_first( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), tag(401), nullptr); + error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), + tag(401), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -568,7 +579,8 @@ static void test_max_concurrent_streams_with_timeout_on_first( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), tag(402), nullptr); + error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), + tag(402), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); grpc_call_details_destroy(&call_details); @@ -603,7 +615,8 @@ static void test_max_concurrent_streams_with_timeout_on_first( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s2, ops, static_cast<size_t>(op - ops), tag(202), nullptr); + error = grpc_call_start_batch(s2, ops, static_cast<size_t>(op - ops), + tag(202), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(402), 1); @@ -709,7 +722,8 @@ static void test_max_concurrent_streams_with_timeout_on_second( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), tag(301), nullptr); + error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), + tag(301), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -727,7 +741,8 @@ static void test_max_concurrent_streams_with_timeout_on_second( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), tag(302), nullptr); + error = grpc_call_start_batch(c1, ops, static_cast<size_t>(op - ops), + tag(302), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(101), 1); @@ -745,7 +760,8 @@ static void test_max_concurrent_streams_with_timeout_on_second( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), tag(401), nullptr); + error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), + tag(401), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -763,7 +779,8 @@ static void test_max_concurrent_streams_with_timeout_on_second( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), tag(402), nullptr); + error = grpc_call_start_batch(c2, ops, static_cast<size_t>(op - ops), + tag(402), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); /* the second request is time out*/ @@ -796,7 +813,8 @@ static void test_max_concurrent_streams_with_timeout_on_second( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s1, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s1, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(302), 1); diff --git a/test/core/end2end/tests/max_connection_age.cc b/test/core/end2end/tests/max_connection_age.cc index 4b498e6bf8..e494dad19c 100644 --- a/test/core/end2end/tests/max_connection_age.cc +++ b/test/core/end2end/tests/max_connection_age.cc @@ -145,7 +145,8 @@ static void test_max_age_forcibly_close(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -156,7 +157,8 @@ static void test_max_age_forcibly_close(grpc_end2end_test_config config) { cq_verify(cqv); gpr_timespec expect_shutdown_time = grpc_timeout_milliseconds_to_deadline( - static_cast<int>(MAX_CONNECTION_AGE_MS * MAX_CONNECTION_AGE_JITTER_MULTIPLIER) + + static_cast<int>(MAX_CONNECTION_AGE_MS * + MAX_CONNECTION_AGE_JITTER_MULTIPLIER) + MAX_CONNECTION_AGE_GRACE_MS + IMMEDIATE_SHUTDOWN_GRACE_TIME_MS); /* Wait for the channel to reach its max age */ @@ -190,7 +192,8 @@ static void test_max_age_forcibly_close(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), true); cq_verify(cqv); @@ -288,7 +291,8 @@ static void test_max_age_gracefully_close(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -325,7 +329,8 @@ static void test_max_age_gracefully_close(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), true); diff --git a/test/core/end2end/tests/max_connection_idle.cc b/test/core/end2end/tests/max_connection_idle.cc index beff733593..2f212b965f 100644 --- a/test/core/end2end/tests/max_connection_idle.cc +++ b/test/core/end2end/tests/max_connection_idle.cc @@ -100,7 +100,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -139,7 +140,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/max_message_length.cc b/test/core/end2end/tests/max_message_length.cc index 987c348c00..3dd1737793 100644 --- a/test/core/end2end/tests/max_message_length.cc +++ b/test/core/end2end/tests/max_message_length.cc @@ -219,7 +219,8 @@ static void test_max_message_length_on_request(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); if (send_limit) { @@ -247,7 +248,8 @@ static void test_max_message_length_on_request(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -408,7 +410,8 @@ static void test_max_message_length_on_response(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -443,7 +446,8 @@ static void test_max_message_length_on_response(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/network_status_change.cc b/test/core/end2end/tests/network_status_change.cc index fe941e8ac8..83cb172f26 100644 --- a/test/core/end2end/tests/network_status_change.cc +++ b/test/core/end2end/tests/network_status_change.cc @@ -150,7 +150,8 @@ static void test_invoke_network_status_change(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == grpc_server_request_call( @@ -170,7 +171,8 @@ static void test_invoke_network_status_change(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -193,7 +195,8 @@ static void test_invoke_network_status_change(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/no_logging.cc b/test/core/end2end/tests/no_logging.cc index c4678f461f..b357e3b0ad 100644 --- a/test/core/end2end/tests/no_logging.cc +++ b/test/core/end2end/tests/no_logging.cc @@ -170,7 +170,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -207,7 +208,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/payload.cc b/test/core/end2end/tests/payload.cc index 0e19e29cb6..340c76e173 100644 --- a/test/core/end2end/tests/payload.cc +++ b/test/core/end2end/tests/payload.cc @@ -174,7 +174,8 @@ static void request_response_with_payload(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -196,7 +197,8 @@ static void request_response_with_payload(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -222,7 +224,8 @@ static void request_response_with_payload(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/ping_pong_streaming.cc b/test/core/end2end/tests/ping_pong_streaming.cc index 9ac4d544f2..9ca880481f 100644 --- a/test/core/end2end/tests/ping_pong_streaming.cc +++ b/test/core/end2end/tests/ping_pong_streaming.cc @@ -143,7 +143,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -165,7 +166,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); for (i = 0; i < messages; i++) { @@ -184,7 +186,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -194,8 +197,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); cq_verify(cqv); @@ -207,8 +210,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(103), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); @@ -229,7 +232,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -242,7 +246,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/proxy_auth.cc b/test/core/end2end/tests/proxy_auth.cc index fd1cbadaf5..5a2e0ef414 100644 --- a/test/core/end2end/tests/proxy_auth.cc +++ b/test/core/end2end/tests/proxy_auth.cc @@ -148,7 +148,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -187,7 +188,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/registered_call.cc b/test/core/end2end/tests/registered_call.cc index 49a9f88df8..d4ca146707 100644 --- a/test/core/end2end/tests/registered_call.cc +++ b/test/core/end2end/tests/registered_call.cc @@ -135,7 +135,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -165,7 +166,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/request_with_flags.cc b/test/core/end2end/tests/request_with_flags.cc index bfce0a0be1..4a54318d0f 100644 --- a/test/core/end2end/tests/request_with_flags.cc +++ b/test/core/end2end/tests/request_with_flags.cc @@ -151,7 +151,8 @@ static void test_invoke_request_with_flags( op->reserved = nullptr; op++; expectation = call_start_batch_expected_result; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(expectation == error); if (expectation == GRPC_CALL_OK) { diff --git a/test/core/end2end/tests/request_with_payload.cc b/test/core/end2end/tests/request_with_payload.cc index fc87f5823e..44398df52d 100644 --- a/test/core/end2end/tests/request_with_payload.cc +++ b/test/core/end2end/tests/request_with_payload.cc @@ -147,7 +147,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == grpc_server_request_call( @@ -168,7 +169,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -189,7 +191,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/resource_quota_server.cc b/test/core/end2end/tests/resource_quota_server.cc index c9d8ab7f9f..33d6b4ef31 100644 --- a/test/core/end2end/tests/resource_quota_server.cc +++ b/test/core/end2end/tests/resource_quota_server.cc @@ -136,20 +136,24 @@ void resource_quota_server(grpc_end2end_test_config config) { grpc_call** server_calls = static_cast<grpc_call**>(malloc(sizeof(grpc_call*) * NUM_CALLS)); grpc_metadata_array* initial_metadata_recv = - static_cast<grpc_metadata_array*>(malloc(sizeof(grpc_metadata_array) * NUM_CALLS)); + static_cast<grpc_metadata_array*>( + malloc(sizeof(grpc_metadata_array) * NUM_CALLS)); grpc_metadata_array* trailing_metadata_recv = - static_cast<grpc_metadata_array*>(malloc(sizeof(grpc_metadata_array) * NUM_CALLS)); + static_cast<grpc_metadata_array*>( + malloc(sizeof(grpc_metadata_array) * NUM_CALLS)); grpc_metadata_array* request_metadata_recv = - static_cast<grpc_metadata_array*>(malloc(sizeof(grpc_metadata_array) * NUM_CALLS)); - grpc_call_details* call_details = - static_cast<grpc_call_details*>(malloc(sizeof(grpc_call_details) * NUM_CALLS)); - grpc_status_code* status = - static_cast<grpc_status_code*>(malloc(sizeof(grpc_status_code) * NUM_CALLS)); - grpc_slice* details = static_cast<grpc_slice*>(malloc(sizeof(grpc_slice) * NUM_CALLS)); - grpc_byte_buffer** request_payload = - static_cast<grpc_byte_buffer**>(malloc(sizeof(grpc_byte_buffer*) * NUM_CALLS)); - grpc_byte_buffer** request_payload_recv = - static_cast<grpc_byte_buffer**>(malloc(sizeof(grpc_byte_buffer*) * NUM_CALLS)); + static_cast<grpc_metadata_array*>( + malloc(sizeof(grpc_metadata_array) * NUM_CALLS)); + grpc_call_details* call_details = static_cast<grpc_call_details*>( + malloc(sizeof(grpc_call_details) * NUM_CALLS)); + grpc_status_code* status = static_cast<grpc_status_code*>( + malloc(sizeof(grpc_status_code) * NUM_CALLS)); + grpc_slice* details = + static_cast<grpc_slice*>(malloc(sizeof(grpc_slice) * NUM_CALLS)); + grpc_byte_buffer** request_payload = static_cast<grpc_byte_buffer**>( + malloc(sizeof(grpc_byte_buffer*) * NUM_CALLS)); + grpc_byte_buffer** request_payload_recv = static_cast<grpc_byte_buffer**>( + malloc(sizeof(grpc_byte_buffer*) * NUM_CALLS)); int* was_cancelled = static_cast<int*>(malloc(sizeof(int) * NUM_CALLS)); grpc_call_error error; int pending_client_calls = 0; @@ -220,7 +224,8 @@ void resource_quota_server(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(client_calls[i], ops, static_cast<size_t>(op - ops), + error = grpc_call_start_batch(client_calls[i], ops, + static_cast<size_t>(op - ops), tag(CLIENT_BASE_TAG + i), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); @@ -285,9 +290,9 @@ void resource_quota_server(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(server_calls[call_id], ops, static_cast<size_t>(op - ops), - tag(SERVER_RECV_BASE_TAG + call_id), nullptr); + error = grpc_call_start_batch( + server_calls[call_id], ops, static_cast<size_t>(op - ops), + tag(SERVER_RECV_BASE_TAG + call_id), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(pending_server_start_calls > 0); @@ -326,9 +331,9 @@ void resource_quota_server(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(server_calls[call_id], ops, static_cast<size_t>(op - ops), - tag(SERVER_END_BASE_TAG + call_id), nullptr); + error = grpc_call_start_batch( + server_calls[call_id], ops, static_cast<size_t>(op - ops), + tag(SERVER_END_BASE_TAG + call_id), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(pending_server_recv_calls > 0); diff --git a/test/core/end2end/tests/server_finishes_request.cc b/test/core/end2end/tests/server_finishes_request.cc index 4423ed3cf2..6fc06cfaa1 100644 --- a/test/core/end2end/tests/server_finishes_request.cc +++ b/test/core/end2end/tests/server_finishes_request.cc @@ -133,7 +133,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -163,7 +164,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/shutdown_finishes_calls.cc b/test/core/end2end/tests/shutdown_finishes_calls.cc index bdba7a6532..34c4ebbf0a 100644 --- a/test/core/end2end/tests/shutdown_finishes_calls.cc +++ b/test/core/end2end/tests/shutdown_finishes_calls.cc @@ -128,7 +128,8 @@ static void test_early_server_shutdown_finishes_inflight_calls( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -145,7 +146,8 @@ static void test_early_server_shutdown_finishes_inflight_calls( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); /* shutdown and destroy the server */ diff --git a/test/core/end2end/tests/simple_cacheable_request.cc b/test/core/end2end/tests/simple_cacheable_request.cc index d7be88713f..4ae8398a6e 100644 --- a/test/core/end2end/tests/simple_cacheable_request.cc +++ b/test/core/end2end/tests/simple_cacheable_request.cc @@ -178,7 +178,8 @@ static void test_cacheable_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -201,7 +202,8 @@ static void test_cacheable_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -227,7 +229,8 @@ static void test_cacheable_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/simple_delayed_request.cc b/test/core/end2end/tests/simple_delayed_request.cc index 12207f0771..f8a1ddfdc3 100644 --- a/test/core/end2end/tests/simple_delayed_request.cc +++ b/test/core/end2end/tests/simple_delayed_request.cc @@ -129,7 +129,8 @@ static void simple_delayed_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -159,7 +160,8 @@ static void simple_delayed_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/simple_metadata.cc b/test/core/end2end/tests/simple_metadata.cc index 246c8b0d6f..1f39f8983b 100644 --- a/test/core/end2end/tests/simple_metadata.cc +++ b/test/core/end2end/tests/simple_metadata.cc @@ -176,7 +176,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -199,7 +200,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -225,7 +227,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/simple_request.cc b/test/core/end2end/tests/simple_request.cc index 8bc7fa6e2c..926e2c7452 100644 --- a/test/core/end2end/tests/simple_request.cc +++ b/test/core/end2end/tests/simple_request.cc @@ -152,7 +152,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -191,7 +192,8 @@ static void simple_request_body(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); diff --git a/test/core/end2end/tests/stream_compression_compressed_payload.cc b/test/core/end2end/tests/stream_compression_compressed_payload.cc index 4dea64e9aa..e90d54f054 100644 --- a/test/core/end2end/tests/stream_compression_compressed_payload.cc +++ b/test/core/end2end/tests/stream_compression_compressed_payload.cc @@ -187,7 +187,8 @@ static void request_for_disabled_algorithm( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(101), true); @@ -205,7 +206,8 @@ static void request_for_disabled_algorithm( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), false); @@ -216,7 +218,8 @@ static void request_for_disabled_algorithm( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), true); @@ -345,7 +348,8 @@ static void request_with_payload_template( op->flags = client_send_flags_bitmask; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), true); } @@ -374,7 +378,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -414,7 +419,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); for (int i = 0; i < 2; i++) { @@ -429,8 +435,8 @@ static void request_with_payload_template( op->flags = client_send_flags_bitmask; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), + tag(2), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); } @@ -442,8 +448,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -459,8 +465,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(103), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -470,7 +476,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); @@ -495,7 +502,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -508,7 +516,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/stream_compression_payload.cc b/test/core/end2end/tests/stream_compression_payload.cc index f11230f6b2..9eace97afd 100644 --- a/test/core/end2end/tests/stream_compression_payload.cc +++ b/test/core/end2end/tests/stream_compression_payload.cc @@ -177,7 +177,8 @@ static void request_response_with_payload(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -199,7 +200,8 @@ static void request_response_with_payload(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -225,7 +227,8 @@ static void request_response_with_payload(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/stream_compression_ping_pong_streaming.cc b/test/core/end2end/tests/stream_compression_ping_pong_streaming.cc index 6f57667d5c..5b033292b0 100644 --- a/test/core/end2end/tests/stream_compression_ping_pong_streaming.cc +++ b/test/core/end2end/tests/stream_compression_ping_pong_streaming.cc @@ -151,7 +151,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -173,7 +174,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); for (i = 0; i < messages; i++) { @@ -192,7 +194,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -202,8 +205,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); cq_verify(cqv); @@ -215,8 +218,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(103), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); @@ -237,7 +240,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -250,7 +254,8 @@ static void test_pingpong_streaming(grpc_end2end_test_config config, op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/streaming_error_response.cc b/test/core/end2end/tests/streaming_error_response.cc index e67920551a..7c7d778d1e 100644 --- a/test/core/end2end/tests/streaming_error_response.cc +++ b/test/core/end2end/tests/streaming_error_response.cc @@ -148,7 +148,8 @@ static void test(grpc_end2end_test_config config, bool request_status_early) { op->data.recv_status_on_client.status_details = &details; op++; } - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == grpc_server_request_call( @@ -165,7 +166,8 @@ static void test(grpc_end2end_test_config config, bool request_status_early) { op->op = GRPC_OP_SEND_MESSAGE; op->data.send_message.send_message = response_payload1; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -179,7 +181,8 @@ static void test(grpc_end2end_test_config config, bool request_status_early) { op->op = GRPC_OP_SEND_MESSAGE; op->data.send_message.send_message = response_payload2; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); @@ -190,7 +193,8 @@ static void test(grpc_end2end_test_config config, bool request_status_early) { op->op = GRPC_OP_RECV_MESSAGE; op->data.recv_message.recv_message = &response_payload2_recv; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); @@ -208,7 +212,8 @@ static void test(grpc_end2end_test_config config, bool request_status_early) { grpc_slice status_details = grpc_slice_from_static_string("xyz"); op->data.send_status_from_server.status_details = &status_details; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(104), 1); @@ -225,7 +230,8 @@ static void test(grpc_end2end_test_config config, bool request_status_early) { op->data.recv_status_on_client.status = &status; op->data.recv_status_on_client.status_details = &details; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(3), 1); diff --git a/test/core/end2end/tests/trailing_metadata.cc b/test/core/end2end/tests/trailing_metadata.cc index 134baaaf93..24069854ac 100644 --- a/test/core/end2end/tests/trailing_metadata.cc +++ b/test/core/end2end/tests/trailing_metadata.cc @@ -184,7 +184,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -207,7 +208,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); @@ -234,7 +236,8 @@ static void test_request_response_with_metadata_and_payload( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); diff --git a/test/core/end2end/tests/workaround_cronet_compression.cc b/test/core/end2end/tests/workaround_cronet_compression.cc index 3de326bef2..4d4c369a42 100644 --- a/test/core/end2end/tests/workaround_cronet_compression.cc +++ b/test/core/end2end/tests/workaround_cronet_compression.cc @@ -191,7 +191,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); error = @@ -227,7 +228,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(101), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); for (int i = 0; i < 2; i++) { @@ -246,7 +248,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -256,8 +259,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(102), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(102), 1); cq_verify(cqv); @@ -274,8 +277,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = - grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), + tag(103), nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(103), 1); CQ_EXPECT_COMPLETION(cqv, tag(2), 1); @@ -308,7 +311,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -321,7 +325,8 @@ static void request_with_payload_template( op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(1), 1); diff --git a/test/core/end2end/tests/write_buffering.cc b/test/core/end2end/tests/write_buffering.cc index 35ab72cc53..5d76d238b9 100644 --- a/test/core/end2end/tests/write_buffering.cc +++ b/test/core/end2end/tests/write_buffering.cc @@ -128,7 +128,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -138,7 +139,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == grpc_server_request_call( @@ -154,7 +156,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->data.send_message.send_message = request_payload1; op->flags = GRPC_WRITE_BUFFER_HINT; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -162,7 +165,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); /* recv message should not succeed yet - it's buffered at the client still */ @@ -171,7 +175,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_RECV_MESSAGE; op->data.recv_message.recv_message = &request_payload_recv1; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), true); @@ -186,7 +191,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->data.send_message.send_message = request_payload2; op->flags = 0; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); /* now the first send should match up with the first recv */ @@ -200,7 +206,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_RECV_MESSAGE; op->data.recv_message.recv_message = &request_payload_recv2; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(104), true); @@ -219,7 +226,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), + nullptr); memset(ops, 0, sizeof(ops)); op = ops; @@ -236,7 +244,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(105), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(105), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(105), 1); diff --git a/test/core/end2end/tests/write_buffering_at_end.cc b/test/core/end2end/tests/write_buffering_at_end.cc index fffb0293a1..bd046ef9cc 100644 --- a/test/core/end2end/tests/write_buffering_at_end.cc +++ b/test/core/end2end/tests/write_buffering_at_end.cc @@ -125,7 +125,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(1), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -135,7 +136,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(2), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); GPR_ASSERT(GRPC_CALL_OK == grpc_server_request_call( @@ -151,7 +153,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->data.send_message.send_message = request_payload; op->flags = GRPC_WRITE_BUFFER_HINT; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(3), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); memset(ops, 0, sizeof(ops)); @@ -159,7 +162,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(102), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); /* recv message should not succeed yet - it's buffered at the client still */ @@ -168,7 +172,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_RECV_MESSAGE; op->data.recv_message.recv_message = &request_payload_recv1; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(103), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(2), true); @@ -181,7 +186,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op = ops; op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); /* now the first send should match up with the first recv */ @@ -195,7 +201,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->op = GRPC_OP_RECV_MESSAGE; op->data.recv_message.recv_message = &request_payload_recv2; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(104), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(104), true); @@ -210,7 +217,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), nullptr); + error = grpc_call_start_batch(c, ops, static_cast<size_t>(op - ops), tag(4), + nullptr); memset(ops, 0, sizeof(ops)); op = ops; @@ -227,7 +235,8 @@ static void test_invoke_request_with_payload(grpc_end2end_test_config config) { op->flags = 0; op->reserved = nullptr; op++; - error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(105), nullptr); + error = grpc_call_start_batch(s, ops, static_cast<size_t>(op - ops), tag(105), + nullptr); GPR_ASSERT(GRPC_CALL_OK == error); CQ_EXPECT_COMPLETION(cqv, tag(105), 1); |