ferruzzi commented on code in PR #23654:
URL: https://github.com/apache/airflow/pull/23654#discussion_r875111136
##########
tests/providers/amazon/aws/hooks/test_s3.py:
##########
@@ -487,12 +487,21 @@ def test_download_file(self, mock_temp_file):
s3_hook.get_key = Mock(return_value=s3_obj)
key = 'test_key'
bucket = 'test_bucket'
-
+
s3_hook.download_file(key=key, bucket_name=bucket)
s3_hook.get_key.assert_called_once_with(key, bucket)
s3_obj.download_fileobj.assert_called_once_with(mock_temp_file)
+ def test_download_file2(self, s3_bucket):
Review Comment:
Please use a more descriptive test/method name. What is this testing that
`test_download_file` doesn't? These are test methods, so you can rename them
to something like `test_download_file_with_filename` and
`test_download_file_with_directory` or something like that, which is much more
useful.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]