# 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/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",
    "../media:rtc_media_base",
    "../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",
  ]
  absl_deps = [ "//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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/strings",
    "//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:rtc_media_base",
    "../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",
  ]
  absl_deps = [
    "//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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/strings",
    "//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/task_queue",
    "../api/video:video_frame",
    "../api/video:video_rtp_headers",
    "../api/video_codecs:video_codecs_api",
    "../common_video",
    "../media:rtc_media_base",
    "../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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/algorithm:container",
    "//third_party/abseil-cpp/absl/strings",
  ]
}

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",
  ]
  absl_deps = [ "//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",
    ]
    absl_deps = [ "//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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/strings",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
}

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

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

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",
  ]
  absl_deps = [ "//third_party/abseil-cpp/absl/strings:strings" ]
}

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",
  ]
  absl_deps = [ "//third_party/abseil-cpp/absl/strings:strings" ]
}

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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/strings",
    "//third_party/abseil-cpp/absl/types:optional",
  ]
  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",
    ]
    absl_deps = [ "//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",
  ]
  absl_deps = [ "//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",
    "../media:rtc_media_base",
    "../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",
  ]
  absl_deps = [ "//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",
      ]
      absl_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",
        "../rtc_base:threading",
        "../system_wrappers:field_trial",
        "../system_wrappers:metrics",
      ]
      absl_deps = [
        "//third_party/abseil-cpp/absl/flags:flag",
        "//third_party/abseil-cpp/absl/memory",
        "//third_party/abseil-cpp/absl/strings:strings",
        "//third_party/abseil-cpp/absl/types:optional",
      ]

      if (is_win) {
        deps += [ "../rtc_base:win32_socket_init" ]
      }
    }

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

      deps = [
        ":test_main_lib",
        ":test_support",
      ]

      absl_deps = [
        "//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",
      ]
      absl_deps = [
        "//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",
      ]
      absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ]
    }

    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",
        "../media:rtc_media_base",
        "../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/libyuv",
      ]
      absl_deps = [
        "//third_party/abseil-cpp/absl/flags:flag",
        "//third_party/abseil-cpp/absl/strings",
        "//third_party/abseil-cpp/absl/types:optional",
      ]
      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",
    ]
    absl_deps = [ "//third_party/abseil-cpp/absl/strings:strings" ]
  }
}

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:stringutils",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/base:core_headers",
    "//third_party/abseil-cpp/absl/strings:strings",
    "//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" ]
  absl_deps = [ "//third_party/abseil-cpp/absl/strings:strings" ]
}

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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/strings:strings",
    "//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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/strings:strings",
    "//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",
  ]
  absl_deps = [ "//third_party/abseil-cpp/absl/memory" ]
  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/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",
  ]
  absl_deps = [
    "//third_party/abseil-cpp/absl/strings",
    "//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",
  ]
  absl_deps = [ "//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" ]
  }
}

rtc_library("mock_frame_transformer") {
  visibility = [ "*" ]
  testonly = true
  sources = [ "mock_frame_transformer.h" ]
  deps = [
    "../api:frame_transformer_interface",
    "../test:test_support",
  ]
}

rtc_library("mock_transformable_frame") {
  visibility = [ "*" ]

  testonly = true
  sources = [ "mock_transformable_frame.h" ]

  deps = [
    "../api:frame_transformer_interface",
    "../test:test_support",
  ]
}

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",
    ]
    absl_deps = [ "//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",
    ]
    absl_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",
      "../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_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_network",
      "../call:simulated_packet_receiver",
      "../call:video_stream_api",
      "../modules/audio_device:audio_device_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",
    ]
    absl_deps = [
      "//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",
  ]
  absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ]
}

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/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/libyuv",
  ]

  absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ]
}
