# Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
#
# Use of this source code is governed by a BSD-style license
# that can be found in the LICENSE file in the root of the source
# tree. An additional intellectual property rights grant can be found
# in the file PATENTS.  All contributing project authors may
# be found in the AUTHORS file in the root of the source tree.

import("//build/config/ui.gni")
import("../webrtc.gni")
if (is_android) {
  import("//build/config/android/rules.gni")
}

if (!build_with_chromium) {
  group("test") {
    testonly = true

    deps = [
      ":copy_to_file_audio_capturer",
      ":rtp_test_utils",
      ":test_common",
      ":test_renderer",
      ":test_support",
      ":test_video_capturer",
      ":video_test_common",
    ]

    if (rtc_include_tests) {
      deps += [
        ":test_main",
        ":test_support_unittests",
        "pc/e2e",
      ]
    }
  }
}

rtc_library("frame_generator_impl") {
  visibility = [
    ":*",
    "../api:create_frame_generator",
  ]
  testonly = true
  sources = [
    "frame_generator.cc",
    "frame_generator.h",
    "testsupport/ivf_video_frame_generator.cc",
    "testsupport/ivf_video_frame_generator.h",
  ]
  deps = [
    ":frame_utils",
    "../api:frame_generator_api",
    "../api:scoped_refptr",
    "../api:sequence_checker",
    "../api/environment",
    "../api/video:encoded_image",
    "../api/video:video_frame",
    "../api/video:video_frame_i010",
    "../api/video:video_rtp_headers",
    "../api/video_codecs:video_codecs_api",
    "../common_video",
    "../media:media_constants",
    "../modules/video_coding:video_codec_interface",
    "../modules/video_coding:video_coding_utility",
    "../modules/video_coding:webrtc_h264",
    "../modules/video_coding:webrtc_vp8",
    "../modules/video_coding:webrtc_vp9",
    "../modules/video_coding/codecs/av1:dav1d_decoder",
    "../rtc_base:checks",
    "../rtc_base:criticalsection",
    "../rtc_base:logging",
    "../rtc_base:random",
    "../rtc_base:rtc_event",
    "../rtc_base/synchronization:mutex",
    "../rtc_base/system:file_wrapper",
    "../system_wrappers",
    "//third_party/abseil-cpp/absl/strings:string_view",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("y4m_frame_generator") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "testsupport/y4m_frame_generator.cc",
    "testsupport/y4m_frame_generator.h",
  ]
  deps = [
    ":video_test_support",
    "../api:frame_generator_api",
    "../api:scoped_refptr",
    "../api/video:video_frame",
    "../rtc_base:checks",
    "//third_party/abseil-cpp/absl/strings:string_view",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("frame_utils") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "frame_utils.cc",
    "frame_utils.h",
  ]
  deps = [
    "../api:scoped_refptr",
    "../api/video:video_frame",
  ]
}

rtc_library("test_video_capturer") {
  testonly = true
  sources = [
    "test_video_capturer.cc",
    "test_video_capturer.h",
  ]
  deps = [
    "../api:scoped_refptr",
    "../api/video:video_frame",
    "../api/video:video_rtp_headers",
    "../media:video_adapter",
    "../media:video_broadcaster",
    "../rtc_base/synchronization:mutex",
  ]
}

rtc_library("create_frame_generator_capturer") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "create_frame_generator_capturer.cc",
    "create_frame_generator_capturer.h",
  ]
  deps = [
    ":fileutils",
    ":frame_generator_capturer",
    "../api:create_frame_generator",
    "../api:frame_generator_api",
    "../api/task_queue",
    "../api/units:time_delta",
    "../rtc_base:checks",
    "../system_wrappers",
    "//third_party/abseil-cpp/absl/strings",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("frame_generator_capturer") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "frame_generator_capturer.cc",
    "frame_generator_capturer.h",
  ]
  deps = [
    ":test_video_capturer",
    "../api:frame_generator_api",
    "../api/task_queue",
    "../api/units:time_delta",
    "../api/video:video_frame",
    "../api/video:video_rtp_headers",
    "../rtc_base:checks",
    "../rtc_base:logging",
    "../rtc_base:macromagic",
    "../rtc_base/synchronization:mutex",
    "../rtc_base/task_utils:repeating_task",
    "../system_wrappers",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("video_test_common") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "fake_texture_frame.cc",
    "fake_texture_frame.h",
    "fake_videorenderer.h",
    "frame_forwarder.cc",
    "frame_forwarder.h",
    "mappable_native_buffer.cc",
    "mappable_native_buffer.h",
    "video_codec_settings.h",
    "video_decoder_proxy_factory.h",
    "video_encoder_nullable_proxy_factory.h",
    "video_encoder_proxy_factory.h",
  ]

  deps = [
    ":create_frame_generator_capturer",
    ":fileutils",
    ":frame_utils",
    ":scoped_key_value_config",
    ":test_video_capturer",
    "../api:array_view",
    "../api:create_frame_generator",
    "../api:frame_generator_api",
    "../api:scoped_refptr",
    "../api/environment",
    "../api/task_queue",
    "../api/video:video_frame",
    "../api/video:video_rtp_headers",
    "../api/video_codecs:video_codecs_api",
    "../common_video",
    "../rtc_base:checks",
    "../rtc_base:criticalsection",
    "../rtc_base:logging",
    "../rtc_base:refcount",
    "../rtc_base:timeutils",
    "../rtc_base/synchronization:mutex",
    "../rtc_base/task_utils:repeating_task",
    "../system_wrappers",
    "//third_party/abseil-cpp/absl/algorithm:container",
  ]
}

