kaxil commented on a change in pull request #15726:
URL: https://github.com/apache/airflow/pull/15726#discussion_r629773272



##########
File path: kubernetes_tests/test_kubernetes_executor.py
##########
@@ -266,3 +266,65 @@ def test_integration_run_dag_with_scheduler_failure(self):
         )
 
         assert self._num_pods_in_namespace('test-namespace') == 0, "failed to 
delete pods in other namespace"
+
+    def test_integration_run_dag_with_running_task_pod_kill(self):

Review comment:
       Can you add comments / docstrings to say what this test is actually 
testing, please

##########
File path: kubernetes_tests/test_kubernetes_executor.py
##########
@@ -266,3 +266,65 @@ def test_integration_run_dag_with_scheduler_failure(self):
         )
 
         assert self._num_pods_in_namespace('test-namespace') == 0, "failed to 
delete pods in other namespace"
+
+    def test_integration_run_dag_with_running_task_pod_kill(self):
+        host = KUBERNETES_HOST_PORT
+        dag_id = 'example_kubernetes_executor_config'
+        pod_name = 'examplekubernetesexecutorconfigstarttask'
+        dag_run_id, execution_date = self.start_dag(dag_id=dag_id, host=host)
+        self._delete_task_pod(pod_name)
+        self.monitor_task(
+            host=host,
+            dag_run_id=dag_run_id,
+            dag_id=dag_id,
+            task_id='start_task',
+            expected_final_state='failed',
+            timeout=300,
+        )
+        self.monitor_task(
+            host=host,
+            dag_run_id=dag_run_id,
+            dag_id=dag_id,
+            task_id='other_namespace_task',
+            expected_final_state='upstream_failed',
+            timeout=300,
+        )
+        self.ensure_dag_expected_state(
+            host=host,
+            execution_date=execution_date,
+            dag_id=dag_id,
+            expected_final_state='failed',
+            timeout=300,
+        )
+        assert self._num_pods_in_namespace('test-namespace') == 0, "failed to 
delete pods in other namespace"
+
+    def test_integration_run_dag_with_container_creating_task_pod_kill(self):

Review comment:
       same: Can you add comments / docstrings to say what this test is 
actually testing, please




-- 
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]


Reply via email to