ephraimbuddy commented on a change in pull request #16768:
URL: https://github.com/apache/airflow/pull/16768#discussion_r665904177



##########
File path: tests/dag_processing/test_processor.py
##########
@@ -643,6 +643,30 @@ def test_execute_on_failure_callbacks(self, 
mock_ti_handle_failure):
                 test_mode=conf.getboolean('core', 'unit_test_mode'),
             )
 
+    def test_failure_callbacks_should_not_drop_hostname(self):
+        dagbag = DagBag(dag_folder="/dev/null", include_examples=True, 
read_dags_from_db=False)
+        dag_file_processor = DagFileProcessor(dag_ids=[], log=mock.MagicMock())
+        dag_file_processor.UNIT_TEST_MODE = False
+
+        with create_session() as session:
+            session.query(TaskInstance).delete()

Review comment:
       ```suggestion
   ```
   We have `clear_db_runs` in the setup method which clears TaskInstance as 
well, so we don't need this




-- 
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: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to