code: def test_topological_sort1():
      dag = DAG(
          "dag",
          start_date=DEFAULT_DATE,
          default_args={"owner": "owner1"},
      )
  
      # A -> B
      # A -> C -> D
      # ordered: B, D, C, A or D, B, C, A or D, C, B, A
      with dag:
          op1 = EmptyOperator(task_id="A")
          op2 = EmptyOperator(task_id="B")
          op3 = EmptyOperator(task_id="C")
          op4 = EmptyOperator(task_id="D")
          [op2, op3] >> op1
          op3 >> op4
  
      topological_list = dag.task_group.topological_sort()
  
      tasks = [op2, op3, op4]
      assert topological_list[0] in tasks
      tasks.remove(topological_list[0])
      assert topological_list[1] in tasks
      tasks.remove(topological_list[1])
      assert topological_list[2] in tasks
      tasks.remove(topological_list[2])
      assert topological_list[3] == op1
  
imports: from __future__ import annotations
  from datetime import timedelta
  import pendulum
  import pytest
  from airflow.decorators import dag, setup, task, task_group, teardown
  from airflow.exceptions import TaskAlreadyInTaskGroup
  from airflow.models.baseoperator import BaseOperator
  from airflow.models.dag import DAG
  from airflow.models.xcom_arg import XComArg
  from airflow.operators.bash import BashOperator
  from airflow.operators.empty import EmptyOperator
  from airflow.operators.python import PythonOperator
  from airflow.utils.dag_edges import dag_edges
  from airflow.utils.task_group import TaskGroup, task_group_to_dict
  from tests.models import DEFAULT_DATE
label_desc: Use image node_id 23 for calling a global function with example usage: test_topological_sort1() without return types