You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2019/01/14 07:48:28 UTC

[GitHub] zingorn commented on a change in pull request #4256: [AIRFLOW-3417] Use the platformVersion only for the FARGATE launch type

zingorn commented on a change in pull request #4256: [AIRFLOW-3417] Use the platformVersion only for the FARGATE launch type
URL: https://github.com/apache/airflow/pull/4256#discussion_r247401771
 
 

 ##########
 File path: tests/contrib/operators/test_ecs_operator.py
 ##########
 @@ -133,6 +134,38 @@ def test_execute_without_failures(self, check_mock, wait_mock):
         self.assertEqual(self.ecs.arn,
                          'arn:aws:ecs:us-east-1:012345678910:task/d8c67b3c-ac87-4ffe-a847-4785bc3a8b55')
 
+    @mock.patch.object(ECSOperator, '_wait_for_task_ended')
+    @mock.patch.object(ECSOperator, '_check_success_task')
+    def test_fargate_run(self, check_mock, wait_mock):
 
 Review comment:
   Then `test_execute_without_failures` need to update somehow so:
   ```
     ecs_operator = ECSOperator(launch_type=launch_type, **self.ecs_operator_args)
     ecs_operator.execute(None)
     ...
     args = {
       'cluster': 'c',
       'launchType': launch_type,
       ...
     }
     if launch_type == 'FARGATE':
       args['platformVersion'] = 'LATEST'
     client_mock.run_task.assert_called_once_with(**args)
   ```
   so I can do this if it dont confusing you

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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