rtc_library("audio_test_common") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "audio_decoder_proxy_factory.h",
    "function_audio_decoder_factory.h",
  ]
  deps = [
    "../api/audio_codecs:audio_codecs_api",
    "../rtc_base:checks",
    "//third_party/abseil-cpp/absl/memory",
  ]
}

if (!build_with_chromium) {
  if (is_mac || is_ios) {
    rtc_library("video_test_mac") {
      testonly = true
      sources = [
        "mac_capturer.h",
        "mac_capturer.mm",
      ]
      deps = [
        ":test_video_capturer",
        ":video_test_common",
        "../api:libjingle_peerconnection_api",
        "../api:media_stream_interface",
        "../api:scoped_refptr",
        "../modules/video_capture:video_capture_module",
        "../rtc_base:logging",
        "../rtc_base:threading",
        "../sdk:base_objc",
        "../sdk:native_api",
        "../sdk:native_video",
        "../sdk:videocapture_objc",
      ]
    }
  }

  rtc_library("platform_video_capturer") {
    testonly = true
    sources = [
      "platform_video_capturer.cc",
      "platform_video_capturer.h",
    ]
    deps = [
      ":test_video_capturer",
      ":video_test_common",
      "//third_party/abseil-cpp/absl/memory",
    ]
    if (is_mac || is_ios) {
      deps += [ ":video_test_mac" ]
    } else {
      sources += [
        "vcm_capturer.cc",
        "vcm_capturer.h",
      ]
      deps += [
        ":scoped_key_value_config",
        "../api:scoped_refptr",
        "../modules/video_capture:video_capture_module",
        "../rtc_base:checks",
        "../rtc_base:logging",
      ]
    }
  }
}

rtc_library("rtp_test_utils") {
  testonly = true
  sources = [
    "rtcp_packet_parser.cc",
    "rtcp_packet_parser.h",
    "rtp_file_reader.cc",
    "rtp_file_reader.h",
    "rtp_file_writer.cc",
    "rtp_file_writer.h",
  ]

  deps = [
    "../api:array_view",
    "../api:rtp_parameters",
    "../modules/rtp_rtcp",
    "../modules/rtp_rtcp:rtp_rtcp_format",
    "../rtc_base:checks",
    "../rtc_base:criticalsection",
    "../rtc_base:logging",
    "../rtc_base:macromagic",
    "../rtc_base/synchronization:mutex",
    "../rtc_base/system:arch",
    "//third_party/abseil-cpp/absl/strings:string_view",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("field_trial") {
  testonly = true
  visibility = [ "*" ]
  sources = [
    "field_trial.cc",
    "field_trial.h",
  ]

  deps = [
    "../rtc_base:checks",
    "../system_wrappers:field_trial",
    "//third_party/abseil-cpp/absl/strings:string_view",
  ]
}

rtc_library("explicit_key_value_config") {
  sources = [
    "explicit_key_value_config.cc",
    "explicit_key_value_config.h",
  ]

  deps = [
    "../api:field_trials_registry",
    "../rtc_base:checks",
    "//third_party/abseil-cpp/absl/strings:string_view",
  ]
}

rtc_library("scoped_key_value_config") {
  testonly = true
  visibility = [ "*" ]
  sources = [
    "scoped_key_value_config.cc",
    "scoped_key_value_config.h",
  ]

  deps = [
    ":field_trial",
    "../api:field_trials_registry",
    "../rtc_base:checks",
    "../system_wrappers:field_trial",
    "//third_party/abseil-cpp/absl/strings:string_view",
  ]
}

rtc_library("perf_test") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "testsupport/perf_test.cc",
    "testsupport/perf_test.h",
    "testsupport/perf_test_histogram_writer.h",
    "testsupport/perf_test_result_writer.h",
  ]
  deps = [
    "../api:array_view",
    "../api/numerics",
    "../rtc_base:checks",
    "../rtc_base:criticalsection",
    "../rtc_base:logging",
    "../rtc_base:rtc_numerics",
    "../rtc_base:stringutils",
    "../rtc_base/synchronization:mutex",
    "../test:fileutils",
    "//third_party/abseil-cpp/absl/strings:string_view",
  ]
  if (rtc_enable_protobuf) {
    sources += [ "testsupport/perf_test_histogram_writer.cc" ]
    deps += [
      "//third_party/catapult/tracing/tracing:histogram",
      "//third_party/catapult/tracing/tracing:reserved_infos",
    ]
  } else {
    sources += [ "testsupport/perf_test_histogram_writer_no_protobuf.cc" ]
  }
}

