XD-DENG commented on a change in pull request #12667:
URL: https://github.com/apache/airflow/pull/12667#discussion_r531793047



##########
File path: tests/jobs/test_scheduler_job.py
##########
@@ -567,13 +567,15 @@ def test_process_task_instances_depends_on_past(self, 
state, start_date, end_dat
                 ti.start_date = start_date
                 ti.end_date = end_date
 
-        ti_to_schedule = []
+        ti_to_schedule = Mock()
         scheduler_job._process_task_instances(dag, 
task_instances_list=ti_to_schedule)
 
-        assert ti_to_schedule == [
-            (dag.dag_id, dag_task1.task_id, DEFAULT_DATE, TRY_NUMBER),
-            (dag.dag_id, dag_task2.task_id, DEFAULT_DATE, TRY_NUMBER),
-        ]
+        ti_to_schedule.append.assert_called_with(

Review comment:
       Makes sense, and the length can be asserted too in this way. Why not.
   
   Re-pushed.




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