Assert with public API instead of private API

pull/22452/head
Lidi Zheng 5 years ago
parent 18f36bb301
commit 5cd773731d
  1. 2
      src/python/grpcio_tests/tests_aio/unit/call_test.py

@ -209,7 +209,7 @@ class TestUnaryUnaryCall(_MulticallableTestMixin, AioTestBase):
grpc.access_token_call_credentials("def"),
)
with self.assertRaisesRegex(
grpc._cygrpc.UsageError,
aio.UsageError,
"Call credentials are only valid on secure channels"):
self._stub.UnaryCall(messages_pb2.SimpleRequest(),
credentials=call_credentials)

Loading…
Cancel
Save