if (is_ios) {
  rtc_library("test_support_objc") {
    testonly = true
    visibility = [
      ":google_test_runner_objc",
      ":test_support",
    ]
    sources = [
      "ios/coverage_util_ios.h",
      "ios/coverage_util_ios.mm",
      "ios/test_support.h",
      "ios/test_support.mm",
    ]
    deps = [
      ":google_test_runner_delegate",
      ":perf_test",
      "../api/test/metrics:chrome_perf_dashboard_metrics_exporter",
      "../api/test/metrics:global_metrics_logger_and_exporter",
      "../api/test/metrics:metrics_exporter",
      "../api/test/metrics:metrics_set_proto_file_exporter",
      "../api/test/metrics:print_result_proxy_metrics_exporter",
      "../api/test/metrics:stdout_metrics_exporter",
      "../sdk:helpers_objc",
      "//third_party/abseil-cpp/absl/types:optional",
    ]
    configs += [ ":test_support_objc_config" ]
  }

  rtc_library("google_test_runner_delegate") {
    sources = [ "ios/google_test_runner_delegate.h" ]
  }

  rtc_library("google_test_runner_objc") {
    testonly = true
    visibility = [ "*" ]
    sources = [ "ios/google_test_runner.mm" ]
    configs += [ "//build/config/ios:xctest_config" ]
    frameworks = [ "UIKit.framework" ]
    deps = [ ":google_test_runner_delegate" ]
  }

  config("test_support_objc_config") {
    defines = []

    if (use_clang_coverage) {
      defines += [ "WEBRTC_IOS_ENABLE_COVERAGE" ]
    }
  }
}

config("suppress_warning_4373") {
  if (is_win) {
    cflags = [
      # MSVC has a bug which generates this warning when using mocks; see the
      # section on warning 4373 in he googlemock FAQ. This warning isn't the
      # least relevant for us, anyway.
      "/wd4373",
    ]
  }
}

config("test_main_direct_config") {
  visibility = [ ":*" ]
  defines = [ "WEBRTC_UNIT_TEST" ]
}
rtc_source_set("test_support") {
  visibility = [ "*" ]
  testonly = true

  all_dependent_configs = [
    ":suppress_warning_4373",
    "//third_party/googletest:gmock_config",
    "//third_party/googletest:gtest_config",
  ]

  sources = [
    "gmock.h",
    "gtest.h",
  ]

  if (is_ios) {
    public_deps +=  # no-presubmit-check TODO(webrtc:8603)
        [ ":test_support_objc" ]
  }

  public_configs = [ ":test_main_direct_config" ]
  deps = [
    "../rtc_base:ignore_wundef",
    "//testing/gmock",
    "//testing/gtest",
  ]
}

