self, mock_isfile, mock_find_path, mock_might_contain_dag, mock_zipfile
    ):
        """Test dag files are sorted alphabetically"""
        dag_files = ["file_3.py", "file_2.py", "file_4.py", "file_1.py"]
        mock_find_path.return_value = dag_files
        manager = DagFileProcessorManager(
            dag_directory="directory",
            max_runs=1,
            processor_timeout=timedelta(days=365),
            signal_conn=MagicMock(),
            dag_ids=[],
            pickle_dags=False,
            async_mode=True,
        )
        manager.set_file_paths(dag_files)
        assert manager._file_path_queue == collections.deque()
        manager.prepare_file_path_queue()
        assert manager._file_path_queue == collections.deque(
            ["file_1.py", "file_2.py", "file_3.py", "file_4.py"]
        )
    @conf_vars({("scheduler", "file_parsing_sort_mode"): "random_seeded_by_host"})
    @mock.patch("zipfile.is_zipfile", return_value=True)
    @mock.patch("airflow.utils.file.might_contain_dag", return_value=True)
    @mock.patch("airflow.utils.file.find_path_from_directory", return_value=True)
    @mock.patch("airflow.utils.file.os.path.isfile", return_value=True)
    def test_file_paths_in_queue_sorted_random_seeded_by_host(