beobest2 commented on code in PR #38658:
URL: https://github.com/apache/airflow/pull/38658#discussion_r1586861317
##########
tests/providers/amazon/aws/operators/test_emr_containers.py:
##########
@@ -144,6 +144,20 @@ def test_operator_defer(self, mock_submit_job,
mock_check_query_status):
exc.value.trigger, EmrContainerTrigger
), f"{exc.value.trigger} is not a EmrContainerTrigger"
+ @mock.patch.object(EmrContainerHook, "submit_job")
+ @mock.patch.object(
+ EmrContainerHook, "check_query_status",
return_value=EmrContainerHook.INTERMEDIATE_STATES[0]
+ )
+ def test_operator_defer_with_timeout(self, mock_submit_job,
mock_check_query_status):
+ self.emr_container.deferrable = True
+ self.emr_container.max_polling_attempts = 1000
Review Comment:
@o-nikolas The purpose of this PR was to address the issue where setting
this value high would not wait beyond the default of 600. By setting it to
1000, the modification is proven to be implemented. The `poll_interval` is set
to 0 for testing, so it does not increase the time it takes to run the tests.
--
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]