rtc_library("fixed_fps_video_frame_writer_adapter") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "testsupport/fixed_fps_video_frame_writer_adapter.cc",
    "testsupport/fixed_fps_video_frame_writer_adapter.h",
  ]
  deps = [
    ":video_test_support",
    "../api/test/video:video_frame_writer",
    "../api/units:time_delta",
    "../api/video:video_frame",
    "../rtc_base:checks",
    "../system_wrappers",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("video_test_support") {
  testonly = true

  sources = [
    "testsupport/frame_reader.h",
    "testsupport/frame_writer.h",
    "testsupport/mock/mock_frame_reader.h",
    "testsupport/video_frame_writer.cc",
    "testsupport/video_frame_writer.h",
    "testsupport/y4m_frame_reader.cc",
    "testsupport/y4m_frame_writer.cc",
    "testsupport/yuv_frame_reader.cc",
    "testsupport/yuv_frame_writer.cc",
  ]

  deps = [
    ":fileutils",
    ":frame_utils",
    ":test_support",
    ":video_test_common",
    "../api:scoped_refptr",
    "../api:sequence_checker",
    "../api/test/video:video_frame_writer",
    "../api/video:encoded_image",
    "../api/video:resolution",
    "../api/video:video_frame",
    "../api/video_codecs:video_codecs_api",
    "../common_video",
    "../modules/video_coding:video_codec_interface",
    "../modules/video_coding:video_coding_utility",
    "../modules/video_coding:webrtc_h264",
    "../modules/video_coding:webrtc_vp8",
    "../modules/video_coding:webrtc_vp9",
    "../rtc_base:buffer",
    "../rtc_base:checks",
    "../rtc_base:criticalsection",
    "../rtc_base:logging",
    "../rtc_base:rtc_event",
    "../rtc_base:stringutils",
    "../rtc_base/system:file_wrapper",
    "//third_party/abseil-cpp/absl/types:optional",
  ]

  if (!is_ios) {
    deps += [ "//third_party:jpeg" ]
    sources += [ "testsupport/jpeg_frame_writer.cc" ]
  } else {
    sources += [ "testsupport/jpeg_frame_writer_ios.cc" ]
  }
}

if (rtc_include_tests) {
  if (rtc_enable_google_benchmarks) {
    rtc_library("benchmark_main") {
      testonly = true
      sources = [ "benchmark_main.cc" ]

      deps = [ "//third_party/google_benchmark" ]
    }
  }

  if (!build_with_chromium) {
    rtc_library("resources_dir_flag") {
      testonly = true
      visibility = [ "*" ]
      sources = [
        "testsupport/resources_dir_flag.cc",
        "testsupport/resources_dir_flag.h",
      ]
      deps = [ "//third_party/abseil-cpp/absl/flags:flag" ]
    }

    rtc_library("test_main_lib") {
      visibility = [ "*" ]
      testonly = true
      sources = [
        "test_main_lib.cc",
        "test_main_lib.h",
      ]

      deps = [
        ":field_trial",
        ":perf_test",
        ":resources_dir_flag",
        ":test_flags",
        ":test_support",
        "../api/test/metrics:chrome_perf_dashboard_metrics_exporter",
        "../api/test/metrics:global_metrics_logger_and_exporter",
        "../api/test/metrics:metrics_exporter",
        "../api/test/metrics:metrics_set_proto_file_exporter",
        "../api/test/metrics:print_result_proxy_metrics_exporter",
        "../api/test/metrics:stdout_metrics_exporter",
        "../rtc_base:checks",
        "../rtc_base:event_tracer",
        "../rtc_base:logging",
        "../rtc_base:ssl_adapter",
        "../rtc_base:threading",
        "../system_wrappers:field_trial",
        "../system_wrappers:metrics",
        "//third_party/abseil-cpp/absl/flags:flag",
        "//third_party/abseil-cpp/absl/memory",
        "//third_party/abseil-cpp/absl/strings",
        "//third_party/abseil-cpp/absl/strings:string_view",
        "//third_party/abseil-cpp/absl/types:optional",
        "//third_party/perfetto/include/perfetto/tracing",
      ]

      if (is_win) {
        deps += [ "../rtc_base:win32_socket_init" ]
      }
      if (rtc_use_perfetto) {
        deps += [ "//third_party/perfetto/src/tracing:client_api" ]
      }
    }

    rtc_library("test_main") {
      visibility = [ "*" ]
      testonly = true
      sources = [ "test_main.cc" ]

      deps = [
        ":test_main_lib",
        ":test_support",
        "//third_party/abseil-cpp/absl/debugging:failure_signal_handler",
        "//third_party/abseil-cpp/absl/debugging:symbolize",
        "//third_party/abseil-cpp/absl/flags:parse",
      ]
    }

    rtc_library("test_support_test_artifacts") {
      testonly = true
      sources = [
        "testsupport/test_artifacts.cc",
        "testsupport/test_artifacts.h",
      ]
      deps = [
        ":fileutils",
        "../rtc_base:logging",
        "../rtc_base/system:file_wrapper",
        "//third_party/abseil-cpp/absl/flags:flag",
        "//third_party/abseil-cpp/absl/flags:parse",
      ]
    }

    test_support_unittests_resources = [
      "../resources/foreman_cif_short.yuv",
      "../resources/video_coding/frame-ethernet-ii.pcap",
      "../resources/video_coding/frame-loopback.pcap",
      "../resources/video_coding/pltype103.rtp",
      "../resources/video_coding/pltype103_header_only.rtp",
      "../resources/video_coding/ssrcs-2.pcap",
      "../resources/video_coding/ssrcs-3.pcap",
    ]

    if (is_ios) {
      bundle_data("test_support_unittests_bundle_data") {
        testonly = true
        sources = test_support_unittests_resources
        outputs = [ "{{bundle_resources_dir}}/{{source_file_part}}" ]
      }
    }

    rtc_library("fixed_fps_video_frame_writer_adapter_test") {
      testonly = true
      sources = [ "testsupport/fixed_fps_video_frame_writer_adapter_test.cc" ]
      deps = [
        ":fixed_fps_video_frame_writer_adapter",
        ":test_support",
        ":video_test_support",
        "../api/units:time_delta",
        "../api/units:timestamp",
        "../api/video:video_frame",
        "../rtc_base/synchronization:mutex",
        "time_controller",
      ]
    }

    rtc_test("test_support_unittests") {
      deps = [
        ":call_config_utils",
        ":copy_to_file_audio_capturer_unittest",
        ":create_frame_generator_capturer",
        ":direct_transport",
        ":fake_video_codecs",
        ":fileutils",
        ":fileutils_unittests",
        ":fixed_fps_video_frame_writer_adapter_test",
        ":frame_generator_capturer",
        ":frame_generator_impl",
        ":perf_test",
        ":rtc_expect_death",
        ":rtp_test_utils",
        ":run_loop",
        ":scoped_key_value_config",
        ":test_main",
        ":test_support",
        ":test_support_test_artifacts",
        ":video_codec_tester",
        ":video_test_common",
        ":video_test_support",
        ":y4m_frame_generator",
        "../api:array_view",
        "../api:create_frame_generator",
        "../api:create_simulcast_test_fixture_api",
        "../api:frame_generator_api",
        "../api:mock_video_codec_factory",
        "../api:mock_video_decoder",
        "../api:mock_video_encoder",
        "../api:scoped_refptr",
        "../api:simulcast_test_fixture_api",
        "../api/environment",
        "../api/environment:environment_factory",
        "../api/task_queue",
        "../api/task_queue:task_queue_test",
        "../api/test/video:function_video_factory",
        "../api/test/video:video_frame_writer",
        "../api/units:data_rate",
        "../api/units:data_size",
        "../api/units:frequency",
        "../api/units:time_delta",
        "../api/video:encoded_image",
        "../api/video:video_frame",
        "../api/video_codecs:scalability_mode",
        "../api/video_codecs:video_codecs_api",
        "../call:video_stream_api",
        "../common_video",
        "../media:codec",
        "../media:media_constants",
        "../modules/rtp_rtcp:rtp_rtcp_format",
        "../modules/video_coding:simulcast_test_fixture_impl",
        "../modules/video_coding:video_codec_interface",
        "../modules/video_coding:video_coding_utility",
        "../modules/video_coding:webrtc_h264",
        "../modules/video_coding:webrtc_vp8",
        "../modules/video_coding:webrtc_vp9",
        "../modules/video_coding/svc:scalability_mode_util",
        "../rtc_base:criticalsection",
        "../rtc_base:rtc_event",
        "../rtc_base/synchronization:mutex",
        "../rtc_base/system:file_wrapper",
        "jitter:jitter_unittests",
        "pc/e2e:e2e_unittests",
        "pc/e2e/analyzer/video:video_analyzer_unittests",
        "pc/e2e/analyzer/video/dvqa:dvqa_unittests",
        "peer_scenario/tests",
        "scenario:scenario_unittests",
        "time_controller:time_controller",
        "time_controller:time_controller_unittests",
        "//third_party/abseil-cpp/absl/flags:flag",
        "//third_party/abseil-cpp/absl/strings:string_view",
        "//third_party/abseil-cpp/absl/types:optional",
        "//third_party/libyuv",
      ]
      sources = [
        "call_config_utils_unittest.cc",
        "direct_transport_unittest.cc",
        "fake_vp8_encoder_unittest.cc",
        "frame_generator_capturer_unittest.cc",
        "frame_generator_unittest.cc",
        "rtp_file_reader_unittest.cc",
        "rtp_file_writer_unittest.cc",
        "run_loop_unittest.cc",
        "testsupport/ivf_video_frame_generator_unittest.cc",
        "testsupport/perf_test_unittest.cc",
        "testsupport/test_artifacts_unittest.cc",
        "testsupport/video_frame_writer_unittest.cc",
        "testsupport/y4m_frame_generator_test.cc",
        "testsupport/y4m_frame_reader_unittest.cc",
        "testsupport/y4m_frame_writer_unittest.cc",
        "testsupport/yuv_frame_reader_unittest.cc",
        "testsupport/yuv_frame_writer_unittest.cc",
        "video_codec_tester_unittest.cc",
      ]

      if (rtc_enable_protobuf) {
        sources += [ "testsupport/perf_test_histogram_writer_unittest.cc" ]
        deps += [ "//third_party/catapult/tracing/tracing:histogram" ]
      }

      data = test_support_unittests_resources
      if (is_android) {
        deps += [ "//testing/android/native_test:native_test_support" ]
        shard_timeout = 900
      }

      if (is_ios) {
        deps += [ ":test_support_unittests_bundle_data" ]
      }

      if (!is_android) {
        # This is needed in order to avoid:
        # undefined symbol: webrtc::videocapturemodule::VideoCaptureImpl::Create
        deps += [ "../modules/video_capture:video_capture_internal_impl" ]
      }
    }
  }
}

if (is_ios) {
  rtc_library("fileutils_ios_objc") {
    visibility = [
      ":fileutils",
      ":fileutils_override_impl",
    ]
    sources = [
      "testsupport/ios_file_utils.h",
      "testsupport/ios_file_utils.mm",
    ]
    deps = [
      "../rtc_base:checks",
      "../sdk:helpers_objc",
      "//third_party/abseil-cpp/absl/strings:string_view",
    ]
  }
}

if (is_mac) {
  rtc_library("fileutils_mac_objc") {
    visibility = [
      ":fileutils",
      ":fileutils_override_impl",
    ]
    sources = [
      "testsupport/mac_file_utils.h",
      "testsupport/mac_file_utils.mm",
    ]
    deps = [ "../rtc_base:checks" ]
  }
}

rtc_library("fileutils") {
  testonly = true
  visibility = [ "*" ]
  sources = [
    "testsupport/file_utils.cc",
    "testsupport/file_utils.h",
  ]
  deps = [
    ":fileutils_override_api",
    ":fileutils_override_impl",
    "../rtc_base:checks",
    "../rtc_base:ssl",
    "../rtc_base:stringutils",
    "//third_party/abseil-cpp/absl/base:core_headers",
    "//third_party/abseil-cpp/absl/strings:string_view",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
  if (is_ios) {
    deps += [ ":fileutils_ios_objc" ]
  }
  if (is_mac) {
    deps += [ ":fileutils_mac_objc" ]
  }
  if (is_win) {
    deps += [ "../rtc_base:win32" ]
  }
}

# We separate header into own target to make it possible for downstream
# projects to override implementation.
rtc_source_set("fileutils_override_api") {
  testonly = true
  sources = [ "testsupport/file_utils_override.h" ]
  deps = [ "//third_party/abseil-cpp/absl/strings:string_view" ]
}

rtc_library("fileutils_override_impl") {
  testonly = true
  visibility = [ ":fileutils" ]
  sources = [ "testsupport/file_utils_override.cc" ]
  deps = [
    ":fileutils_override_api",
    "../rtc_base:checks",
    "../rtc_base:macromagic",
    "../rtc_base:stringutils",
    "//third_party/abseil-cpp/absl/strings:string_view",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
  if (is_ios) {
    deps += [ ":fileutils_ios_objc" ]
  }
  if (is_mac) {
    deps += [ ":fileutils_mac_objc" ]
  }
  if (is_win) {
    deps += [ "../rtc_base:win32" ]
  }
}

rtc_source_set("run_test") {
  testonly = true
  if (is_mac) {
    public_deps += [ ":run_test_objc" ]  # no-presubmit-check TODO(webrtc:8603)
  } else {
    public_deps +=  # no-presubmit-check TODO(webrtc:8603)
        [ ":run_test_generic" ]
  }
}

rtc_source_set("run_test_interface") {
  sources = [ "run_test.h" ]
}

if (is_mac) {
  rtc_library("run_test_objc") {
    testonly = true
    visibility = [ ":run_test" ]
    sources = [ "mac/run_test.mm" ]
    deps = [ ":run_test_interface" ]
  }
}

rtc_library("run_test_generic") {
  testonly = true
  visibility = [ ":run_test" ]
  sources = [ "run_test.cc" ]
  deps = [ ":run_test_interface" ]
}

rtc_library("fileutils_unittests") {
  testonly = true
  visibility = [ ":*" ]  # Only targets in this file can depend on this.
  sources = [ "testsupport/file_utils_unittest.cc" ]
  deps = [
    ":fileutils",
    ":test_support",
    "../rtc_base:checks",
    "../rtc_base:ssl",
    "//third_party/abseil-cpp/absl/strings:string_view",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("direct_transport") {
  visibility = [ "*" ]
  testonly = true
  sources = [
    "direct_transport.cc",
    "direct_transport.h",
  ]
  deps = [
    "../api:rtp_parameters",
    "../api:sequence_checker",
    "../api:simulated_network_api",
    "../api:transport_api",
    "../api/task_queue",
    "../api/units:time_delta",
    "../call:call_interfaces",
    "../call:simulated_packet_receiver",
    "../modules/rtp_rtcp:rtp_rtcp_format",
    "../rtc_base:checks",
    "../rtc_base:macromagic",
    "../rtc_base:timeutils",
    "../rtc_base/synchronization:mutex",
    "../rtc_base/task_utils:repeating_task",
  ]
  public_deps +=  # no-presubmit-check TODO(webrtc:8603)
      [ "../call:fake_network" ]
}

rtc_library("fake_video_codecs") {
  allow_poison = [ "software_video_codecs" ]
  visibility = [ "*" ]
  sources = [
    "configurable_frame_size_encoder.cc",
    "configurable_frame_size_encoder.h",
    "fake_decoder.cc",
    "fake_decoder.h",
    "fake_encoder.cc",
    "fake_encoder.h",
    "fake_vp8_decoder.cc",
    "fake_vp8_decoder.h",
    "fake_vp8_encoder.cc",
    "fake_vp8_encoder.h",
  ]
  deps = [
    "../api:fec_controller_api",
    "../api:scoped_refptr",
    "../api:sequence_checker",
    "../api/environment",
    "../api/task_queue",
    "../api/video:encoded_image",
    "../api/video:video_bitrate_allocation",
    "../api/video:video_frame",
    "../api/video:video_rtp_headers",
    "../api/video_codecs:video_codecs_api",
    "../api/video_codecs:vp8_temporal_layers_factory",
    "../modules/video_coding:codec_globals_headers",
    "../modules/video_coding:video_codec_interface",
    "../modules/video_coding:video_coding_utility",
    "../rtc_base:checks",
    "../rtc_base:criticalsection",
    "../rtc_base:macromagic",
    "../rtc_base:timeutils",
    "../rtc_base/synchronization:mutex",
    "../system_wrappers",
    "//third_party/abseil-cpp/absl/strings:string_view",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

rtc_library("null_transport") {
  testonly = true
  sources = [
    "null_transport.cc",
    "null_transport.h",
  ]
  deps = [ "../api:transport_api" ]
}

rtc_library("encoder_settings") {
  testonly = true
  sources = [
    "encoder_settings.cc",
    "encoder_settings.h",
  ]
  deps = [
    "../api:scoped_refptr",
    "../api/video_codecs:video_codecs_api",
    "../call:rtp_interfaces",
    "../call:video_stream_api",
    "../rtc_base:checks",
    "../rtc_base:refcount",
    "../video/config:encoder_config",
  ]
}

rtc_library("rtc_expect_death") {
  testonly = true
  sources = [ "testsupport/rtc_expect_death.h" ]
  deps = [ ":test_support" ]
}

rtc_library("run_loop") {
  testonly = true
  sources = [
    "run_loop.cc",
    "run_loop.h",
  ]
  deps = [
    "../api/task_queue",
    "../rtc_base:threading",
    "../rtc_base:timeutils",
    "//third_party/abseil-cpp/absl/functional:any_invocable",
  ]
}

rtc_library("video_test_constants") {
  testonly = true
  sources = [ "video_test_constants.h" ]
  deps = [ "../api/units:time_delta" ]
}

rtc_library("mock_transport") {
  testonly = true
  sources = [
    "mock_transport.cc",
    "mock_transport.h",
  ]
  deps = [
    ":test_support",
    "../api:transport_api",
  ]
}

rtc_source_set("test_renderer") {
  public_deps +=  # no-presubmit-check TODO(webrtc:8603)
      [ ":test_renderer_generic" ]
  testonly = true
  if (is_mac) {
    public_deps +=  # no-presubmit-check TODO(webrtc:8603)
        [ ":test_renderer_objc" ]
  }
}

if (is_mac) {
  rtc_library("test_renderer_objc") {
    testonly = true
    visibility = [ ":test_renderer" ]
    sources = [
      "mac/video_renderer_mac.h",
      "mac/video_renderer_mac.mm",
    ]
    deps = [ ":test_renderer_generic" ]
    frameworks = [
      "Cocoa.framework",
      "OpenGL.framework",
      "CoreVideo.framework",
    ]
    defines = [ "GL_SILENCE_DEPRECATION" ]
  }
}

rtc_library("test_renderer_generic") {
  testonly = true
  visibility = [
    ":test_renderer",
    ":test_renderer_objc",
  ]
  libs = []
  sources = [
    "video_renderer.cc",
    "video_renderer.h",
  ]
  deps = [
    "../api/video:video_frame",
    "../common_video",
    "../rtc_base:checks",
  ]
  if (is_win) {
    sources += [
      "win/d3d_renderer.cc",
      "win/d3d_renderer.h",
    ]
    deps += [ "../api:scoped_refptr" ]
  }
  if (!((is_linux || is_chromeos) && rtc_use_x11) && !is_mac && !is_win) {
    sources += [ "null_platform_renderer.cc" ]
  }
  if (((is_linux || is_chromeos) && rtc_use_x11) || is_mac) {
    sources += [
      "gl/gl_renderer.cc",
      "gl/gl_renderer.h",
    ]
  }
  if (is_mac) {
    defines = [ "GL_SILENCE_DEPRECATION" ]
  }

  if ((is_linux || is_chromeos) && rtc_use_x11) {
    sources += [
      "linux/glx_renderer.cc",
      "linux/glx_renderer.h",
      "linux/video_renderer_linux.cc",
    ]
    libs += [
      "Xext",
      "X11",
      "GL",
    ]
  }
  if (is_android) {
    libs += [
      "GLESv2",
      "log",
    ]
  }
}

rtc_library("audio_codec_mocks") {
  testonly = true
  sources = [
    "mock_audio_decoder.cc",
    "mock_audio_decoder.h",
    "mock_audio_decoder_factory.h",
    "mock_audio_encoder.cc",
    "mock_audio_encoder.h",
    "mock_audio_encoder_factory.h",
  ]

  deps = [
    ":test_support",
    "../api:array_view",
    "../api:make_ref_counted",
    "../api:scoped_refptr",
    "../api/audio_codecs:audio_codecs_api",
    "../api/audio_codecs:builtin_audio_decoder_factory",
  ]
}

if (!build_with_chromium) {
  rtc_library("copy_to_file_audio_capturer") {
    testonly = true
    sources = [
      "testsupport/copy_to_file_audio_capturer.cc",
      "testsupport/copy_to_file_audio_capturer.h",
    ]
    deps = [
      "../api:array_view",
      "../common_audio",
      "../modules/audio_device:test_audio_device_module",
      "../rtc_base:buffer",
      "//third_party/abseil-cpp/absl/types:optional",
    ]
  }

  rtc_library("copy_to_file_audio_capturer_unittest") {
    testonly = true
    sources = [ "testsupport/copy_to_file_audio_capturer_unittest.cc" ]
    deps = [
      ":copy_to_file_audio_capturer",
      ":fileutils",
      ":test_support",
      "../modules/audio_device:test_audio_device_module",
    ]
  }

  rtc_library("test_flags") {
    testonly = true
    sources = [
      "test_flags.cc",
      "test_flags.h",
    ]
    deps = [ "//third_party/abseil-cpp/absl/flags:flag" ]
  }

  rtc_library("test_common") {
    testonly = true
    sources = [
      "call_test.cc",
      "call_test.h",
      "drifting_clock.cc",
      "drifting_clock.h",
      "layer_filtering_transport.cc",
      "layer_filtering_transport.h",
      "rtp_rtcp_observer.h",
    ]

    deps = [
      ":direct_transport",
      ":encoder_settings",
      ":fake_video_codecs",
      ":fileutils",
      ":frame_generator_capturer",
      ":mock_transport",
      ":run_loop",
      ":scoped_key_value_config",
      ":test_flags",
      ":test_support",
      ":test_video_capturer",
      ":video_test_common",
      ":video_test_constants",
      "..//test/network:simulated_network",
      "../api:array_view",
      "../api:create_frame_generator",
      "../api:frame_generator_api",
      "../api:rtp_headers",
      "../api:rtp_parameters",
      "../api:simulated_network_api",
      "../api:transport_api",
      "../api/audio:audio_device",
      "../api/audio_codecs:builtin_audio_decoder_factory",
      "../api/audio_codecs:builtin_audio_encoder_factory",
      "../api/environment",
      "../api/environment:environment_factory",
      "../api/rtc_event_log",
      "../api/task_queue",
      "../api/test/video:function_video_factory",
      "../api/transport:field_trial_based_config",
      "../api/units:time_delta",
      "../api/video:builtin_video_bitrate_allocator_factory",
      "../api/video:video_bitrate_allocator_factory",
      "../api/video:video_frame",
      "../api/video_codecs:video_codecs_api",
      "../call",
      "../call:call_interfaces",
      "../call:fake_network",
      "../call:simulated_packet_receiver",
      "../call:video_stream_api",
      "../modules/audio_device:test_audio_device_module",
      "../modules/audio_mixer:audio_mixer_impl",
      "../modules/rtp_rtcp",
      "../modules/rtp_rtcp:rtp_rtcp_format",
      "../modules/rtp_rtcp:rtp_video_header",
      "../modules/video_coding:codec_globals_headers",
      "../rtc_base:checks",
      "../rtc_base:criticalsection",
      "../rtc_base:rtc_event",
      "../rtc_base:task_queue_for_test",
      "../rtc_base:threading",
      "../rtc_base:timeutils",
      "../system_wrappers",
      "../system_wrappers:field_trial",
      "../video/config:encoder_config",
      "//third_party/abseil-cpp/absl/flags:flag",
      "//third_party/abseil-cpp/absl/types:optional",
    ]
    if (!is_android && !build_with_chromium) {
      deps += [ "../modules/video_capture:video_capture_internal_impl" ]
    }
  }
}

if (!build_with_chromium && is_android) {
  rtc_android_library("native_test_java") {
    testonly = true
    sources = [
      "android/org/webrtc/native_test/RTCNativeUnitTest.java",
      "android/org/webrtc/native_test/RTCNativeUnitTestActivity.java",
    ]
    deps = [
      "../rtc_base:base_java",
      "//testing/android/native_test:native_test_java",
    ]
  }
}

rtc_library("call_config_utils") {
  testonly = true

  # TODO(bugs.webrtc.org/10814): Remove rtc_json_suppressions as soon as it
  # gets removed upstream.
  public_configs = [ "../rtc_base:rtc_json_suppressions" ]
  sources = [
    "call_config_utils.cc",
    "call_config_utils.h",
  ]
  deps = [
    "../call:video_stream_api",
    "../rtc_base:rtc_json",
  ]
}

rtc_library("fake_encoded_frame") {
  testonly = true
  sources = [
    "fake_encoded_frame.cc",
    "fake_encoded_frame.h",
  ]
  deps = [
    ":test_support",
    "../api:rtp_packet_info",
    "../api/video:encoded_frame",
    "../api/video:encoded_image",
    "../api/video:video_frame_type",
    "../api/video:video_rtp_headers",
  ]
}

rtc_library("video_codec_tester") {
  testonly = true
  sources = [
    "video_codec_tester.cc",
    "video_codec_tester.h",
  ]
  deps = [
    ":scoped_key_value_config",
    "../api:array_view",
    "../api/environment",
    "../api/numerics:numerics",
    "../api/test/metrics:metric",
    "../api/test/metrics:metrics_logger",
    "../api/units:data_rate",
    "../api/units:data_size",
    "../api/units:frequency",
    "../api/units:time_delta",
    "../api/units:timestamp",
    "../api/video:builtin_video_bitrate_allocator_factory",
    "../api/video:encoded_image",
    "../api/video:resolution",
    "../api/video:video_bitrate_allocator",
    "../api/video:video_frame",
    "../api/video_codecs:video_codecs_api",
    "../media:media_constants",
    "../modules/video_coding:video_codec_interface",
    "../modules/video_coding:video_coding_utility",
    "../modules/video_coding:webrtc_h264",
    "../modules/video_coding:webrtc_vp9_helpers",
    "../modules/video_coding/codecs/av1:av1_svc_config",
    "../modules/video_coding/svc:scalability_mode_util",
    "../rtc_base:checks",
    "../rtc_base:logging",
    "../rtc_base:rtc_event",
    "../rtc_base:stringutils",
    "../rtc_base:task_queue_for_test",
    "../rtc_base:timeutils",
    "../rtc_base/synchronization:mutex",
    "../system_wrappers",
    "../test:fileutils",
    "../test:video_test_support",
    "../video/config:streams_config",
    "//third_party/abseil-cpp/absl/strings",
    "//third_party/abseil-cpp/absl/types:optional",
    "//third_party/libyuv",
  ]
}
