airflow-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [airflow] kaxil commented on a change in pull request #6396: [AIRFLOW-5726] Delete table as file name in RedshiftToS3Transfer
Date Mon, 25 Nov 2019 21:07:18 GMT
kaxil commented on a change in pull request #6396: [AIRFLOW-5726] Delete table as file name
in RedshiftToS3Transfer
URL: https://github.com/apache/airflow/pull/6396#discussion_r350422465
 
 

 ##########
 File path: tests/operators/test_redshift_to_s3_operator.py
 ##########
 @@ -31,7 +32,11 @@ class TestRedshiftToS3Transfer(unittest.TestCase):
 
     @mock.patch("boto3.session.Session")
     @mock.patch("airflow.hooks.postgres_hook.PostgresHook.run")
-    def test_execute(self, mock_run, mock_session):
+    @parameterized.expand([
 
 Review comment:
   It should be the following:
   
   ```
   	@parameterized.expand([
   	       [True, "key/table_"],
   	        [False, "key"],
   	    ])
   	@mock.patch("boto3.session.Session")
   	@mock.patch("airflow.hooks.postgres_hook.PostgresHook.run")
   	def test_execute(self, table_as_file_name, expected_s3_key, mock_run, mock_session,):
   ```

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message