XD-DENG commented on a change in pull request #12667:
URL: https://github.com/apache/airflow/pull/12667#discussion_r531779764
##########
File path: tests/jobs/test_scheduler_job.py
##########
@@ -516,12 +516,12 @@ def test_process_task_instances_with_task_concurrency(
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 == [
+ ti_to_schedule.append.assert_called_once_with(
(dag.dag_id, dag_task1.task_id, DEFAULT_DATE, TRY_NUMBER),
- ]
+ )
Review comment:
We don't "have to" make change for this line, given for this case we
only have one TI (i.e. one element in the list).
Changing only for consistent testing style/method.
----------------------------------------------------------------
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]