code: def test_get_test_targets() -> None:
      _TEST_YAML = "flaky_tests: [//python/ray/tests:flaky_test_01]"
  
      with TemporaryDirectory() as tmp:
          with open(os.path.join(tmp, "core.tests.yml"), "w") as f:
              f.write(_TEST_YAML)
  
          test_targets = [
              "//python/ray/tests:good_test_01",
              "//python/ray/tests:good_test_02",
              "//python/ray/tests:good_test_03",
              "//python/ray/tests:flaky_test_01",
          ]
          with mock.patch(
              "subprocess.check_output",
              return_value="\n".join(test_targets).encode("utf-8"),
          ), mock.patch(
              "ci.ray_ci.linux_tester_container.LinuxTesterContainer.install_ray",
              return_value=None,
          ):
              assert set(
                  _get_test_targets(
                      LinuxTesterContainer("core"),
                      "targets",
                      "core",
                      operating_system="linux",
                      yaml_dir=tmp,
                  )
              ) == {
                  "//python/ray/tests:good_test_01",
                  "//python/ray/tests:good_test_02",
                  "//python/ray/tests:good_test_03",
              }
  
              assert _get_test_targets(
                  LinuxTesterContainer("core"),
                  "targets",
                  "core",
                  operating_system="linux",
                  yaml_dir=tmp,
                  get_flaky_tests=True,
              ) == [
                  "//python/ray/tests:flaky_test_01",
              ]
  
file_path: ray/ci/ray_ci/test_tester.py
imports: import os
  import re
  import sys
  from tempfile import TemporaryDirectory
  from unittest import mock
  import pytest
  from ci.ray_ci.linux_tester_container import LinuxTesterContainer
  from ci.ray_ci.windows_tester_container import WindowsTesterContainer
  from ci.ray_ci.tester import _add_default_except_tags, _get_container, _get_all_test_query, _get_test_targets, _get_flaky_test_targets, _get_tag_matcher
label_desc: Use image node_id 3 for calling a global function with example usage: test_get_test_targets() without return types