diff options
author | Mehrdad Afshari <mmx@google.com> | 2017-05-27 14:27:52 -0700 |
---|---|---|
committer | Mehrdad Afshari <mehrdada@users.noreply.github.com> | 2017-06-13 14:14:07 -0700 |
commit | 8fd84cfa07a7f33766a05e3343132a6222e5aa32 (patch) | |
tree | c3e286c5de105527d70ebb273501fd614c7321b5 /src/python/grpcio_tests/tests | |
parent | 0897518ad7ca84c7425bff51e3f5b08f80b21ed7 (diff) |
Update python reflection tests to cover the higher level API
Diffstat (limited to 'src/python/grpcio_tests/tests')
-rw-r--r-- | src/python/grpcio_tests/tests/reflection/_reflection_servicer_test.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/python/grpcio_tests/tests/reflection/_reflection_servicer_test.py b/src/python/grpcio_tests/tests/reflection/_reflection_servicer_test.py index e4536db38b..299ce75e79 100644 --- a/src/python/grpcio_tests/tests/reflection/_reflection_servicer_test.py +++ b/src/python/grpcio_tests/tests/reflection/_reflection_servicer_test.py @@ -25,8 +25,6 @@ from google.protobuf import descriptor_pool from google.protobuf import descriptor_pb2 from src.proto.grpc.testing import empty_pb2 -#empty2_pb2 is imported for import-consequent side-effects. -from src.proto.grpc.testing.proto2 import empty2_pb2 # pylint: disable=unused-import from src.proto.grpc.testing.proto2 import empty2_extensions_pb2 from tests.unit.framework.common import test_constants @@ -48,12 +46,10 @@ def _file_descriptor_to_proto(descriptor): class ReflectionServicerTest(unittest.TestCase): def setUp(self): - servicer = reflection.ReflectionServicer(service_names=_SERVICE_NAMES) server_pool = logging_pool.pool(test_constants.THREAD_CONCURRENCY) self._server = grpc.server(server_pool) + reflection.enable_server_reflection(_SERVICE_NAMES, self._server) port = self._server.add_insecure_port('[::]:0') - reflection_pb2_grpc.add_ServerReflectionServicer_to_server(servicer, - self._server) self._server.start() channel = grpc.insecure_channel('localhost:%d' % port) |