code: def populate_dir(root_path):
      """
      Create all directories and files that should be ignored. And set base path.
      """
      # Temp dir name includes an ignored token "not", but it shouldn't matter since it's in the base path.
      test_dir = root_path / "onotole"
      plugin_folder_path = test_dir / "test_ignore"
      plugin_folder_path.mkdir(parents=True)
      for name in ("subdir1", "subdir2", "subdir3"):
          (plugin_folder_path / name).mkdir()
      files_content = [
          ["test_load.py", "#Should not be ignored file"],
          [
              "test_notload.py",
              'raise Exception("This file should have been ignored!")',
          ],
          [".airflowignore", "#ignore test\nnot\nsubdir2"],
          [".airflowignore_glob", "#ignore test\n**/*not*\nsubdir2/"],
          ["subdir1/.airflowignore", "#ignore test\nnone\n_glob"],
          ["subdir1/.airflowignore_glob", "#ignore test\n*none*"],
          ["subdir1/test_load_sub1.py", "#Should not be ignored file"],
          [
              "test_notload_sub.py",
              'raise Exception("This file should have been ignored!")',
          ],
          [
              "subdir1/test_noneload_sub1.py",
              'raise Exception("This file should have been ignored!")',
          ],
          [
              "subdir2/test_shouldignore.py",
              'raise Exception("This file should have been ignored!")',
          ],
          [
              "subdir3/test_notload_sub3.py",
              'raise Exception("This file should have been ignored!")',
          ],
      ]
      for file_path, content in files_content:
          (plugin_folder_path / file_path).write_text(content)
      patch.object(
          settings, "PLUGINS_FOLDER", return_value=plugin_folder_path
      )
      return plugin_folder_path
  
file_path: airflow/tests/plugins/test_plugin_ignore.py
imports: from __future__ import annotations
  from pathlib import Path
  from unittest.mock import patch
  from airflow import settings
  from airflow.utils.file import find_path_from_directory
label_desc: Use image node_id 1 for calling a global function with example usage: populate_dir(root_path) and returns: plugin_folder_path