From 762cde4d24d8cb037ce37ab020c51b0082502e88 Mon Sep 17 00:00:00 2001 From: AJ Heller Date: Mon, 7 Mar 2022 08:52:30 -0800 Subject: [PATCH] Delete end2end nosec tests (#28946) * rm nosec tests (TODO: identify coverage differences) * grpc::load_reporter * delete unused nosec test files & config * trigger build * re-delete nosec test file (snuck in with a merge) * revert TODO deletion --- .gitattributes | 1 - CMakeLists.txt | 143 ---- build_autogenerated.yaml | 119 --- grpc.gyp | 111 --- .../end2end/end2end_nosec_tests.cc.template | 4 - test/core/end2end/BUILD | 4 +- test/core/end2end/end2end_nosec_tests.cc | 773 ------------------ test/core/end2end/gen_build_yaml.py | 2 +- test/core/end2end/generate_tests.bzl | 142 ---- .../extract_metadata_from_bazel_xml.py | 9 +- .../clang_format_all_the_things.sh | 2 +- 11 files changed, 5 insertions(+), 1305 deletions(-) delete mode 100644 templates/test/core/end2end/end2end_nosec_tests.cc.template delete mode 100644 test/core/end2end/end2end_nosec_tests.cc diff --git a/.gitattributes b/.gitattributes index af025806dd3..955469a0563 100644 --- a/.gitattributes +++ b/.gitattributes @@ -20,7 +20,6 @@ src/python/grpcio/grpc_core_dependencies.py linguist-generated=true src/ruby/ext/grpc/rb_grpc_imports.generated.h linguist-generated=true src/ruby/ext/grpc/rb_grpc_imports.generated.c linguist-generated=true test/core/end2end/end2end_tests.cc linguist-generated=true -test/core/end2end/end2end_nosec_tests.cc linguist-generated=true test/core/surface/public_headers_must_be_c89.c linguist-generated=true tools/doxygen/Doxyfile.c++.internal linguist-generated=true tools/doxygen/Doxyfile.core.internal linguist-generated=true diff --git a/CMakeLists.txt b/CMakeLists.txt index 0b12007cb79..0080fdd625d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1104,149 +1104,6 @@ endif() if(gRPC_BUILD_TESTS) -add_library(end2end_nosec_tests - test/core/compression/args_utils.cc - test/core/end2end/cq_verifier.cc - test/core/end2end/data/client_certs.cc - test/core/end2end/data/server1_cert.cc - test/core/end2end/data/server1_key.cc - test/core/end2end/data/test_root_cert.cc - test/core/end2end/end2end_nosec_tests.cc - test/core/end2end/end2end_test_utils.cc - test/core/end2end/fixtures/http_proxy_fixture.cc - test/core/end2end/fixtures/local_util.cc - test/core/end2end/fixtures/proxy.cc - test/core/end2end/tests/authority_not_supported.cc - test/core/end2end/tests/bad_hostname.cc - test/core/end2end/tests/bad_ping.cc - test/core/end2end/tests/binary_metadata.cc - test/core/end2end/tests/call_host_override.cc - test/core/end2end/tests/cancel_after_accept.cc - test/core/end2end/tests/cancel_after_client_done.cc - test/core/end2end/tests/cancel_after_invoke.cc - test/core/end2end/tests/cancel_after_round_trip.cc - test/core/end2end/tests/cancel_before_invoke.cc - test/core/end2end/tests/cancel_in_a_vacuum.cc - test/core/end2end/tests/cancel_with_status.cc - test/core/end2end/tests/channelz.cc - test/core/end2end/tests/client_streaming.cc - test/core/end2end/tests/compressed_payload.cc - test/core/end2end/tests/connectivity.cc - test/core/end2end/tests/default_host.cc - test/core/end2end/tests/disappearing_server.cc - test/core/end2end/tests/empty_batch.cc - test/core/end2end/tests/filter_causes_close.cc - test/core/end2end/tests/filter_context.cc - test/core/end2end/tests/filter_init_fails.cc - test/core/end2end/tests/filter_latency.cc - test/core/end2end/tests/filter_status_code.cc - test/core/end2end/tests/graceful_server_shutdown.cc - test/core/end2end/tests/high_initial_seqno.cc - test/core/end2end/tests/hpack_size.cc - test/core/end2end/tests/invoke_large_request.cc - test/core/end2end/tests/keepalive_timeout.cc - test/core/end2end/tests/large_metadata.cc - test/core/end2end/tests/max_concurrent_streams.cc - test/core/end2end/tests/max_connection_age.cc - test/core/end2end/tests/max_connection_idle.cc - test/core/end2end/tests/max_message_length.cc - test/core/end2end/tests/negative_deadline.cc - test/core/end2end/tests/no_error_on_hotpath.cc - test/core/end2end/tests/no_logging.cc - test/core/end2end/tests/no_op.cc - test/core/end2end/tests/payload.cc - test/core/end2end/tests/ping.cc - test/core/end2end/tests/ping_pong_streaming.cc - test/core/end2end/tests/proxy_auth.cc - test/core/end2end/tests/registered_call.cc - test/core/end2end/tests/request_with_flags.cc - test/core/end2end/tests/request_with_payload.cc - test/core/end2end/tests/resource_quota_server.cc - test/core/end2end/tests/retry.cc - test/core/end2end/tests/retry_cancel_after_first_attempt_starts.cc - test/core/end2end/tests/retry_cancel_during_delay.cc - test/core/end2end/tests/retry_cancel_with_multiple_send_batches.cc - test/core/end2end/tests/retry_cancellation.cc - test/core/end2end/tests/retry_disabled.cc - test/core/end2end/tests/retry_exceeds_buffer_size_in_delay.cc - test/core/end2end/tests/retry_exceeds_buffer_size_in_initial_batch.cc - test/core/end2end/tests/retry_exceeds_buffer_size_in_subsequent_batch.cc - test/core/end2end/tests/retry_lb_drop.cc - test/core/end2end/tests/retry_lb_fail.cc - test/core/end2end/tests/retry_non_retriable_status.cc - test/core/end2end/tests/retry_non_retriable_status_before_recv_trailing_metadata_started.cc - test/core/end2end/tests/retry_per_attempt_recv_timeout.cc - test/core/end2end/tests/retry_per_attempt_recv_timeout_on_last_attempt.cc - test/core/end2end/tests/retry_recv_initial_metadata.cc - test/core/end2end/tests/retry_recv_message.cc - test/core/end2end/tests/retry_recv_message_replay.cc - test/core/end2end/tests/retry_recv_trailing_metadata_error.cc - test/core/end2end/tests/retry_send_initial_metadata_refs.cc - test/core/end2end/tests/retry_send_op_fails.cc - test/core/end2end/tests/retry_server_pushback_delay.cc - test/core/end2end/tests/retry_server_pushback_disabled.cc - test/core/end2end/tests/retry_streaming.cc - test/core/end2end/tests/retry_streaming_after_commit.cc - test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc - test/core/end2end/tests/retry_throttled.cc - test/core/end2end/tests/retry_too_many_attempts.cc - test/core/end2end/tests/retry_transparent_goaway.cc - test/core/end2end/tests/retry_transparent_max_concurrent_streams.cc - test/core/end2end/tests/retry_transparent_not_sent_on_wire.cc - test/core/end2end/tests/retry_unref_before_finish.cc - test/core/end2end/tests/retry_unref_before_recv.cc - test/core/end2end/tests/server_finishes_request.cc - test/core/end2end/tests/server_streaming.cc - test/core/end2end/tests/shutdown_finishes_calls.cc - test/core/end2end/tests/shutdown_finishes_tags.cc - test/core/end2end/tests/simple_delayed_request.cc - test/core/end2end/tests/simple_metadata.cc - test/core/end2end/tests/simple_request.cc - test/core/end2end/tests/streaming_error_response.cc - test/core/end2end/tests/trailing_metadata.cc - test/core/end2end/tests/write_buffering.cc - test/core/end2end/tests/write_buffering_at_end.cc - test/core/util/test_lb_policies.cc -) - -set_target_properties(end2end_nosec_tests PROPERTIES - VERSION ${gRPC_CORE_VERSION} - SOVERSION ${gRPC_CORE_SOVERSION} -) - -if(WIN32 AND MSVC) - set_target_properties(end2end_nosec_tests PROPERTIES COMPILE_PDB_NAME "end2end_nosec_tests" - COMPILE_PDB_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" - ) - if(gRPC_INSTALL) - install(FILES ${CMAKE_CURRENT_BINARY_DIR}/end2end_nosec_tests.pdb - DESTINATION ${gRPC_INSTALL_LIBDIR} OPTIONAL - ) - endif() -endif() - -target_include_directories(end2end_nosec_tests - PUBLIC $ $ - PRIVATE - ${CMAKE_CURRENT_SOURCE_DIR} - ${_gRPC_ADDRESS_SORTING_INCLUDE_DIR} - ${_gRPC_RE2_INCLUDE_DIR} - ${_gRPC_SSL_INCLUDE_DIR} - ${_gRPC_UPB_GENERATED_DIR} - ${_gRPC_UPB_GRPC_GENERATED_DIR} - ${_gRPC_UPB_INCLUDE_DIR} - ${_gRPC_XXHASH_INCLUDE_DIR} - ${_gRPC_ZLIB_INCLUDE_DIR} -) -target_link_libraries(end2end_nosec_tests - ${_gRPC_ALLTARGETS_LIBRARIES} - grpc_test_util -) - - -endif() -if(gRPC_BUILD_TESTS) - add_library(end2end_tests src/core/lib/security/authorization/grpc_authorization_policy_provider.cc src/core/lib/security/authorization/rbac_translator.cc diff --git a/build_autogenerated.yaml b/build_autogenerated.yaml index 3486037cef3..1aeb2b1d5b1 100644 --- a/build_autogenerated.yaml +++ b/build_autogenerated.yaml @@ -12,125 +12,6 @@ libs: - third_party/address_sorting/address_sorting_posix.c - third_party/address_sorting/address_sorting_windows.c deps: [] -- name: end2end_nosec_tests - build: private - language: c - public_headers: [] - headers: - - test/core/compression/args_utils.h - - test/core/end2end/cq_verifier.h - - test/core/end2end/data/ssl_test_data.h - - test/core/end2end/end2end_tests.h - - test/core/end2end/fixtures/http_proxy_fixture.h - - test/core/end2end/fixtures/local_util.h - - test/core/end2end/fixtures/proxy.h - - test/core/end2end/tests/cancel_test_helpers.h - - test/core/util/test_lb_policies.h - src: - - test/core/compression/args_utils.cc - - test/core/end2end/cq_verifier.cc - - test/core/end2end/data/client_certs.cc - - test/core/end2end/data/server1_cert.cc - - test/core/end2end/data/server1_key.cc - - test/core/end2end/data/test_root_cert.cc - - test/core/end2end/end2end_nosec_tests.cc - - test/core/end2end/end2end_test_utils.cc - - test/core/end2end/fixtures/http_proxy_fixture.cc - - test/core/end2end/fixtures/local_util.cc - - test/core/end2end/fixtures/proxy.cc - - test/core/end2end/tests/authority_not_supported.cc - - test/core/end2end/tests/bad_hostname.cc - - test/core/end2end/tests/bad_ping.cc - - test/core/end2end/tests/binary_metadata.cc - - test/core/end2end/tests/call_host_override.cc - - test/core/end2end/tests/cancel_after_accept.cc - - test/core/end2end/tests/cancel_after_client_done.cc - - test/core/end2end/tests/cancel_after_invoke.cc - - test/core/end2end/tests/cancel_after_round_trip.cc - - test/core/end2end/tests/cancel_before_invoke.cc - - test/core/end2end/tests/cancel_in_a_vacuum.cc - - test/core/end2end/tests/cancel_with_status.cc - - test/core/end2end/tests/channelz.cc - - test/core/end2end/tests/client_streaming.cc - - test/core/end2end/tests/compressed_payload.cc - - test/core/end2end/tests/connectivity.cc - - test/core/end2end/tests/default_host.cc - - test/core/end2end/tests/disappearing_server.cc - - test/core/end2end/tests/empty_batch.cc - - test/core/end2end/tests/filter_causes_close.cc - - test/core/end2end/tests/filter_context.cc - - test/core/end2end/tests/filter_init_fails.cc - - test/core/end2end/tests/filter_latency.cc - - test/core/end2end/tests/filter_status_code.cc - - test/core/end2end/tests/graceful_server_shutdown.cc - - test/core/end2end/tests/high_initial_seqno.cc - - test/core/end2end/tests/hpack_size.cc - - test/core/end2end/tests/invoke_large_request.cc - - test/core/end2end/tests/keepalive_timeout.cc - - test/core/end2end/tests/large_metadata.cc - - test/core/end2end/tests/max_concurrent_streams.cc - - test/core/end2end/tests/max_connection_age.cc - - test/core/end2end/tests/max_connection_idle.cc - - test/core/end2end/tests/max_message_length.cc - - test/core/end2end/tests/negative_deadline.cc - - test/core/end2end/tests/no_error_on_hotpath.cc - - test/core/end2end/tests/no_logging.cc - - test/core/end2end/tests/no_op.cc - - test/core/end2end/tests/payload.cc - - test/core/end2end/tests/ping.cc - - test/core/end2end/tests/ping_pong_streaming.cc - - test/core/end2end/tests/proxy_auth.cc - - test/core/end2end/tests/registered_call.cc - - test/core/end2end/tests/request_with_flags.cc - - test/core/end2end/tests/request_with_payload.cc - - test/core/end2end/tests/resource_quota_server.cc - - test/core/end2end/tests/retry.cc - - test/core/end2end/tests/retry_cancel_after_first_attempt_starts.cc - - test/core/end2end/tests/retry_cancel_during_delay.cc - - test/core/end2end/tests/retry_cancel_with_multiple_send_batches.cc - - test/core/end2end/tests/retry_cancellation.cc - - test/core/end2end/tests/retry_disabled.cc - - test/core/end2end/tests/retry_exceeds_buffer_size_in_delay.cc - - test/core/end2end/tests/retry_exceeds_buffer_size_in_initial_batch.cc - - test/core/end2end/tests/retry_exceeds_buffer_size_in_subsequent_batch.cc - - test/core/end2end/tests/retry_lb_drop.cc - - test/core/end2end/tests/retry_lb_fail.cc - - test/core/end2end/tests/retry_non_retriable_status.cc - - test/core/end2end/tests/retry_non_retriable_status_before_recv_trailing_metadata_started.cc - - test/core/end2end/tests/retry_per_attempt_recv_timeout.cc - - test/core/end2end/tests/retry_per_attempt_recv_timeout_on_last_attempt.cc - - test/core/end2end/tests/retry_recv_initial_metadata.cc - - test/core/end2end/tests/retry_recv_message.cc - - test/core/end2end/tests/retry_recv_message_replay.cc - - test/core/end2end/tests/retry_recv_trailing_metadata_error.cc - - test/core/end2end/tests/retry_send_initial_metadata_refs.cc - - test/core/end2end/tests/retry_send_op_fails.cc - - test/core/end2end/tests/retry_server_pushback_delay.cc - - test/core/end2end/tests/retry_server_pushback_disabled.cc - - test/core/end2end/tests/retry_streaming.cc - - test/core/end2end/tests/retry_streaming_after_commit.cc - - test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc - - test/core/end2end/tests/retry_throttled.cc - - test/core/end2end/tests/retry_too_many_attempts.cc - - test/core/end2end/tests/retry_transparent_goaway.cc - - test/core/end2end/tests/retry_transparent_max_concurrent_streams.cc - - test/core/end2end/tests/retry_transparent_not_sent_on_wire.cc - - test/core/end2end/tests/retry_unref_before_finish.cc - - test/core/end2end/tests/retry_unref_before_recv.cc - - test/core/end2end/tests/server_finishes_request.cc - - test/core/end2end/tests/server_streaming.cc - - test/core/end2end/tests/shutdown_finishes_calls.cc - - test/core/end2end/tests/shutdown_finishes_tags.cc - - test/core/end2end/tests/simple_delayed_request.cc - - test/core/end2end/tests/simple_metadata.cc - - test/core/end2end/tests/simple_request.cc - - test/core/end2end/tests/streaming_error_response.cc - - test/core/end2end/tests/trailing_metadata.cc - - test/core/end2end/tests/write_buffering.cc - - test/core/end2end/tests/write_buffering_at_end.cc - - test/core/util/test_lb_policies.cc - deps: - - grpc_test_util - name: end2end_tests build: private language: c diff --git a/grpc.gyp b/grpc.gyp index 9a7a36cb898..7ab8b7bd2d0 100644 --- a/grpc.gyp +++ b/grpc.gyp @@ -173,117 +173,6 @@ 'third_party/address_sorting/address_sorting_windows.c', ], }, - { - 'target_name': 'end2end_nosec_tests', - 'type': 'static_library', - 'dependencies': [ - 'grpc_test_util', - ], - 'sources': [ - 'test/core/compression/args_utils.cc', - 'test/core/end2end/cq_verifier.cc', - 'test/core/end2end/data/client_certs.cc', - 'test/core/end2end/data/server1_cert.cc', - 'test/core/end2end/data/server1_key.cc', - 'test/core/end2end/data/test_root_cert.cc', - 'test/core/end2end/end2end_nosec_tests.cc', - 'test/core/end2end/end2end_test_utils.cc', - 'test/core/end2end/fixtures/http_proxy_fixture.cc', - 'test/core/end2end/fixtures/local_util.cc', - 'test/core/end2end/fixtures/proxy.cc', - 'test/core/end2end/tests/authority_not_supported.cc', - 'test/core/end2end/tests/bad_hostname.cc', - 'test/core/end2end/tests/bad_ping.cc', - 'test/core/end2end/tests/binary_metadata.cc', - 'test/core/end2end/tests/call_host_override.cc', - 'test/core/end2end/tests/cancel_after_accept.cc', - 'test/core/end2end/tests/cancel_after_client_done.cc', - 'test/core/end2end/tests/cancel_after_invoke.cc', - 'test/core/end2end/tests/cancel_after_round_trip.cc', - 'test/core/end2end/tests/cancel_before_invoke.cc', - 'test/core/end2end/tests/cancel_in_a_vacuum.cc', - 'test/core/end2end/tests/cancel_with_status.cc', - 'test/core/end2end/tests/channelz.cc', - 'test/core/end2end/tests/client_streaming.cc', - 'test/core/end2end/tests/compressed_payload.cc', - 'test/core/end2end/tests/connectivity.cc', - 'test/core/end2end/tests/default_host.cc', - 'test/core/end2end/tests/disappearing_server.cc', - 'test/core/end2end/tests/empty_batch.cc', - 'test/core/end2end/tests/filter_causes_close.cc', - 'test/core/end2end/tests/filter_context.cc', - 'test/core/end2end/tests/filter_init_fails.cc', - 'test/core/end2end/tests/filter_latency.cc', - 'test/core/end2end/tests/filter_status_code.cc', - 'test/core/end2end/tests/graceful_server_shutdown.cc', - 'test/core/end2end/tests/high_initial_seqno.cc', - 'test/core/end2end/tests/hpack_size.cc', - 'test/core/end2end/tests/invoke_large_request.cc', - 'test/core/end2end/tests/keepalive_timeout.cc', - 'test/core/end2end/tests/large_metadata.cc', - 'test/core/end2end/tests/max_concurrent_streams.cc', - 'test/core/end2end/tests/max_connection_age.cc', - 'test/core/end2end/tests/max_connection_idle.cc', - 'test/core/end2end/tests/max_message_length.cc', - 'test/core/end2end/tests/negative_deadline.cc', - 'test/core/end2end/tests/no_error_on_hotpath.cc', - 'test/core/end2end/tests/no_logging.cc', - 'test/core/end2end/tests/no_op.cc', - 'test/core/end2end/tests/payload.cc', - 'test/core/end2end/tests/ping.cc', - 'test/core/end2end/tests/ping_pong_streaming.cc', - 'test/core/end2end/tests/proxy_auth.cc', - 'test/core/end2end/tests/registered_call.cc', - 'test/core/end2end/tests/request_with_flags.cc', - 'test/core/end2end/tests/request_with_payload.cc', - 'test/core/end2end/tests/resource_quota_server.cc', - 'test/core/end2end/tests/retry.cc', - 'test/core/end2end/tests/retry_cancel_after_first_attempt_starts.cc', - 'test/core/end2end/tests/retry_cancel_during_delay.cc', - 'test/core/end2end/tests/retry_cancel_with_multiple_send_batches.cc', - 'test/core/end2end/tests/retry_cancellation.cc', - 'test/core/end2end/tests/retry_disabled.cc', - 'test/core/end2end/tests/retry_exceeds_buffer_size_in_delay.cc', - 'test/core/end2end/tests/retry_exceeds_buffer_size_in_initial_batch.cc', - 'test/core/end2end/tests/retry_exceeds_buffer_size_in_subsequent_batch.cc', - 'test/core/end2end/tests/retry_lb_drop.cc', - 'test/core/end2end/tests/retry_lb_fail.cc', - 'test/core/end2end/tests/retry_non_retriable_status.cc', - 'test/core/end2end/tests/retry_non_retriable_status_before_recv_trailing_metadata_started.cc', - 'test/core/end2end/tests/retry_per_attempt_recv_timeout.cc', - 'test/core/end2end/tests/retry_per_attempt_recv_timeout_on_last_attempt.cc', - 'test/core/end2end/tests/retry_recv_initial_metadata.cc', - 'test/core/end2end/tests/retry_recv_message.cc', - 'test/core/end2end/tests/retry_recv_message_replay.cc', - 'test/core/end2end/tests/retry_recv_trailing_metadata_error.cc', - 'test/core/end2end/tests/retry_send_initial_metadata_refs.cc', - 'test/core/end2end/tests/retry_send_op_fails.cc', - 'test/core/end2end/tests/retry_server_pushback_delay.cc', - 'test/core/end2end/tests/retry_server_pushback_disabled.cc', - 'test/core/end2end/tests/retry_streaming.cc', - 'test/core/end2end/tests/retry_streaming_after_commit.cc', - 'test/core/end2end/tests/retry_streaming_succeeds_before_replay_finished.cc', - 'test/core/end2end/tests/retry_throttled.cc', - 'test/core/end2end/tests/retry_too_many_attempts.cc', - 'test/core/end2end/tests/retry_transparent_goaway.cc', - 'test/core/end2end/tests/retry_transparent_max_concurrent_streams.cc', - 'test/core/end2end/tests/retry_transparent_not_sent_on_wire.cc', - 'test/core/end2end/tests/retry_unref_before_finish.cc', - 'test/core/end2end/tests/retry_unref_before_recv.cc', - 'test/core/end2end/tests/server_finishes_request.cc', - 'test/core/end2end/tests/server_streaming.cc', - 'test/core/end2end/tests/shutdown_finishes_calls.cc', - 'test/core/end2end/tests/shutdown_finishes_tags.cc', - 'test/core/end2end/tests/simple_delayed_request.cc', - 'test/core/end2end/tests/simple_metadata.cc', - 'test/core/end2end/tests/simple_request.cc', - 'test/core/end2end/tests/streaming_error_response.cc', - 'test/core/end2end/tests/trailing_metadata.cc', - 'test/core/end2end/tests/write_buffering.cc', - 'test/core/end2end/tests/write_buffering_at_end.cc', - 'test/core/util/test_lb_policies.cc', - ], - }, { 'target_name': 'end2end_tests', 'type': 'static_library', diff --git a/templates/test/core/end2end/end2end_nosec_tests.cc.template b/templates/test/core/end2end/end2end_nosec_tests.cc.template deleted file mode 100644 index e0023dd2d91..00000000000 --- a/templates/test/core/end2end/end2end_nosec_tests.cc.template +++ /dev/null @@ -1,4 +0,0 @@ -%YAML 1.2 ---- | - <%namespace file="end2end_defs.include" import="*"/>\ - ${end2end_selector(k for k, v in core_end2end_tests.items() if not v)} diff --git a/test/core/end2end/BUILD b/test/core/end2end/BUILD index 1a2c31966a2..d1dc661df04 100644 --- a/test/core/end2end/BUILD +++ b/test/core/end2end/BUILD @@ -13,7 +13,7 @@ # limitations under the License. load("//bazel:grpc_build_system.bzl", "grpc_cc_library", "grpc_cc_test", "grpc_package") -load(":generate_tests.bzl", "grpc_end2end_nosec_tests", "grpc_end2end_tests") +load(":generate_tests.bzl", "grpc_end2end_tests") licenses(["notice"]) @@ -184,8 +184,6 @@ grpc_cc_test( grpc_end2end_tests() -grpc_end2end_nosec_tests() - grpc_cc_test( name = "h2_ssl_session_reuse_test", srcs = ["h2_ssl_session_reuse_test.cc"], diff --git a/test/core/end2end/end2end_nosec_tests.cc b/test/core/end2end/end2end_nosec_tests.cc deleted file mode 100644 index 10705c53afc..00000000000 --- a/test/core/end2end/end2end_nosec_tests.cc +++ /dev/null @@ -1,773 +0,0 @@ - -/* - * - * Copyright 2015 gRPC authors. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - -/* This file is auto-generated */ - -#include "test/core/end2end/end2end_tests.h" - -#include -#include - -#include - - -static bool g_pre_init_called = false; - -extern void authority_not_supported(grpc_end2end_test_config config); -extern void authority_not_supported_pre_init(void); -extern void bad_hostname(grpc_end2end_test_config config); -extern void bad_hostname_pre_init(void); -extern void bad_ping(grpc_end2end_test_config config); -extern void bad_ping_pre_init(void); -extern void binary_metadata(grpc_end2end_test_config config); -extern void binary_metadata_pre_init(void); -extern void call_host_override(grpc_end2end_test_config config); -extern void call_host_override_pre_init(void); -extern void cancel_after_accept(grpc_end2end_test_config config); -extern void cancel_after_accept_pre_init(void); -extern void cancel_after_client_done(grpc_end2end_test_config config); -extern void cancel_after_client_done_pre_init(void); -extern void cancel_after_invoke(grpc_end2end_test_config config); -extern void cancel_after_invoke_pre_init(void); -extern void cancel_after_round_trip(grpc_end2end_test_config config); -extern void cancel_after_round_trip_pre_init(void); -extern void cancel_before_invoke(grpc_end2end_test_config config); -extern void cancel_before_invoke_pre_init(void); -extern void cancel_in_a_vacuum(grpc_end2end_test_config config); -extern void cancel_in_a_vacuum_pre_init(void); -extern void cancel_with_status(grpc_end2end_test_config config); -extern void cancel_with_status_pre_init(void); -extern void channelz(grpc_end2end_test_config config); -extern void channelz_pre_init(void); -extern void client_streaming(grpc_end2end_test_config config); -extern void client_streaming_pre_init(void); -extern void compressed_payload(grpc_end2end_test_config config); -extern void compressed_payload_pre_init(void); -extern void connectivity(grpc_end2end_test_config config); -extern void connectivity_pre_init(void); -extern void default_host(grpc_end2end_test_config config); -extern void default_host_pre_init(void); -extern void disappearing_server(grpc_end2end_test_config config); -extern void disappearing_server_pre_init(void); -extern void empty_batch(grpc_end2end_test_config config); -extern void empty_batch_pre_init(void); -extern void filter_causes_close(grpc_end2end_test_config config); -extern void filter_causes_close_pre_init(void); -extern void filter_context(grpc_end2end_test_config config); -extern void filter_context_pre_init(void); -extern void filter_init_fails(grpc_end2end_test_config config); -extern void filter_init_fails_pre_init(void); -extern void filter_latency(grpc_end2end_test_config config); -extern void filter_latency_pre_init(void); -extern void filter_status_code(grpc_end2end_test_config config); -extern void filter_status_code_pre_init(void); -extern void graceful_server_shutdown(grpc_end2end_test_config config); -extern void graceful_server_shutdown_pre_init(void); -extern void high_initial_seqno(grpc_end2end_test_config config); -extern void high_initial_seqno_pre_init(void); -extern void hpack_size(grpc_end2end_test_config config); -extern void hpack_size_pre_init(void); -extern void invoke_large_request(grpc_end2end_test_config config); -extern void invoke_large_request_pre_init(void); -extern void keepalive_timeout(grpc_end2end_test_config config); -extern void keepalive_timeout_pre_init(void); -extern void large_metadata(grpc_end2end_test_config config); -extern void large_metadata_pre_init(void); -extern void max_concurrent_streams(grpc_end2end_test_config config); -extern void max_concurrent_streams_pre_init(void); -extern void max_connection_age(grpc_end2end_test_config config); -extern void max_connection_age_pre_init(void); -extern void max_connection_idle(grpc_end2end_test_config config); -extern void max_connection_idle_pre_init(void); -extern void max_message_length(grpc_end2end_test_config config); -extern void max_message_length_pre_init(void); -extern void negative_deadline(grpc_end2end_test_config config); -extern void negative_deadline_pre_init(void); -extern void no_error_on_hotpath(grpc_end2end_test_config config); -extern void no_error_on_hotpath_pre_init(void); -extern void no_logging(grpc_end2end_test_config config); -extern void no_logging_pre_init(void); -extern void no_op(grpc_end2end_test_config config); -extern void no_op_pre_init(void); -extern void payload(grpc_end2end_test_config config); -extern void payload_pre_init(void); -extern void ping(grpc_end2end_test_config config); -extern void ping_pre_init(void); -extern void ping_pong_streaming(grpc_end2end_test_config config); -extern void ping_pong_streaming_pre_init(void); -extern void proxy_auth(grpc_end2end_test_config config); -extern void proxy_auth_pre_init(void); -extern void registered_call(grpc_end2end_test_config config); -extern void registered_call_pre_init(void); -extern void request_with_flags(grpc_end2end_test_config config); -extern void request_with_flags_pre_init(void); -extern void request_with_payload(grpc_end2end_test_config config); -extern void request_with_payload_pre_init(void); -extern void resource_quota_server(grpc_end2end_test_config config); -extern void resource_quota_server_pre_init(void); -extern void retry(grpc_end2end_test_config config); -extern void retry_pre_init(void); -extern void retry_cancel_after_first_attempt_starts(grpc_end2end_test_config config); -extern void retry_cancel_after_first_attempt_starts_pre_init(void); -extern void retry_cancel_during_delay(grpc_end2end_test_config config); -extern void retry_cancel_during_delay_pre_init(void); -extern void retry_cancel_with_multiple_send_batches(grpc_end2end_test_config config); -extern void retry_cancel_with_multiple_send_batches_pre_init(void); -extern void retry_cancellation(grpc_end2end_test_config config); -extern void retry_cancellation_pre_init(void); -extern void retry_disabled(grpc_end2end_test_config config); -extern void retry_disabled_pre_init(void); -extern void retry_exceeds_buffer_size_in_delay(grpc_end2end_test_config config); -extern void retry_exceeds_buffer_size_in_delay_pre_init(void); -extern void retry_exceeds_buffer_size_in_initial_batch(grpc_end2end_test_config config); -extern void retry_exceeds_buffer_size_in_initial_batch_pre_init(void); -extern void retry_exceeds_buffer_size_in_subsequent_batch(grpc_end2end_test_config config); -extern void retry_exceeds_buffer_size_in_subsequent_batch_pre_init(void); -extern void retry_lb_drop(grpc_end2end_test_config config); -extern void retry_lb_drop_pre_init(void); -extern void retry_lb_fail(grpc_end2end_test_config config); -extern void retry_lb_fail_pre_init(void); -extern void retry_non_retriable_status(grpc_end2end_test_config config); -extern void retry_non_retriable_status_pre_init(void); -extern void retry_non_retriable_status_before_recv_trailing_metadata_started(grpc_end2end_test_config config); -extern void retry_non_retriable_status_before_recv_trailing_metadata_started_pre_init(void); -extern void retry_per_attempt_recv_timeout(grpc_end2end_test_config config); -extern void retry_per_attempt_recv_timeout_pre_init(void); -extern void retry_per_attempt_recv_timeout_on_last_attempt(grpc_end2end_test_config config); -extern void retry_per_attempt_recv_timeout_on_last_attempt_pre_init(void); -extern void retry_recv_initial_metadata(grpc_end2end_test_config config); -extern void retry_recv_initial_metadata_pre_init(void); -extern void retry_recv_message(grpc_end2end_test_config config); -extern void retry_recv_message_pre_init(void); -extern void retry_recv_message_replay(grpc_end2end_test_config config); -extern void retry_recv_message_replay_pre_init(void); -extern void retry_recv_trailing_metadata_error(grpc_end2end_test_config config); -extern void retry_recv_trailing_metadata_error_pre_init(void); -extern void retry_send_initial_metadata_refs(grpc_end2end_test_config config); -extern void retry_send_initial_metadata_refs_pre_init(void); -extern void retry_send_op_fails(grpc_end2end_test_config config); -extern void retry_send_op_fails_pre_init(void); -extern void retry_server_pushback_delay(grpc_end2end_test_config config); -extern void retry_server_pushback_delay_pre_init(void); -extern void retry_server_pushback_disabled(grpc_end2end_test_config config); -extern void retry_server_pushback_disabled_pre_init(void); -extern void retry_streaming(grpc_end2end_test_config config); -extern void retry_streaming_pre_init(void); -extern void retry_streaming_after_commit(grpc_end2end_test_config config); -extern void retry_streaming_after_commit_pre_init(void); -extern void retry_streaming_succeeds_before_replay_finished(grpc_end2end_test_config config); -extern void retry_streaming_succeeds_before_replay_finished_pre_init(void); -extern void retry_throttled(grpc_end2end_test_config config); -extern void retry_throttled_pre_init(void); -extern void retry_too_many_attempts(grpc_end2end_test_config config); -extern void retry_too_many_attempts_pre_init(void); -extern void retry_transparent_goaway(grpc_end2end_test_config config); -extern void retry_transparent_goaway_pre_init(void); -extern void retry_transparent_max_concurrent_streams(grpc_end2end_test_config config); -extern void retry_transparent_max_concurrent_streams_pre_init(void); -extern void retry_transparent_not_sent_on_wire(grpc_end2end_test_config config); -extern void retry_transparent_not_sent_on_wire_pre_init(void); -extern void retry_unref_before_finish(grpc_end2end_test_config config); -extern void retry_unref_before_finish_pre_init(void); -extern void retry_unref_before_recv(grpc_end2end_test_config config); -extern void retry_unref_before_recv_pre_init(void); -extern void server_finishes_request(grpc_end2end_test_config config); -extern void server_finishes_request_pre_init(void); -extern void server_streaming(grpc_end2end_test_config config); -extern void server_streaming_pre_init(void); -extern void shutdown_finishes_calls(grpc_end2end_test_config config); -extern void shutdown_finishes_calls_pre_init(void); -extern void shutdown_finishes_tags(grpc_end2end_test_config config); -extern void shutdown_finishes_tags_pre_init(void); -extern void simple_delayed_request(grpc_end2end_test_config config); -extern void simple_delayed_request_pre_init(void); -extern void simple_metadata(grpc_end2end_test_config config); -extern void simple_metadata_pre_init(void); -extern void simple_request(grpc_end2end_test_config config); -extern void simple_request_pre_init(void); -extern void streaming_error_response(grpc_end2end_test_config config); -extern void streaming_error_response_pre_init(void); -extern void trailing_metadata(grpc_end2end_test_config config); -extern void trailing_metadata_pre_init(void); -extern void write_buffering(grpc_end2end_test_config config); -extern void write_buffering_pre_init(void); -extern void write_buffering_at_end(grpc_end2end_test_config config); -extern void write_buffering_at_end_pre_init(void); - -void grpc_end2end_tests_pre_init(void) { - GPR_ASSERT(!g_pre_init_called); - g_pre_init_called = true; - authority_not_supported_pre_init(); - bad_hostname_pre_init(); - bad_ping_pre_init(); - binary_metadata_pre_init(); - call_host_override_pre_init(); - cancel_after_accept_pre_init(); - cancel_after_client_done_pre_init(); - cancel_after_invoke_pre_init(); - cancel_after_round_trip_pre_init(); - cancel_before_invoke_pre_init(); - cancel_in_a_vacuum_pre_init(); - cancel_with_status_pre_init(); - channelz_pre_init(); - client_streaming_pre_init(); - compressed_payload_pre_init(); - connectivity_pre_init(); - default_host_pre_init(); - disappearing_server_pre_init(); - empty_batch_pre_init(); - filter_causes_close_pre_init(); - filter_context_pre_init(); - filter_init_fails_pre_init(); - filter_latency_pre_init(); - filter_status_code_pre_init(); - graceful_server_shutdown_pre_init(); - high_initial_seqno_pre_init(); - hpack_size_pre_init(); - invoke_large_request_pre_init(); - keepalive_timeout_pre_init(); - large_metadata_pre_init(); - max_concurrent_streams_pre_init(); - max_connection_age_pre_init(); - max_connection_idle_pre_init(); - max_message_length_pre_init(); - negative_deadline_pre_init(); - no_error_on_hotpath_pre_init(); - no_logging_pre_init(); - no_op_pre_init(); - payload_pre_init(); - ping_pre_init(); - ping_pong_streaming_pre_init(); - proxy_auth_pre_init(); - registered_call_pre_init(); - request_with_flags_pre_init(); - request_with_payload_pre_init(); - resource_quota_server_pre_init(); - retry_pre_init(); - retry_cancel_after_first_attempt_starts_pre_init(); - retry_cancel_during_delay_pre_init(); - retry_cancel_with_multiple_send_batches_pre_init(); - retry_cancellation_pre_init(); - retry_disabled_pre_init(); - retry_exceeds_buffer_size_in_delay_pre_init(); - retry_exceeds_buffer_size_in_initial_batch_pre_init(); - retry_exceeds_buffer_size_in_subsequent_batch_pre_init(); - retry_lb_drop_pre_init(); - retry_lb_fail_pre_init(); - retry_non_retriable_status_pre_init(); - retry_non_retriable_status_before_recv_trailing_metadata_started_pre_init(); - retry_per_attempt_recv_timeout_pre_init(); - retry_per_attempt_recv_timeout_on_last_attempt_pre_init(); - retry_recv_initial_metadata_pre_init(); - retry_recv_message_pre_init(); - retry_recv_message_replay_pre_init(); - retry_recv_trailing_metadata_error_pre_init(); - retry_send_initial_metadata_refs_pre_init(); - retry_send_op_fails_pre_init(); - retry_server_pushback_delay_pre_init(); - retry_server_pushback_disabled_pre_init(); - retry_streaming_pre_init(); - retry_streaming_after_commit_pre_init(); - retry_streaming_succeeds_before_replay_finished_pre_init(); - retry_throttled_pre_init(); - retry_too_many_attempts_pre_init(); - retry_transparent_goaway_pre_init(); - retry_transparent_max_concurrent_streams_pre_init(); - retry_transparent_not_sent_on_wire_pre_init(); - retry_unref_before_finish_pre_init(); - retry_unref_before_recv_pre_init(); - server_finishes_request_pre_init(); - server_streaming_pre_init(); - shutdown_finishes_calls_pre_init(); - shutdown_finishes_tags_pre_init(); - simple_delayed_request_pre_init(); - simple_metadata_pre_init(); - simple_request_pre_init(); - streaming_error_response_pre_init(); - trailing_metadata_pre_init(); - write_buffering_pre_init(); - write_buffering_at_end_pre_init(); -} - -// NOLINTNEXTLINE(readability-function-size) -void grpc_end2end_tests(int argc, char **argv, - grpc_end2end_test_config config) { - int i; - - GPR_ASSERT(g_pre_init_called); - - if (argc <= 1) { - authority_not_supported(config); - bad_hostname(config); - bad_ping(config); - binary_metadata(config); - call_host_override(config); - cancel_after_accept(config); - cancel_after_client_done(config); - cancel_after_invoke(config); - cancel_after_round_trip(config); - cancel_before_invoke(config); - cancel_in_a_vacuum(config); - cancel_with_status(config); - channelz(config); - client_streaming(config); - compressed_payload(config); - connectivity(config); - default_host(config); - disappearing_server(config); - empty_batch(config); - filter_causes_close(config); - filter_context(config); - filter_init_fails(config); - filter_latency(config); - filter_status_code(config); - graceful_server_shutdown(config); - high_initial_seqno(config); - hpack_size(config); - invoke_large_request(config); - keepalive_timeout(config); - large_metadata(config); - max_concurrent_streams(config); - max_connection_age(config); - max_connection_idle(config); - max_message_length(config); - negative_deadline(config); - no_error_on_hotpath(config); - no_logging(config); - no_op(config); - payload(config); - ping(config); - ping_pong_streaming(config); - proxy_auth(config); - registered_call(config); - request_with_flags(config); - request_with_payload(config); - resource_quota_server(config); - retry(config); - retry_cancel_after_first_attempt_starts(config); - retry_cancel_during_delay(config); - retry_cancel_with_multiple_send_batches(config); - retry_cancellation(config); - retry_disabled(config); - retry_exceeds_buffer_size_in_delay(config); - retry_exceeds_buffer_size_in_initial_batch(config); - retry_exceeds_buffer_size_in_subsequent_batch(config); - retry_lb_drop(config); - retry_lb_fail(config); - retry_non_retriable_status(config); - retry_non_retriable_status_before_recv_trailing_metadata_started(config); - retry_per_attempt_recv_timeout(config); - retry_per_attempt_recv_timeout_on_last_attempt(config); - retry_recv_initial_metadata(config); - retry_recv_message(config); - retry_recv_message_replay(config); - retry_recv_trailing_metadata_error(config); - retry_send_initial_metadata_refs(config); - retry_send_op_fails(config); - retry_server_pushback_delay(config); - retry_server_pushback_disabled(config); - retry_streaming(config); - retry_streaming_after_commit(config); - retry_streaming_succeeds_before_replay_finished(config); - retry_throttled(config); - retry_too_many_attempts(config); - retry_transparent_goaway(config); - retry_transparent_max_concurrent_streams(config); - retry_transparent_not_sent_on_wire(config); - retry_unref_before_finish(config); - retry_unref_before_recv(config); - server_finishes_request(config); - server_streaming(config); - shutdown_finishes_calls(config); - shutdown_finishes_tags(config); - simple_delayed_request(config); - simple_metadata(config); - simple_request(config); - streaming_error_response(config); - trailing_metadata(config); - write_buffering(config); - write_buffering_at_end(config); - return; - } - - for (i = 1; i < argc; i++) { - if (0 == strcmp("authority_not_supported", argv[i])) { - authority_not_supported(config); - continue; - } - if (0 == strcmp("bad_hostname", argv[i])) { - bad_hostname(config); - continue; - } - if (0 == strcmp("bad_ping", argv[i])) { - bad_ping(config); - continue; - } - if (0 == strcmp("binary_metadata", argv[i])) { - binary_metadata(config); - continue; - } - if (0 == strcmp("call_host_override", argv[i])) { - call_host_override(config); - continue; - } - if (0 == strcmp("cancel_after_accept", argv[i])) { - cancel_after_accept(config); - continue; - } - if (0 == strcmp("cancel_after_client_done", argv[i])) { - cancel_after_client_done(config); - continue; - } - if (0 == strcmp("cancel_after_invoke", argv[i])) { - cancel_after_invoke(config); - continue; - } - if (0 == strcmp("cancel_after_round_trip", argv[i])) { - cancel_after_round_trip(config); - continue; - } - if (0 == strcmp("cancel_before_invoke", argv[i])) { - cancel_before_invoke(config); - continue; - } - if (0 == strcmp("cancel_in_a_vacuum", argv[i])) { - cancel_in_a_vacuum(config); - continue; - } - if (0 == strcmp("cancel_with_status", argv[i])) { - cancel_with_status(config); - continue; - } - if (0 == strcmp("channelz", argv[i])) { - channelz(config); - continue; - } - if (0 == strcmp("client_streaming", argv[i])) { - client_streaming(config); - continue; - } - if (0 == strcmp("compressed_payload", argv[i])) { - compressed_payload(config); - continue; - } - if (0 == strcmp("connectivity", argv[i])) { - connectivity(config); - continue; - } - if (0 == strcmp("default_host", argv[i])) { - default_host(config); - continue; - } - if (0 == strcmp("disappearing_server", argv[i])) { - disappearing_server(config); - continue; - } - if (0 == strcmp("empty_batch", argv[i])) { - empty_batch(config); - continue; - } - if (0 == strcmp("filter_causes_close", argv[i])) { - filter_causes_close(config); - continue; - } - if (0 == strcmp("filter_context", argv[i])) { - filter_context(config); - continue; - } - if (0 == strcmp("filter_init_fails", argv[i])) { - filter_init_fails(config); - continue; - } - if (0 == strcmp("filter_latency", argv[i])) { - filter_latency(config); - continue; - } - if (0 == strcmp("filter_status_code", argv[i])) { - filter_status_code(config); - continue; - } - if (0 == strcmp("graceful_server_shutdown", argv[i])) { - graceful_server_shutdown(config); - continue; - } - if (0 == strcmp("high_initial_seqno", argv[i])) { - high_initial_seqno(config); - continue; - } - if (0 == strcmp("hpack_size", argv[i])) { - hpack_size(config); - continue; - } - if (0 == strcmp("invoke_large_request", argv[i])) { - invoke_large_request(config); - continue; - } - if (0 == strcmp("keepalive_timeout", argv[i])) { - keepalive_timeout(config); - continue; - } - if (0 == strcmp("large_metadata", argv[i])) { - large_metadata(config); - continue; - } - if (0 == strcmp("max_concurrent_streams", argv[i])) { - max_concurrent_streams(config); - continue; - } - if (0 == strcmp("max_connection_age", argv[i])) { - max_connection_age(config); - continue; - } - if (0 == strcmp("max_connection_idle", argv[i])) { - max_connection_idle(config); - continue; - } - if (0 == strcmp("max_message_length", argv[i])) { - max_message_length(config); - continue; - } - if (0 == strcmp("negative_deadline", argv[i])) { - negative_deadline(config); - continue; - } - if (0 == strcmp("no_error_on_hotpath", argv[i])) { - no_error_on_hotpath(config); - continue; - } - if (0 == strcmp("no_logging", argv[i])) { - no_logging(config); - continue; - } - if (0 == strcmp("no_op", argv[i])) { - no_op(config); - continue; - } - if (0 == strcmp("payload", argv[i])) { - payload(config); - continue; - } - if (0 == strcmp("ping", argv[i])) { - ping(config); - continue; - } - if (0 == strcmp("ping_pong_streaming", argv[i])) { - ping_pong_streaming(config); - continue; - } - if (0 == strcmp("proxy_auth", argv[i])) { - proxy_auth(config); - continue; - } - if (0 == strcmp("registered_call", argv[i])) { - registered_call(config); - continue; - } - if (0 == strcmp("request_with_flags", argv[i])) { - request_with_flags(config); - continue; - } - if (0 == strcmp("request_with_payload", argv[i])) { - request_with_payload(config); - continue; - } - if (0 == strcmp("resource_quota_server", argv[i])) { - resource_quota_server(config); - continue; - } - if (0 == strcmp("retry", argv[i])) { - retry(config); - continue; - } - if (0 == strcmp("retry_cancel_after_first_attempt_starts", argv[i])) { - retry_cancel_after_first_attempt_starts(config); - continue; - } - if (0 == strcmp("retry_cancel_during_delay", argv[i])) { - retry_cancel_during_delay(config); - continue; - } - if (0 == strcmp("retry_cancel_with_multiple_send_batches", argv[i])) { - retry_cancel_with_multiple_send_batches(config); - continue; - } - if (0 == strcmp("retry_cancellation", argv[i])) { - retry_cancellation(config); - continue; - } - if (0 == strcmp("retry_disabled", argv[i])) { - retry_disabled(config); - continue; - } - if (0 == strcmp("retry_exceeds_buffer_size_in_delay", argv[i])) { - retry_exceeds_buffer_size_in_delay(config); - continue; - } - if (0 == strcmp("retry_exceeds_buffer_size_in_initial_batch", argv[i])) { - retry_exceeds_buffer_size_in_initial_batch(config); - continue; - } - if (0 == strcmp("retry_exceeds_buffer_size_in_subsequent_batch", argv[i])) { - retry_exceeds_buffer_size_in_subsequent_batch(config); - continue; - } - if (0 == strcmp("retry_lb_drop", argv[i])) { - retry_lb_drop(config); - continue; - } - if (0 == strcmp("retry_lb_fail", argv[i])) { - retry_lb_fail(config); - continue; - } - if (0 == strcmp("retry_non_retriable_status", argv[i])) { - retry_non_retriable_status(config); - continue; - } - if (0 == strcmp("retry_non_retriable_status_before_recv_trailing_metadata_started", argv[i])) { - retry_non_retriable_status_before_recv_trailing_metadata_started(config); - continue; - } - if (0 == strcmp("retry_per_attempt_recv_timeout", argv[i])) { - retry_per_attempt_recv_timeout(config); - continue; - } - if (0 == strcmp("retry_per_attempt_recv_timeout_on_last_attempt", argv[i])) { - retry_per_attempt_recv_timeout_on_last_attempt(config); - continue; - } - if (0 == strcmp("retry_recv_initial_metadata", argv[i])) { - retry_recv_initial_metadata(config); - continue; - } - if (0 == strcmp("retry_recv_message", argv[i])) { - retry_recv_message(config); - continue; - } - if (0 == strcmp("retry_recv_message_replay", argv[i])) { - retry_recv_message_replay(config); - continue; - } - if (0 == strcmp("retry_recv_trailing_metadata_error", argv[i])) { - retry_recv_trailing_metadata_error(config); - continue; - } - if (0 == strcmp("retry_send_initial_metadata_refs", argv[i])) { - retry_send_initial_metadata_refs(config); - continue; - } - if (0 == strcmp("retry_send_op_fails", argv[i])) { - retry_send_op_fails(config); - continue; - } - if (0 == strcmp("retry_server_pushback_delay", argv[i])) { - retry_server_pushback_delay(config); - continue; - } - if (0 == strcmp("retry_server_pushback_disabled", argv[i])) { - retry_server_pushback_disabled(config); - continue; - } - if (0 == strcmp("retry_streaming", argv[i])) { - retry_streaming(config); - continue; - } - if (0 == strcmp("retry_streaming_after_commit", argv[i])) { - retry_streaming_after_commit(config); - continue; - } - if (0 == strcmp("retry_streaming_succeeds_before_replay_finished", argv[i])) { - retry_streaming_succeeds_before_replay_finished(config); - continue; - } - if (0 == strcmp("retry_throttled", argv[i])) { - retry_throttled(config); - continue; - } - if (0 == strcmp("retry_too_many_attempts", argv[i])) { - retry_too_many_attempts(config); - continue; - } - if (0 == strcmp("retry_transparent_goaway", argv[i])) { - retry_transparent_goaway(config); - continue; - } - if (0 == strcmp("retry_transparent_max_concurrent_streams", argv[i])) { - retry_transparent_max_concurrent_streams(config); - continue; - } - if (0 == strcmp("retry_transparent_not_sent_on_wire", argv[i])) { - retry_transparent_not_sent_on_wire(config); - continue; - } - if (0 == strcmp("retry_unref_before_finish", argv[i])) { - retry_unref_before_finish(config); - continue; - } - if (0 == strcmp("retry_unref_before_recv", argv[i])) { - retry_unref_before_recv(config); - continue; - } - if (0 == strcmp("server_finishes_request", argv[i])) { - server_finishes_request(config); - continue; - } - if (0 == strcmp("server_streaming", argv[i])) { - server_streaming(config); - continue; - } - if (0 == strcmp("shutdown_finishes_calls", argv[i])) { - shutdown_finishes_calls(config); - continue; - } - if (0 == strcmp("shutdown_finishes_tags", argv[i])) { - shutdown_finishes_tags(config); - continue; - } - if (0 == strcmp("simple_delayed_request", argv[i])) { - simple_delayed_request(config); - continue; - } - if (0 == strcmp("simple_metadata", argv[i])) { - simple_metadata(config); - continue; - } - if (0 == strcmp("simple_request", argv[i])) { - simple_request(config); - continue; - } - if (0 == strcmp("streaming_error_response", argv[i])) { - streaming_error_response(config); - continue; - } - if (0 == strcmp("trailing_metadata", argv[i])) { - trailing_metadata(config); - continue; - } - if (0 == strcmp("write_buffering", argv[i])) { - write_buffering(config); - continue; - } - if (0 == strcmp("write_buffering_at_end", argv[i])) { - write_buffering_at_end(config); - continue; - } - gpr_log(GPR_DEBUG, "not a test: '%s'", argv[i]); - abort(); - } -} diff --git a/test/core/end2end/gen_build_yaml.py b/test/core/end2end/gen_build_yaml.py index 144b2ce5d4e..4d004b96b91 100755 --- a/test/core/end2end/gen_build_yaml.py +++ b/test/core/end2end/gen_build_yaml.py @@ -42,7 +42,7 @@ exec( def main(): json = { - # needed by end2end_tests.cc.template and end2end_nosec_tests.cc.template + # needed by end2end_tests.cc.template 'core_end2end_tests': dict((t, END2END_TESTS[t]['secure']) for t in END2END_TESTS.keys()) } diff --git a/test/core/end2end/generate_tests.bzl b/test/core/end2end/generate_tests.bzl index 861f87e8410..64827cc3848 100755 --- a/test/core/end2end/generate_tests.bzl +++ b/test/core/end2end/generate_tests.bzl @@ -135,62 +135,6 @@ END2END_FIXTURES = { ), } -# maps fixture name to whether it requires the security library -END2END_NOSEC_FIXTURES = { - "h2_compress": _fixture_options(secure = False), - "h2_census": _fixture_options(secure = False), - # TODO(juanlishen): This is disabled for now, but should be considered to re-enable once we have - # decided how the load reporting service should be enabled. - #'h2_load_reporting': _fixture_options(), - "h2_fakesec": _fixture_options(), - "h2_fd": _fixture_options( - dns_resolver = False, - fullstack = False, - client_channel = False, - secure = False, - _platforms = ["linux", "mac", "posix"], - supports_msvc = False, - ), - "h2_full": _fixture_options(secure = False), - "h2_full+pipe": _fixture_options( - secure = False, - _platforms = ["linux"], - supports_msvc = False, - ), - "h2_full+trace": _fixture_options(secure = False, tracing = True, supports_msvc = False), - "h2_http_proxy": _fixture_options(secure = False, supports_proxy_auth = True), - "h2_proxy": _fixture_options(secure = False, includes_proxy = True), - "h2_sockpair_1byte": _fixture_options( - fullstack = False, - dns_resolver = False, - client_channel = False, - secure = False, - is_1byte = True, - ), - "h2_sockpair": _fixture_options( - fullstack = False, - dns_resolver = False, - client_channel = False, - secure = False, - ), - "h2_sockpair+trace": _fixture_options( - fullstack = False, - dns_resolver = False, - tracing = True, - secure = False, - client_channel = False, - ), - "h2_ssl": _fixture_options(secure = False), - "h2_ssl_cred_reload": _fixture_options(secure = False), - "h2_ssl_proxy": _fixture_options(includes_proxy = True, secure = False), - "h2_uds": _fixture_options( - dns_resolver = False, - _platforms = ["linux", "mac", "posix"], - secure = False, - supports_msvc = False, - ), -} - def _test_options( needs_fullstack = False, needs_dns = False, @@ -515,89 +459,3 @@ def grpc_end2end_tests(): tags = ["no_mac", "no_windows"], flaky = t in fopt.flaky_tests, ) - -# buildifier: disable=unnamed-macro -def grpc_end2end_nosec_tests(): - """Instantiates the gRPC end2end no security tests""" - grpc_cc_library( - name = "end2end_nosec_tests", - srcs = ["end2end_nosec_tests.cc", "end2end_test_utils.cc"] + [ - "tests/%s.cc" % t - for t in sorted(END2END_TESTS.keys()) - if not END2END_TESTS[t].secure - ], - hdrs = [ - "tests/cancel_test_helpers.h", - "end2end_tests.h", - ], - language = "C++", - testonly = 1, - deps = [ - ":cq_verifier", - ":ssl_test_data", - ":http_proxy", - ":proxy", - ":local_util", - "//test/core/util:test_lb_policies", - "//test/core/compression:args_utils", - ], - ) - - for f, fopt in END2END_NOSEC_FIXTURES.items(): - if fopt.secure: - continue - grpc_cc_binary( - name = "%s_nosec_test" % f, - srcs = ["fixtures/%s.cc" % f], - language = "C++", - testonly = 1, - data = [ - "//src/core/tsi/test_creds:ca.pem", - "//src/core/tsi/test_creds:server1.key", - "//src/core/tsi/test_creds:server1.pem", - ], - deps = [ - ":end2end_nosec_tests", - "//test/core/util:grpc_test_util_unsecure", - "//:grpc_unsecure", - "//:gpr", - "//test/core/compression:args_utils", - ], - tags = _platform_support_tags(fopt), - ) - for t, topt in END2END_TESTS.items(): - #print(_compatible(fopt, topt), f, t, fopt, topt) - if not _compatible(fopt, topt): - continue - if topt.secure: - continue - - test_short_name = str(t) if not topt.short_name else topt.short_name - native.sh_test( - name = "%s_nosec_test@%s" % (f, test_short_name), - data = [":%s_nosec_test" % f], - srcs = ["end2end_test.sh"], - args = [ - "$(location %s_nosec_test)" % f, - t, - ], - tags = ["no_linux"] + _platform_support_tags(fopt), - flaky = t in fopt.flaky_tests, - ) - - for poller in POLLERS: - if poller in topt.exclude_pollers: - continue - native.sh_test( - name = "%s_nosec_test@%s@poller=%s" % - (f, test_short_name, poller), - data = [":%s_nosec_test" % f], - srcs = ["end2end_test.sh"], - args = [ - "$(location %s_nosec_test)" % f, - t, - poller, - ], - tags = ["no_mac", "no_windows"], - flaky = t in fopt.flaky_tests, - ) diff --git a/tools/buildgen/extract_metadata_from_bazel_xml.py b/tools/buildgen/extract_metadata_from_bazel_xml.py index 9773ff15773..396f635fb79 100755 --- a/tools/buildgen/extract_metadata_from_bazel_xml.py +++ b/tools/buildgen/extract_metadata_from_bazel_xml.py @@ -229,7 +229,7 @@ def _compute_transitive_metadata( * _COLLAPSED_PUBLIC_HEADERS: the merged public headers; * _COLLAPSED_HEADERS: the merged non-public headers; * _EXCLUDE_DEPS: intermediate targets to exclude when performing collapsing - of sources and dependencies. + of sources and dependencies. For the collapsed_deps, the algorithm improved cases like: @@ -237,7 +237,7 @@ def _compute_transitive_metadata( end2end_tests -> [grpc_test_util, grpc, gpr, address_sorting, upb] grpc_test_util -> [grpc, gpr, address_sorting, upb, ...] grpc -> [gpr, address_sorting, upb, ...] - + The result of the algorithm: end2end_tests -> [grpc_test_util] grpc_test_util -> [grpc] @@ -873,11 +873,6 @@ _BUILD_EXTRA_METADATA = { 'build': 'private', '_RENAME': 'end2end_tests' }, - 'test/core/end2end:end2end_nosec_tests': { - 'language': 'c', - 'build': 'private', - '_RENAME': 'end2end_nosec_tests' - }, # benchmark support libraries 'test/cpp/microbenchmarks:helpers': { diff --git a/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh b/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh index ee626abdd84..5dd18b34740 100755 --- a/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh +++ b/tools/dockerfile/grpc_clang_format/clang_format_all_the_things.sh @@ -32,7 +32,7 @@ for dir in $DIRS do for glob in $GLOB do - files="$files `find ${CLANG_FORMAT_ROOT}/$dir -name $glob -and -not -name '*.generated.*' -and -not -name '*.upb.h' -and -not -name '*.upb.c' -and -not -name '*.upbdefs.h' -and -not -name '*.upbdefs.c' -and -not -name '*.pb.h' -and -not -name '*.pb.c' -and -not -name '*.pb.cc' -and -not -name '*.pbobjc.h' -and -not -name '*.pbobjc.m' -and -not -name '*.pbrpc.h' -and -not -name '*.pbrpc.m' -and -not -name end2end_tests.cc -and -not -name end2end_nosec_tests.cc -and -not -name public_headers_must_be_c89.c -and -not -name grpc_shadow_boringssl.h`" + files="$files `find ${CLANG_FORMAT_ROOT}/$dir -name $glob -and -not -name '*.generated.*' -and -not -name '*.upb.h' -and -not -name '*.upb.c' -and -not -name '*.upbdefs.h' -and -not -name '*.upbdefs.c' -and -not -name '*.pb.h' -and -not -name '*.pb.c' -and -not -name '*.pb.cc' -and -not -name '*.pbobjc.h' -and -not -name '*.pbobjc.m' -and -not -name '*.pbrpc.h' -and -not -name '*.pbrpc.m' -and -not -name end2end_tests.cc -and -not -name public_headers_must_be_c89.c -and -not -name grpc_shadow_boringssl.h`" done done