mik-laj commented on a change in pull request #5586: [AIRFLOW-4952] Remove 
unused arguments in tests
URL: https://github.com/apache/airflow/pull/5586#discussion_r303850671
 
 

 ##########
 File path: tests/contrib/hooks/test_grpc_hook.py
 ##########
 @@ -48,21 +48,21 @@ def get_airflow_connection_with_port():
 
 
 class StubClass:
-    def __init__(self, channel):
+    def __init__(self, _):
         pass
 
     def single_call(self, data):
         return data
 
-    def stream_call(self, data):
+    def stream_call(self, data):  # pylint: disable=unused-argument
         return ["streaming", "call"]
 
 
 class TestGrpcHook(unittest.TestCase):
     def setUp(self):
         self.channel_mock = mock.patch('grpc.Channel').start()
 
-    def custom_conn_func(self, connection):
+    def custom_conn_func(self, _):
 
 Review comment:
   I think it's valuable to keep the signature of the function. I think that in 
such cases it was better to use MagicMock, but this is not the purpose of this 
PR. In the future, we can rewrite tests to use MagicMock much more often.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to