From 9c537f91f4e0d13970a9f78e3c2b65cf747edfd6 Mon Sep 17 00:00:00 2001 From: Lidi Zheng Date: Tue, 5 May 2020 15:11:16 -0700 Subject: [PATCH] Make pytype happy --- .../tests_aio/channelz/channelz_servicer_test.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/python/grpcio_tests/tests_aio/channelz/channelz_servicer_test.py b/src/python/grpcio_tests/tests_aio/channelz/channelz_servicer_test.py index 8cc0d4d2fcc..d6e9fd42791 100644 --- a/src/python/grpcio_tests/tests_aio/channelz/channelz_servicer_test.py +++ b/src/python/grpcio_tests/tests_aio/channelz/channelz_servicer_test.py @@ -71,6 +71,13 @@ class _GenericHandler(grpc.GenericRpcHandler): class _ChannelServerPair: + def __init__(self): + self.address = '' + self.server = None + self.channel = None + self.server_ref_id = None + self.channel_ref_id = None + async def start(self): # Server will enable channelz service self.server = aio.server(options=_DISABLE_REUSE_PORT + _ENABLE_CHANNELZ) @@ -348,8 +355,7 @@ class ChannelzServicerTest(AioTestBase): socket_id=gsc_resp.subchannel.socket_ref[0].socket_id)) self.assertEqual(gsc_resp.subchannel.data.calls_started, gs_resp.socket.data.streams_started) - self.assertEqual(gsc_resp.subchannel.data.calls_started, - gs_resp.socket.data.streams_succeeded) + self.assertEqual(0, gs_resp.socket.data.streams_failed) # Calls started == messages sent, only valid for unary calls self.assertEqual(gsc_resp.subchannel.data.calls_started, gs_resp.socket.data.messages_sent)