chromium/chrome/test/BUILD.gn

# Copyright 2014 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//build/cipd/cipd.gni")
import("//build/config/buildflags_paint_preview.gni")
import("//build/config/chrome_build.gni")
import("//build/config/chromeos/ui_mode.gni")
import("//build/config/compiler/compiler.gni")
import("//build/config/features.gni")
import("//build/config/ozone.gni")
import("//build/config/ui.gni")
import("//build/toolchain/toolchain.gni")
import("//chrome/browser/buildflags.gni")
import("//chrome/browser/downgrade/buildflags.gni")
import("//chrome/browser/page_load_metrics/integration_tests/jsdeps.gni")
import("//chrome/browser/page_load_metrics/integration_tests/sources.gni")
import("//chrome/browser/sync/test/integration/sync_integration_tests.gni")
import("//chrome/common/features.gni")

import("//chrome/services/speech/buildflags/buildflags.gni")
import("//chrome/test/include_js_tests.gni")
import("//chrome/version.gni")
import("//components/allocation_recorder/testing/testing.gni")
import("//components/captive_portal/core/features.gni")
import("//components/compose/features.gni")
import("//components/enterprise/buildflags/buildflags.gni")
import("//components/lens/features.gni")
import("//components/nacl/features.gni")
import("//components/offline_pages/buildflags/features.gni")
import("//components/optimization_guide/features.gni")
import("//components/os_crypt/sync/features.gni")
import("//components/safe_browsing/buildflags.gni")
import("//components/soda/buildflags.gni")
import("//components/spellcheck/spellcheck_build_features.gni")
import("//crypto/features.gni")
import("//extensions/buildflags/buildflags.gni")
import("//mojo/public/tools/bindings/mojom.gni")
import("//net/features.gni")
import("//pdf/features.gni")
import("//ppapi/buildflags/buildflags.gni")
import("//printing/buildflags/buildflags.gni")
import("//remoting/remoting_enable.gni")
import("//rlz/buildflags/buildflags.gni")
import("//services/screen_ai/buildflags/features.gni")
import("//testing/libfuzzer/fuzzer_test.gni")
import("//testing/test.gni")
import("//third_party/protobuf/proto_library.gni")
import("//third_party/widevine/cdm/widevine.gni")
import("//ui/base/ui_features.gni")
import("//ui/gl/features.gni")
import("//ui/views/features.gni")
import("//ui/webui/webui_features.gni")
import("//v8/gni/v8.gni")

assert(!is_ios, "Chromium/iOS shouldn't use anything in //chrome")
assert(!is_fuchsia, "Fuchsia shouldn't use anything in //chrome")
assert(enable_supervised_users)

if (is_android) {
  import("//build/config/android/rules.gni")
  import("//chrome/android/features/dev_ui/dev_ui_module.gni")
  import("//third_party/jni_zero/jni_zero.gni")
  import("//tools/perf/chrome_telemetry_build/android_browser_types.gni")
}

if (is_chromeos_ash && include_js2gtest_tests) {
  import("//chrome/test/base/ash/js2gtest.gni")
}

# This target exists to reference other test executables to bring these files
# into the build.
group("test") {
  testonly = true
  deps = [
    "fuzzing:test",
    "//chrome/test/variations:variations_desktop_smoke_tests",
  ]
}

if (is_android) {
  android_library("test_support_java") {
    testonly = true
    deps = [
      ":payment_test_support_jni_headers_java",
      ":test_support_jni_headers_java",
      "//chrome/android:chrome_all_java",
      "//chrome/browser/feedback/android:java",
      "//chrome/browser/profiles/android:java",
      "//chrome/browser/ui/android/hats/test:test_support_java",
      "//components/autofill/android:autofill_java",
      "//components/messages/android/test:test_support_java",
      "//components/metrics:metrics_java",
      "//components/payments/content/android:java",
      "//components/payments/mojom:mojom_java",
      "//content/public/android:content_java",
      "//third_party/androidx:androidx_annotation_annotation_java",
      "//third_party/blink/public/mojom:android_mojo_bindings_java",
      "//third_party/jni_zero:jni_zero_java",
    ]
    sources = [
      "android/test_support/src/org/chromium/chrome/test_support/FamilyInfoFeedbackSourceTestBridge.java",
      "android/test_support/src/org/chromium/chrome/test_support/PaymentRequestTestBridge.java",
    ]
  }

  generate_jni("test_support_jni_headers") {
    testonly = true
    sources = [ "android/test_support/src/org/chromium/chrome/test_support/FamilyInfoFeedbackSourceTestBridge.java" ]
  }
  generate_jni("payment_test_support_jni_headers") {
    testonly = true
    sources = [ "android/test_support/src/org/chromium/chrome/test_support/PaymentRequestTestBridge.java" ]
  }
}

static_library("chrome_test_launcher") {
  testonly = true
  sources = [
    "base/chrome_test_launcher.cc",
    "base/chrome_test_launcher.h",
  ]

  deps = [
    ":test_support",
    "//chrome/browser:main_extra_parts",
  ]

  if (is_mac) {
    deps += [ "//chrome/app_shim" ]
  }

  if (is_chromeos_ash) {
    deps += [
      "//chrome/browser/ash/crosapi",
      "//chrome/browser/ash/crosapi:test_support",
    ]
  }
}

# Use a static library here because many test binaries depend on this but don't
# require many files from it. This makes linking more efficient.
static_library("test_support") {
  defines = []
  deps = [
    "//chrome/browser:global_features",
    "//chrome/browser/ui:ui_features",
  ]
  public_deps = []
  testonly = true

  sources = [
    "../app/startup_timestamps.h",
    "../browser/autofill/automated_tests/cache_replayer.cc",
    "../browser/autofill/automated_tests/cache_replayer.h",
    "../browser/component_updater/privacy_sandbox_attestations_component_installer_test_util.cc",
    "../browser/component_updater/privacy_sandbox_attestations_component_installer_test_util.h",
    "../browser/dips/dips_test_utils.cc",
    "../browser/dips/dips_test_utils.h",
    "../browser/fingerprinting_protection/fingerprinting_protection_filter_browser_test_harness.cc",
    "../browser/fingerprinting_protection/fingerprinting_protection_filter_browser_test_harness.h",
    "../browser/notifications/notification_display_service_tester.cc",
    "../browser/notifications/notification_display_service_tester.h",
    "../browser/notifications/stub_notification_platform_bridge.cc",
    "../browser/notifications/stub_notification_platform_bridge.h",
    "../browser/optimization_guide/mock_optimization_guide_keyed_service.cc",
    "../browser/optimization_guide/mock_optimization_guide_keyed_service.h",
    "../browser/password_manager/password_manager_test_util.cc",
    "../browser/password_manager/password_manager_test_util.h",
    "../browser/permissions/crowd_deny_fake_safe_browsing_database_manager.cc",
    "../browser/permissions/crowd_deny_fake_safe_browsing_database_manager.h",
    "../browser/policy/messaging_layer/public/report_client_test_util.cc",
    "../browser/policy/messaging_layer/public/report_client_test_util.h",
    "../browser/policy/messaging_layer/upload/file_upload_job_test_util.cc",
    "../browser/policy/messaging_layer/upload/file_upload_job_test_util.h",
    "../browser/policy/messaging_layer/util/reporting_server_connector_test_util.cc",
    "../browser/policy/messaging_layer/util/reporting_server_connector_test_util.h",
    "../browser/policy/messaging_layer/util/test_request_payload.cc",
    "../browser/policy/messaging_layer/util/test_request_payload.h",
    "../browser/policy/messaging_layer/util/test_response_payload.cc",
    "../browser/policy/messaging_layer/util/test_response_payload.h",
    "../browser/profiles/keep_alive/profile_keep_alive_waiter.cc",
    "../browser/profiles/keep_alive/profile_keep_alive_waiter.h",
    "../browser/profiles/profile_test_util.cc",
    "../browser/profiles/profile_test_util.h",
    "../browser/safe_browsing/test_safe_browsing_database_helper.cc",
    "../browser/safe_browsing/test_safe_browsing_database_helper.h",
    "../browser/search_engines/template_url_service_factory_test_util.cc",
    "../browser/search_engines/template_url_service_factory_test_util.h",
    "../browser/search_engines/template_url_service_test_util.cc",
    "../browser/search_engines/template_url_service_test_util.h",
    "../browser/signin/identity_test_environment_profile_adaptor.cc",
    "../browser/signin/identity_test_environment_profile_adaptor.h",
    "../browser/signin/test_signin_client_builder.cc",
    "../browser/signin/test_signin_client_builder.h",
    "../browser/subresource_filter/subresource_filter_browser_test_harness.cc",
    "../browser/subresource_filter/subresource_filter_browser_test_harness.h",
    "../browser/tpcd/experiment/mock_experiment_manager.cc",
    "../browser/tpcd/experiment/mock_experiment_manager.h",
    "../browser/tpcd/support/trial_test_utils.cc",
    "../browser/tpcd/support/trial_test_utils.h",
    "../browser/ui/safety_hub/safety_hub_test_util.cc",
    "../browser/ui/safety_hub/safety_hub_test_util.h",
    "base/chrome_render_view_host_test_harness.cc",
    "base/chrome_render_view_host_test_harness.h",
    "base/chrome_render_view_test.cc",
    "base/chrome_render_view_test.h",
    "base/chrome_test_suite.cc",
    "base/chrome_test_suite.h",
    "base/chrome_test_utils.cc",
    "base/chrome_test_utils.h",
    "base/chrome_unit_test_suite.cc",
    "base/chrome_unit_test_suite.h",
    "base/fake_profile_manager.cc",
    "base/fake_profile_manager.h",
    "base/find_result_waiter.cc",
    "base/find_result_waiter.h",
    "base/profile_deletion_observer.cc",
    "base/profile_deletion_observer.h",
    "base/profile_destruction_waiter.cc",
    "base/profile_destruction_waiter.h",
    "base/profile_waiter.cc",
    "base/profile_waiter.h",
    "base/scoped_browser_locale.cc",
    "base/scoped_browser_locale.h",
    "base/scoped_metrics_service_for_synthetic_trials.cc",
    "base/scoped_metrics_service_for_synthetic_trials.h",
    "base/scoped_testing_local_state.cc",
    "base/scoped_testing_local_state.h",
    "base/search_test_utils.cc",
    "base/search_test_utils.h",
    "base/test_launcher_utils.cc",
    "base/test_launcher_utils.h",
    "base/test_switches.cc",
    "base/test_switches.h",
    "base/testing_browser_process.cc",
    "base/testing_browser_process.h",
    "base/testing_browser_process_platform_part.cc",
    "base/testing_browser_process_platform_part.h",
    "base/testing_profile.cc",
    "base/testing_profile.h",
    "base/testing_profile_key.cc",
    "base/testing_profile_key.h",
    "base/testing_profile_manager.cc",
    "base/testing_profile_manager.h",
    "base/tracing.cc",
    "base/tracing.h",
    "base/web_feature_histogram_tester.cc",
    "base/web_feature_histogram_tester.h",
  ]

  if (is_chromeos && is_chromeos_device) {
    sources += [
      "base/chromeos/crosier/chromeos_integration_test_mixin.cc",
      "base/chromeos/crosier/chromeos_integration_test_mixin.h",
      "base/chromeos/crosier/chromeos_test_launcher.cc",
      "base/chromeos/crosier/chromeos_test_launcher.h",
      "base/chromeos/crosier/chromeos_test_suite.cc",
      "base/chromeos/crosier/chromeos_test_suite.h",
      "base/chromeos/crosier/power_manager_emitter.cc",
      "base/chromeos/crosier/power_manager_emitter.h",
      "base/chromeos/crosier/upstart.cc",
      "base/chromeos/crosier/upstart.h",
    ]

    if (is_chromeos_ash) {
      sources += [
        "base/chromeos/crosier/chromeos_integration_login_mixin.cc",
        "base/chromeos/crosier/chromeos_integration_login_mixin.h",
        "base/chromeos/crosier/supervised_user_login_delegate.cc",
        "base/chromeos/crosier/supervised_user_login_delegate.h",
      ]

      deps += [ "//ui/ozone/platform/drm:ui_controls" ]

      if (is_chrome_branded) {
        sources += [
          "base/chromeos/crosier/adb_helper.cc",
          "base/chromeos/crosier/adb_helper.h",
          "base/chromeos/crosier/chromeos_integration_arc_mixin.cc",
          "base/chromeos/crosier/chromeos_integration_arc_mixin.h",
        ]
      }
    }

    deps += [
      "base/chromeos/crosier/helper:common",
      "//chromeos/dbus/power:power_manager_proto",
    ]
  }

  if (enable_extensions) {
    sources += [
      "../browser/apps/platform_apps/app_browsertest_util.cc",
      "../browser/apps/platform_apps/app_browsertest_util.h",
      "../browser/extensions/api/braille_display_private/mock_braille_controller.cc",
      "../browser/extensions/api/braille_display_private/mock_braille_controller.h",
      "../browser/extensions/browsertest_util.cc",
      "../browser/extensions/browsertest_util.h",
      "../browser/extensions/extension_api_unittest.cc",
      "../browser/extensions/extension_api_unittest.h",
      "../browser/extensions/extension_apitest.cc",
      "../browser/extensions/extension_apitest.h",
      "../browser/extensions/extension_browsertest.cc",
      "../browser/extensions/extension_browsertest.h",
      "../browser/extensions/extension_service_test_base.cc",
      "../browser/extensions/extension_service_test_base.h",
      "../browser/extensions/extension_service_test_with_install.cc",
      "../browser/extensions/extension_service_test_with_install.h",
      "../browser/extensions/extension_service_user_test_base.cc",
      "../browser/extensions/extension_service_user_test_base.h",
      "../browser/extensions/mixin_based_extension_apitest.cc",
      "../browser/extensions/mixin_based_extension_apitest.h",
      "../browser/extensions/permissions/permissions_test_util.cc",
      "../browser/extensions/permissions/permissions_test_util.h",
      "../browser/extensions/test_extension_environment.cc",
      "../browser/extensions/test_extension_environment.h",
      "../browser/extensions/test_extension_menu_icon_loader.cc",
      "../browser/extensions/test_extension_menu_icon_loader.h",
      "../browser/extensions/test_extension_prefs.cc",
      "../browser/extensions/test_extension_prefs.h",
      "../browser/policy/extension_force_install_mixin.cc",
      "../browser/policy/extension_force_install_mixin.h",
      "../browser/task_manager/task_manager_browsertest_util.cc",
      "../browser/task_manager/task_manager_browsertest_util.h",
      "../browser/task_manager/task_manager_tester.cc",
      "../browser/task_manager/task_manager_tester.h",
      "../browser/ui/web_applications/test/isolated_web_app_test_utils.cc",
      "../browser/ui/web_applications/test/isolated_web_app_test_utils.h",
      "../browser/ui/web_applications/test/ssl_test_utils.cc",
      "../browser/ui/web_applications/test/ssl_test_utils.h",
      "../browser/ui/web_applications/test/test_server_redirect_handle.cc",
      "../browser/ui/web_applications/test/test_server_redirect_handle.h",
      "../browser/ui/web_applications/test/web_app_browsertest_util.cc",
      "../browser/ui/web_applications/test/web_app_browsertest_util.h",
      "../browser/ui/web_applications/web_app_browsertest_base.cc",
      "../browser/ui/web_applications/web_app_browsertest_base.h",
      "../browser/ui/webui/extensions/extension_settings_test_base.cc",
      "../browser/ui/webui/extensions/extension_settings_test_base.h",
      "../common/extensions/manifest_tests/chrome_manifest_test.cc",
      "../common/extensions/manifest_tests/chrome_manifest_test.h",
    ]

    deps += [
      "//build:chromeos_buildflags",
      "//chrome/browser/apps/app_service",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//chrome/renderer/extensions",
      "//components/media_router/browser:test_support",
      "//components/media_router/common:test_support",
      "//components/web_package",
      "//components/web_package/test_support",
      "//components/webapps/browser",
      "//components/webapps/browser:test_support",
      "//extensions/renderer",
      "//extensions/strings",
      "//third_party/zlib/google:zip",
    ]

    public_deps += [
      "//apps:test_support",
      "//chrome/browser/extensions:test_support",
      "//chrome/common/extensions/api",
      "//components/guest_view/browser:test_support",
      "//extensions:test_support",
      "//extensions/browser:test_support",
      "//extensions/common:test_support",
      "//google_apis/common:test_support",
      "//google_apis/drive",
    ]
  }

  # TODO(https://crbug.com/356905053): Continue pulling more common test
  # support pieces into here and eventually merge this with the
  # `enable_extensions` block above.
  if (enable_desktop_android_extensions) {
    deps += [ "//chrome/renderer/extensions" ]

    public_deps += [
      "//extensions:test_support",
      "//extensions/browser:test_support",
      "//extensions/common:test_support",
    ]
  }

  if (toolkit_views) {
    sources += [
      "../browser/ui/views/external_protocol_dialog_test_harness.cc",
      "../browser/ui/views/external_protocol_dialog_test_harness.h",
    ]
  }

  if (is_chrome_branded &&
      (is_mac || is_win || (is_posix && !is_android && !is_chromeos_ash))) {
    sources += [ "base/scoped_channel_override.h" ]
    if (is_mac) {
      sources += [ "base/scoped_channel_override_mac.cc" ]
    } else if (is_win) {
      sources += [ "base/scoped_channel_override_win.cc" ]
    } else if (is_posix && !is_android && !is_chromeos_ash) {
      sources += [ "base/scoped_channel_override_posix.cc" ]
    }
  }

  configs += [ "//build/config:precompiled_headers" ]

  deps += [
    "//build:chromeos_buildflags",
    "//chrome/app:command_ids",
    "//chrome/browser/autofill",
    "//chrome/browser/permissions",
    "//chrome/browser/policy/messaging_layer/proto:log_upload_event_proto",
    "//chrome/browser/policy/messaging_layer/storage_selector",
    "//chrome/browser/search_engines",
    "//chrome/browser/sync",
    "//chrome/browser/ui:browser_element_identifiers",
    "//chrome/browser/ui/color:color_headers",
    "//chrome/browser/ui/webui:configs",
    "//chrome/browser/ui/zoom",
    "//chrome/common/search:mojo_bindings",
    "//components/autofill/content/renderer:test_support",
    "//components/blocked_content:blocked_content",
    "//components/content_settings/browser",
    "//components/enterprise:enterprise",
    "//components/fingerprinting_protection_filter/common:features",
    "//components/infobars/content",
    "//components/input",
    "//components/network_session_configurator/common:common",
    "//components/privacy_sandbox:features",
    "//components/privacy_sandbox:tracking_protection_prefs",
    "//components/privacy_sandbox/privacy_sandbox_attestations/proto:proto",
    "//components/reporting/storage:test_support",
    "//components/reporting/util:status_macros",
    "//components/reporting/util:test_callbacks_support",
    "//components/safe_browsing/content/renderer/phishing_classifier:unit_tests_support",
    "//components/safe_browsing/core/browser/db:v4_database",
    "//components/safe_browsing/core/common",
    "//components/security_interstitials/content:security_interstitial_page",
    "//components/security_interstitials/core:unsafe_resource",
    "//components/segmentation_platform/public",
    "//components/segmentation_platform/public:test_support",
    "//components/signin/core/browser",
    "//components/spellcheck/renderer",
    "//components/subresource_filter/core/browser:test_support",
    "//components/subresource_filter/core/common:test_support",
    "//components/tpcd/metadata/browser",
    "//components/ukm:test_support",
    "//components/user_education/common",
    "//components/user_manager",
    "//components/web_package",
    "//components/webapps/browser:browser",
    "//components/webapps/common",
    "//ui/webui",
  ]

  # New deps should go in the non-iOS section below.
  public_deps += [
    "//base/test:test_support",
    "//chrome:resources",
    "//chrome:strings",
    "//chrome/browser:browser_process",
    "//chrome/browser:test_support",
    "//chrome/browser/media/webrtc",
    "//chrome/browser/safe_browsing",
    "//chrome/browser/supervised_user:test_support",
    "//chrome/child",
    "//chrome/common:non_code_constants",
    "//chrome/common:test_support",
    "//chrome/renderer",
    "//chrome/utility",
    "//components/bookmarks/test",
    "//components/browsing_topics:test_support",
    "//components/captive_portal/core:test_support",
    "//components/consent_auditor:test_support",
    "//components/content_settings/core/browser",
    "//components/content_settings/core/browser:cookie_settings",
    "//components/crash/core/app",
    "//components/custom_handlers/",
    "//components/device_reauth:test_support",
    "//components/domain_reliability",
    "//components/find_in_page",
    "//components/gcm_driver:test_support",
    "//components/gcm_driver/crypto:test_support",
    "//components/gcm_driver/instance_id:test_support",
    "//components/history/core/test",
    "//components/infobars/core",
    "//components/metrics:content",
    "//components/metrics:test_support",
    "//components/network_session_configurator/common",
    "//components/network_time",
    "//components/network_time:network_time_test_support",
    "//components/omnibox/browser:test_support",
    "//components/optimization_guide/core:features",
    "//components/optimization_guide/core:prediction",
    "//components/os_crypt/async/browser:test_support",
    "//components/os_crypt/sync",
    "//components/page_content_annotations/core",
    "//components/page_content_annotations/core:test_support",
    "//components/password_manager/core/browser:test_support",
    "//components/password_manager/core/browser/features:password_features",
    "//components/payments/core:test_support",
    "//components/performance_manager/test_support",
    "//components/permissions",
    "//components/permissions:test_support",
    "//components/policy/core/browser",
    "//components/policy/core/common:test_support",
    "//components/prefs:test_support",
    "//components/privacy_sandbox:test_support",
    "//components/profile_metrics",
    "//components/safe_browsing/core/browser/db:database_manager",
    "//components/safe_browsing/core/browser/db:v4_test_util",
    "//components/safe_browsing/core/browser/tailored_security_service:tailored_security_service",
    "//components/search_engines:test_support",
    "//components/services/storage:storage",
    "//components/services/storage:test_support",
    "//components/sessions:test_support",
    "//components/sharing_message/proto",
    "//components/signin/public/base:test_support",
    "//components/startup_metric_utils",
    "//components/subresource_filter/content/browser",
    "//components/subresource_filter/content/browser:test_support",
    "//components/subresource_filter/content/shared/browser",
    "//components/subresource_filter/core/browser",
    "//components/subresource_filter/core/common",
    "//components/supervised_user/core/browser",
    "//components/supervised_user/core/browser/proto",
    "//components/supervised_user/core/common",
    "//components/supervised_user/core/common",
    "//components/supervised_user/test_support",
    "//components/sync:test_support",
    "//components/sync_preferences",
    "//components/sync_preferences:test_support",
    "//components/sync_sessions:test_support",
    "//components/sync_user_events:test_support",
    "//components/update_client:test_support",
    "//components/user_education/test",
    "//components/user_prefs",
    "//components/variations:test_support",
    "//components/web_resource:test_support",
    "//components/webdata_services",
    "//components/zoom",
    "//components/zoom:test_support",
    "//content/public/app",
    "//content/public/child",
    "//content/public/common",
    "//content/public/renderer",
    "//content/public/utility",
    "//content/test:test_support",
    "//extensions/buildflags",
    "//google_apis:test_support",
    "//gpu/ipc/service",
    "//ipc:test_support",
    "//media:media_buildflags",
    "//net",
    "//net:test_support",
    "//ppapi/buildflags",
    "//printing/buildflags",
    "//services/data_decoder/public/cpp:test_support",
    "//services/device/public/cpp:test_support",
    "//services/device/public/cpp/geolocation",
    "//services/test/echo:lib",
    "//skia",
    "//sql",
    "//sql:test_support",
    "//testing/gmock",
    "//testing/gtest",
    "//third_party/leveldatabase",
    "//ui/base",
    "//ui/base:test_support",
    "//ui/base/emoji",
    "//ui/events:events_base",
    "//ui/gfx:test_support",
    "//ui/gl",
  ]

  data = []
  data_deps = []

  if (enable_pdf) {
    sources += [
      "../browser/pdf/pdf_extension_test_base.cc",
      "../browser/pdf/pdf_extension_test_base.h",
      "../browser/pdf/test_pdf_viewer_stream_manager.cc",
      "../browser/pdf/test_pdf_viewer_stream_manager.h",
    ]

    deps += [
      "../browser/pdf",
      "../browser/pdf:pdf_extension_test_utils",
      "//components/pdf/browser",
      "//pdf:features",
    ]
  }

  if (enable_printing) {
    sources += [
      "../browser/printing/print_test_utils.cc",
      "../browser/printing/print_test_utils.h",
    ]

    if (is_chromeos) {
      sources += [
        "chromeos/printing/fake_local_printer_chromeos.cc",
        "chromeos/printing/fake_local_printer_chromeos.h",
        "chromeos/printing/mock_local_printer_chromeos.cc",
        "chromeos/printing/mock_local_printer_chromeos.h",
      ]
      if (use_cups) {
        sources += [
          "../browser/extensions/api/printing/fake_print_job_controller.cc",
          "../browser/extensions/api/printing/fake_print_job_controller.h",
          "../browser/extensions/api/printing/printing_test_utils.cc",
          "../browser/extensions/api/printing/printing_test_utils.h",
        ]
        public_deps += [
          "//chrome/services/printing/public/mojom",
          "//chromeos/printing:printing",
          "//printing/backend:test_support",
        ]
      }
    }

    public_deps += [
      "//printing",
      "//printing/backend",
      "//printing/mojom",
    ]
  }

  if (enable_print_preview) {
    sources += [
      "../browser/printing/browser_printing_context_factory_for_test.cc",
      "../browser/printing/browser_printing_context_factory_for_test.h",
    ]

    public_deps += [ "//printing:test_support" ]
  }

  if (is_chromeos_lacros && also_build_ash_chrome) {
    data_deps += [
      "//chrome/test:test_ash_chrome(//build/toolchain/linux:ash_clang_x64)",
    ]
  }

  if (is_chromeos_ash && also_build_lacros_chrome) {
    data_deps += [
      # TODO(crbug.com/40281506): Try to drop building ordinary Lacros binary.
      "//chrome:chrome(//build/toolchain/linux:lacros_clang_x64)",
      "//chrome/test:test_lacros_chrome(//build/toolchain/linux:lacros_clang_x64)",
    ]
  }

  if (is_linux) {
    data_deps += [ "//components/crash/core/app:chrome_crashpad_handler" ]
  }

  if (is_android) {
    public_deps += [
      ":test_support_ui_android",
      "//chrome:chrome_android_core",
      "//components/feed/core/v2:feed_core_stubs",
    ]

    sources += [
      "../browser/ui/autofill/autofill_keyboard_accessory_controller_impl_test_api.h",
      "../browser/webapps/installable/ml_promotion_browsertest_base.cc",
      "../browser/webapps/installable/ml_promotion_browsertest_base.h",
    ]

    allow_circular_includes_from = [ ":test_support_ui_android" ]
  } else {
    public_deps += [
      # Android uses //chrome:chrome_android_core instead of the //chrome/app
      # target.
      ":test_support_ui",
      "//chrome/app:test_support",
      "//chrome/browser:test_support",
      "//chrome/browser/ui/views/toolbar",
      "//chrome/browser/web_applications",
      "//components/crx_file",
      "//components/enterprise/common/proto:connectors_proto",
      "//components/keep_alive_registry",
      "//components/pref_registry",
      "//components/renderer_context_menu",
      "//components/services/app_service/public/cpp:test_support",
      "//components/storage_monitor",
      "//components/storage_monitor:test_support",
      "//components/ukm:test_support",
      "//components/ukm:ukm_test_helper",
      "//components/web_modal",
      "//ui/compositor:test_support",
      "//ui/snapshot",
    ]

    # Non-android deps for "test_support" target.
    deps += [
      "//chrome/browser/apps/link_capturing",
      "//chrome/browser/task_manager",
      "//chrome/browser/themes",
      "//chrome/browser/ui/apps",
      "//chrome/browser/ui/find_bar",
      "//chrome/browser/ui/webui/top_chrome",
      "//components/constrained_window",
      "//components/performance_manager",
      "//components/performance_manager/test_support:test_support_common",
      "//components/segmentation_platform/public:public",
    ]

    sources += [
      "../browser/badging/test_badge_manager_delegate.cc",
      "../browser/badging/test_badge_manager_delegate.h",
      "../browser/banners/test_app_banner_manager_desktop.cc",
      "../browser/banners/test_app_banner_manager_desktop.h",
      "../browser/download/download_browsertest_utils.cc",
      "../browser/download/download_browsertest_utils.h",
      "../browser/net/profile_network_context_service_test_utils.cc",
      "../browser/net/profile_network_context_service_test_utils.h",
      "../browser/performance_manager/test_support/fake_child_process_tuning_delegate.cc",
      "../browser/performance_manager/test_support/fake_child_process_tuning_delegate.h",
      "../browser/performance_manager/test_support/fake_frame_throttling_delegate.cc",
      "../browser/performance_manager/test_support/fake_frame_throttling_delegate.h",
      "../browser/performance_manager/test_support/fake_freezing_delegate.cc",
      "../browser/performance_manager/test_support/fake_freezing_delegate.h",
      "../browser/performance_manager/test_support/fake_memory_saver_mode_delegate.cc",
      "../browser/performance_manager/test_support/fake_memory_saver_mode_delegate.h",
      "../browser/performance_manager/test_support/fake_power_monitor_source.cc",
      "../browser/performance_manager/test_support/fake_power_monitor_source.h",
      "../browser/performance_manager/test_support/page_discarding_utils.cc",
      "../browser/performance_manager/test_support/page_discarding_utils.h",
      "../browser/performance_manager/test_support/site_data_utils.cc",
      "../browser/performance_manager/test_support/site_data_utils.h",
      "../browser/performance_manager/test_support/test_user_performance_tuning_manager_environment.cc",
      "../browser/performance_manager/test_support/test_user_performance_tuning_manager_environment.h",
      "../browser/preloading/preview/preview_test_util.cc",
      "../browser/preloading/preview/preview_test_util.h",
      "../browser/renderer_context_menu/mock_render_view_context_menu.cc",
      "../browser/renderer_context_menu/mock_render_view_context_menu.h",
      "../browser/renderer_context_menu/render_view_context_menu_browsertest_util.cc",
      "../browser/renderer_context_menu/render_view_context_menu_browsertest_util.h",
      "../browser/renderer_context_menu/render_view_context_menu_test_util.cc",
      "../browser/renderer_context_menu/render_view_context_menu_test_util.h",
      "../browser/signin/signin_browser_test_base.h",
      "../browser/sync_file_system/mock_local_change_processor.cc",
      "../browser/sync_file_system/mock_local_change_processor.h",
      "../browser/sync_file_system/mock_remote_file_sync_service.cc",
      "../browser/sync_file_system/mock_remote_file_sync_service.h",
      "../browser/themes/test/theme_service_changed_waiter.cc",
      "../browser/themes/test/theme_service_changed_waiter.h",
      "../browser/ui/autofill/autofill_popup_controller_impl_test_api.h",
      "../browser/ui/autofill/mock_autofill_popup_controller.cc",
      "../browser/ui/autofill/mock_autofill_popup_controller.h",
      "../browser/ui/performance_controls/test_support/battery_saver_browser_test_mixin.h",
      "../browser/ui/performance_controls/test_support/memory_metrics_refresh_waiter.cc",
      "../browser/ui/performance_controls/test_support/memory_metrics_refresh_waiter.h",
      "../browser/ui/performance_controls/test_support/memory_saver_browser_test_mixin.h",
      "../browser/ui/performance_controls/test_support/memory_saver_interactive_test_mixin.h",
      "../browser/ui/performance_controls/test_support/resource_usage_collector_observer.cc",
      "../browser/ui/performance_controls/test_support/resource_usage_collector_observer.h",
      "../browser/ui/profiles/profile_ui_test_utils.h",
      "../browser/ui/tabs/pinned_tab_test_utils.cc",
      "../browser/ui/tabs/pinned_tab_test_utils.h",
      "../browser/ui/tabs/test_util.cc",
      "../browser/ui/tabs/test_util.h",
      "../browser/ui/test/pixel_test_configuration_mixin.cc",
      "../browser/ui/test/pixel_test_configuration_mixin.h",
      "../browser/ui/test/test_browser_dialog.cc",
      "../browser/ui/test/test_browser_dialog.h",
      "../browser/ui/test/test_browser_ui.cc",
      "../browser/ui/test/test_browser_ui.h",
      "../browser/ui/views/performance_controls/test_support/discard_mock_navigation_handle.cc",
      "../browser/ui/views/performance_controls/test_support/discard_mock_navigation_handle.h",
      "../browser/ui/views/performance_controls/test_support/memory_saver_unit_test_mixin.h",
      "../browser/ui/webui/identity_internals_ui_browsertest.cc",
      "../browser/ui/webui/identity_internals_ui_browsertest.h",
      "../browser/ui/webui/net_internals/net_internals_ui_browsertest.cc",
      "../browser/ui/webui/net_internals/net_internals_ui_browsertest.h",
      "../browser/ui/webui/test_support/webui_interactive_test_mixin.h",
      "../browser/webapps/installable/ml_promotion_browsertest_base.cc",
      "../browser/webapps/installable/ml_promotion_browsertest_base.h",
      "../test/base/browser_with_test_window_test.cc",
      "../test/base/browser_with_test_window_test.h",
      "base/dialog_test_browser_window.cc",
      "base/dialog_test_browser_window.h",
      "base/test_browser_window.cc",
      "base/test_browser_window.h",
    ]
    allow_circular_includes_from = [ ":test_support_ui" ]
  }

  if (use_nss_certs) {
    public_configs = [ "//build/config/linux/nss" ]
  }

  if (is_mac) {
    sources += [
      "//chrome/app/chrome_crash_reporter_client.cc",
      "//chrome/app/chrome_crash_reporter_client_mac.mm",
      "base/launchservices_utils_mac.h",
      "base/launchservices_utils_mac.mm",
      "base/scoped_bundle_swizzler_mac.h",
      "base/scoped_bundle_swizzler_mac.mm",
    ]
    deps += [
      "//build:branding_buildflags",
      "//chrome/app_shim",
      "//components/upload_list",
    ]
    public_deps += [ "//components/crash/core/app" ]
  }

  if (use_aura) {
    deps += [ "//ui/events:test_support" ]
  }

  if (is_win) {
    sources += [
      "../browser/webshare/win/fake_buffer.cc",
      "../browser/webshare/win/fake_buffer.h",
      "../browser/webshare/win/fake_data_transfer_manager.cc",
      "../browser/webshare/win/fake_data_transfer_manager.h",
      "../browser/webshare/win/fake_data_transfer_manager_interop.cc",
      "../browser/webshare/win/fake_data_transfer_manager_interop.h",
      "../browser/webshare/win/fake_data_writer_factory.cc",
      "../browser/webshare/win/fake_data_writer_factory.h",
      "../browser/webshare/win/fake_iasync_operation_with_progress.h",
      "../browser/webshare/win/fake_random_access_stream.cc",
      "../browser/webshare/win/fake_random_access_stream.h",
      "../browser/webshare/win/fake_storage_file_statics.cc",
      "../browser/webshare/win/fake_storage_file_statics.h",
      "../browser/webshare/win/fake_uri_runtime_class_factory.cc",
      "../browser/webshare/win/fake_uri_runtime_class_factory.h",
      "../browser/webshare/win/scoped_fake_data_transfer_manager_interop.cc",
      "../browser/webshare/win/scoped_fake_data_transfer_manager_interop.h",
      "../browser/webshare/win/scoped_share_operation_fake_components.cc",
      "../browser/webshare/win/scoped_share_operation_fake_components.h",
      "//chrome/app/chrome_crash_reporter_client_win.cc",
      "base/process_inspector_win.cc",
      "base/process_inspector_win.h",
      "base/process_lineage_win.cc",
      "base/process_lineage_win.h",
    ]
    deps += [ "//chrome/chrome_elf:constants" ]
    public_deps += [
      "//chrome/chrome_elf:crash",
      "//chrome/install_static/test:test_support",
      "//components/crash/core/app",
      "//third_party/wtl",
    ]
    libs = [ "runtimeobject.lib" ]
  }

  if (is_chromeos) {
    sources += [
      "../browser/app_mode/test/accelerator_helpers.cc",
      "../browser/apps/app_service/metrics/website_metrics_browser_test_mixin.cc",
      "../browser/apps/app_service/metrics/website_metrics_browser_test_mixin.h",
      "../browser/certificate_provider/test_certificate_provider_extension.cc",
      "../browser/certificate_provider/test_certificate_provider_extension.h",
      "../browser/extensions/policy_test_utils.cc",
      "../browser/extensions/policy_test_utils.h",
      "../browser/ui/views/frame/immersive_mode_tester.cc",
      "../browser/ui/views/frame/immersive_mode_tester.h",
      "../browser/web_applications/isolated_web_apps/isolated_web_app_update_server_mixin.cc",
      "../browser/web_applications/isolated_web_apps/isolated_web_app_update_server_mixin.h",
      "base/chromeos/crosier/annotations.cc",
      "base/chromeos/crosier/annotations.h",
      "base/chromeos/crosier/aura_window_title_observer.cc",
      "base/chromeos/crosier/aura_window_title_observer.h",
      "base/chromeos/crosier/crosier_util.cc",
      "base/chromeos/crosier/crosier_util.h",
    ]

    if (is_chrome_branded && is_chromeos_ash) {
      sources += [
        "base/chromeos/crosier/gaia_host_util.cc",
        "base/chromeos/crosier/gaia_host_util.h",
        "base/chromeos/crosier/test_accounts.cc",
        "base/chromeos/crosier/test_accounts.h",
      ]
      data += [
        "../browser/internal/resources/chromeos/crosier/test_accounts.json",
      ]
    }

    deps += [
      "base/chromeos/crosier:proto",
      "//base/test:proto_test_support",
      "//chrome/browser/chromeos",
      "//chrome/browser/chromeos/policy/dlp",
      "//chrome/browser/ui/chromeos",
      "//chromeos/components/mgs",
      "//chromeos/dbus/constants",
    ]
    public_deps += [ "//chromeos/constants" ]
  }

  if (is_chromeos_ash) {
    sources += [
      "../browser/certificate_provider/test_certificate_provider_extension_mixin.cc",
      "../browser/certificate_provider/test_certificate_provider_extension_mixin.h",
      "../browser/chromeos/extensions/login_screen/login_screen_apitest_base.cc",
      "../browser/chromeos/extensions/login_screen/login_screen_apitest_base.h",
      "../browser/enterprise/connectors/analysis/mock_file_transfer_analysis_delegate.cc",
      "../browser/enterprise/connectors/analysis/mock_file_transfer_analysis_delegate.h",
      "../browser/enterprise/connectors/analysis/source_destination_test_util.cc",
      "../browser/enterprise/connectors/analysis/source_destination_test_util.h",
      "base/ash/js_test_api.cc",
      "base/ash/js_test_api.h",
      "base/ash/scoped_test_system_nss_key_slot_mixin.cc",
      "base/ash/scoped_test_system_nss_key_slot_mixin.h",
      "base/browser_process_platform_part_test_api_chromeos.cc",
      "base/browser_process_platform_part_test_api_chromeos.h",
      "base/chromeos/ash_browser_test_starter.cc",
      "base/chromeos/ash_browser_test_starter.h",
      "base/chromeos/lacros_only_mocha_browser_test.cc",
      "base/chromeos/lacros_only_mocha_browser_test.h",

      # Only used for Chromevox tests, so only included on Chrome OS.
      "base/ash/extension_js_browser_test.cc",
      "base/ash/extension_js_browser_test.h",
    ]

    public_deps += [
      "//ash",
      "//ash:test_support",
      "//ash/constants",
      "//ash/public/cpp:test_support",
      "//ash/webui/diagnostics_ui:url_constants",
      "//ash/webui/firmware_update_ui:url_constants",
      "//ash/webui/graduation:url_constants",
      "//ash/webui/os_feedback_ui:url_constants",
      "//ash/webui/personalization_app:test_support",
      "//ash/webui/print_management:url_constants",
      "//ash/webui/print_preview_cros:url_constants",
      "//ash/webui/sanitize_ui:url_constants",
      "//ash/webui/scanning:url_constants",
      "//ash/webui/shortcut_customization_ui:url_constants",
      "//chrome/browser/ash/app_mode",
      "//chrome/browser/ash/file_manager",
      "//chrome/browser/ash/login/enrollment",
      "//chrome/browser/ash/login/enrollment:test_support",
      "//chrome/browser/ash/login/test:test_support",
      "//chrome/browser/ash/login/users:test_support",
      "//chrome/browser/ash/profiles",
      "//chrome/browser/ash/settings:test_support",
      "//chrome/browser/ash/system_web_apps",
      "//chromeos/ash/components/account_manager",
      "//chromeos/ash/components/dbus/session_manager",
      "//chromeos/ash/components/dbus/userdataauth",
      "//chromeos/ash/components/install_attributes:test_support",
      "//chromeos/ash/components/login/auth:test_support",
      "//chromeos/ash/components/login/login_state",
      "//chromeos/ash/components/settings",
      "//chromeos/ash/components/tpm",
      "//chromeos/dbus/tpm_manager",
      "//components/exo",
      "//components/ownership",
      "//components/user_manager:test_support",
      "//ui/aura",
      "//ui/aura:test_support",
      "//ui/base/ime/init",
      "//ui/chromeos/resources:resources_grit",
    ]

    deps += [
      "//ash/constants",
      "//chrome/browser/ash/app_list/arc",
      "//chrome/browser/ash/arc",
      "//chrome/browser/ash/arc/boot_phase_monitor",
      "//chrome/browser/ash/arc/session",
      "//chrome/browser/ash/crosapi",
      "//chrome/browser/ash/dbus",
      "//chrome/browser/ash/extensions",
      "//chrome/browser/ash/guest_os",
      "//chrome/browser/ash/guest_os/public",
      "//chrome/browser/ash/input_method",
      "//chrome/browser/ash/login/session:test_support",
      "//chrome/browser/ash/login/users",
      "//chrome/browser/ash/net",
      "//chrome/browser/ash/policy/core:test_support",
      "//chrome/browser/ash/policy/test_support",
      "//chrome/browser/ash/printing",
      "//chrome/browser/ash/printing:test_support",
      "//chrome/browser/ash/printing/history:print_job_info_proto",
      "//chrome/browser/ash/settings",
      "//chrome/browser/ash/system_web_apps/test_support",
      "//chrome/browser/ui/ash",
      "//chrome/browser/ui/ash/cast_config",
      "//chrome/browser/ui/ash/system_web_apps",
      "//chrome/browser/ui/webui/ash/login",
      "//chromeos/ash/components/attestation:test_support",
      "//chromeos/ash/components/browser_context_helper",
      "//chromeos/ash/components/cryptohome",
      "//chromeos/ash/components/dbus",
      "//chromeos/ash/components/dbus/concierge",
      "//chromeos/ash/components/dbus/shill",
      "//chromeos/ash/components/disks:test_support",
      "//chromeos/ash/components/nearby/common/connections_manager",
      "//chromeos/ash/components/standalone_browser:test_support",
      "//chromeos/ash/components/system",
      "//chromeos/dbus/power",
      "//components/component_updater/ash",
      "//components/component_updater/ash:test_support",
      "//components/policy/test_support",
      "//crypto:test_support",
      "//google_apis",
      "//google_apis:test_support",
      "//net:test_support",
    ]

    allow_circular_includes_from += [
      "//chrome/browser/ash/login/users:test_support",
      "//chrome/browser/ash/settings:test_support",
    ]
  }

  if (is_chromeos_lacros) {
    public_deps += [
      "//components/enterprise/data_controls/core/browser:dlp_policy_event_proto",
      "//components/reporting/client:report_queue",
      "//components/reporting/client:test_support",
      "//components/reporting/storage:test_support",
      "//components/reporting/util:test_callbacks_support",
    ]
    deps += [
      "//chromeos/lacros",
      "//chromeos/lacros:test_support",
      "//chromeos/services/machine_learning/public/cpp:stub",
      "//chromeos/startup",
      "//chromeos/ui/base",
      "//components/account_manager_core:test_support",
    ]
  }

  if (is_win || is_mac || is_linux || is_chromeos) {
    public_deps += [
      "//ui/base:pixel_diff_test_support",
      "//ui/views:view_pixel_diff_test_support",
    ]
  }

  if (use_aura) {
    sources += [
      "base/test_browser_window_aura.cc",
      "base/test_browser_window_aura.h",
    ]
    deps += [
      "//ui/aura:test_support",
      "//ui/wm",
      "//ui/wm/public",
    ]
  }

  if (toolkit_views) {
    sources += [
      "../browser/password_manager/password_manager_uitest_util.cc",
      "../browser/password_manager/password_manager_uitest_util.h",
      "../browser/ui/chooser_bubble_testapi.h",
      "../browser/ui/views/chooser_bubble_testapi_views.cc",
      "../browser/ui/views/desktop_capture/desktop_media_picker_views_test_api.cc",
      "../browser/ui/views/desktop_capture/desktop_media_picker_views_test_api.h",
      "../browser/ui/views/frame/test_with_browser_view.cc",
      "../browser/ui/views/frame/test_with_browser_view.h",
      "../browser/ui/views/media_router/app_menu_test_api.h",
      "../browser/ui/views/media_router/app_menu_test_api_views.cc",
      "../browser/ui/views/omnibox/omnibox_popup_view_views_test.cc",
      "../browser/ui/views/omnibox/omnibox_popup_view_views_test.h",
      "../browser/ui/views/omnibox/omnibox_popup_view_webui_test.cc",
      "../browser/ui/views/omnibox/omnibox_popup_view_webui_test.h",
      "../browser/ui/views/profiles/profile_picker_view_test_utils.cc",
      "../browser/ui/views/profiles/profile_picker_view_test_utils.h",
      "../browser/ui/views/profiles/profiles_pixel_test_utils.cc",
      "../browser/ui/views/profiles/profiles_pixel_test_utils.h",
      "../browser/ui/views/web_apps/frame_toolbar/web_app_frame_toolbar_test_helper.cc",
      "../browser/ui/views/web_apps/frame_toolbar/web_app_frame_toolbar_test_helper.h",
      "base/test_theme_provider.cc",
      "base/test_theme_provider.h",
      "views/accessibility_checker.cc",
      "views/accessibility_checker.h",
      "views/chrome_test_views_delegate.h",
      "views/chrome_test_widget.cc",
      "views/chrome_test_widget.h",
      "views/chrome_views_test_base.cc",
      "views/chrome_views_test_base.h",
    ]
    public_deps += [
      "//chrome/browser/media/router:media_router_feature",
      "//ui/views:test_support",
    ]
    deps += [
      "//chrome/browser/ui/color:mixers",
      "//components/color",
      "//components/user_education/views",
    ]
  }

  if (enable_message_center) {
    public_deps += [ "//ui/message_center:test_support" ]
  }

  if (enable_offline_pages) {
    public_deps += [ "//components/offline_pages/core:test_support" ]
  }

  if (enable_ppapi) {
    public_deps += [ "//ppapi/shared_impl" ]
  }

  if (enable_compose) {
    sources += [
      "../browser/compose/mock_chrome_compose_client.cc",
      "../browser/compose/mock_chrome_compose_client.h",
    ]
  }

  if (is_win || is_mac || is_linux) {
    sources += [
      "../browser/enterprise/signin/mock_oidc_authentication_signin_interceptor.cc",
      "../browser/enterprise/signin/mock_oidc_authentication_signin_interceptor.h",
      "../browser/enterprise/signin/mock_user_policy_oidc_signin_service.cc",
      "../browser/enterprise/signin/mock_user_policy_oidc_signin_service.h",
    ]
  }
}

if (is_android) {
  template("telemetry_gpu_integration_test_android_template") {
    forward_variables_from(invoker, [ "telemetry_target_suffix" ])

    # For Android tests, prepend the logdog_wrapper.py tool to the command,
    # which will automatically stream the device's logcats to logdog.
    generate_wrapper(target_name) {
      executable = "../../build/android/test_wrapper/logdog_wrapper.py"
      wrapper_script = "$root_out_dir/bin/run_${target_name}"
      executable_args = [
        "../../testing/scripts/run_gpu_integration_test_as_googletest.py",
        "../../content/test/gpu/run_gpu_integration_test.py",
        "--chromium-output-directory=@WrappedPath(.)",
      ]

      testonly = true
      data_deps = [
        "//build/android:logdog_wrapper_py",
        "//content/test:telemetry_gpu_integration_test_support",
        "//tools/perf/chrome_telemetry_build:telemetry_chrome_test${telemetry_target_suffix}",
      ]
    }
  }

  foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
    telemetry_gpu_integration_test_android_template(
        "telemetry_gpu_integration_test${_target_suffix}") {
      telemetry_target_suffix = _target_suffix
    }
  }
} else {
  _telemetry_args = [
    "../../content/test/gpu/run_gpu_integration_test.py",
    "--chromium-output-directory=@WrappedPath(.)",
  ]
  _telemetry_data_deps = [
    "//content/test:telemetry_gpu_integration_test_support",
    "//tools/perf/chrome_telemetry_build:telemetry_chrome_test",
  ]
  if (is_chromeos_ash && is_chromeos_device) {
    cros_test_wrapper_script_test("telemetry_gpu_integration_test") {
      args = [ "../../testing/scripts/run_gpu_integration_test_as_googletest.py" ] + _telemetry_args
      data_deps = _telemetry_data_deps
    }
  } else {
    script_test("telemetry_gpu_integration_test") {
      script = "//testing/scripts/run_gpu_integration_test_as_googletest.py"
      args = _telemetry_args

      data_deps = _telemetry_data_deps
    }
  }
}

if (is_win) {
  source_set("credential_provider_test_utils") {
    testonly = true
    sources = [
      "../browser/ui/startup/credential_provider_signin_dialog_win_test_data.cc",
      "../browser/ui/startup/credential_provider_signin_dialog_win_test_data.h",
    ]
    deps = [
      "//base",
      "//chrome/credential_provider/common:common_constants",
    ]
  }
}

if (is_chromeos && is_chromeos_device) {
  if (is_chromeos_ash) {
    copy("crosier_metadata") {
      sources = [ "base/chromeos/crosier/ash_integration_test_test.yaml" ]
      outputs = [ "$root_out_dir/crosier_metadata/{{source_file_part}}" ]
    }

    copy("crosier_js_helpers") {
      sources = [ "../browser/ash/accessibility/google_tts_test_support.js" ]
      outputs = [ "$root_out_dir/crosier_js_helpers/{{source_file_part}}" ]
    }

    static_library("ash_integration_test_support") {
      testonly = true

      defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]

      sources = [
        # These cannot live in ":test_support" because they use
        # InProcessBrowserTest which requires HAS_OUT_OF_PROC_TEST_RUNNER.
        "base/chromeos/crosier/ash_integration_test.cc",
        "base/chromeos/crosier/ash_integration_test.h",
        "base/chromeos/crosier/supervised_user_integration_base_test.cc",
        "base/chromeos/crosier/supervised_user_integration_base_test.h",
      ]

      deps = [
        ":test_support",
        "//base",
        "//build:branding_buildflags",
        "//chrome/browser/ash/crosapi",
        "//chrome/browser/ui/ash/main_extra_parts",
        "//chrome/common:non_code_constants",
        "//chrome/test/base/ash/interactive:test_support",
        "//chromeos/ash/components/standalone_browser",
        "//chromeos/ash/components/standalone_browser:test_support",
        "//google_apis",
        "//net:test_support",
        "//url",
      ]
    }
  }

  test("chromeos_integration_tests") {
    configs += [ "//build/config:precompiled_headers" ]
    defines = [
      "HAS_OUT_OF_PROC_TEST_RUNNER",
      "CHROME_VERSION_MAJOR=" + chrome_version_major,
    ]
    sources = [
      "base/chromeos/crosier/chromeos_tests_main.cc",
      "base/chromeos/crosier/demo_integration_test.cc",
    ]
    deps = [
      ":test_support",
      "//components/app_constants",
    ]
    data_deps = []
    if (also_build_lacros_chrome_for_architecture != "") {
      data_deps += [ "//chrome:chrome(//build/toolchain/cros:lacros_clang)" ]
    }
    if (is_chromeos_ash) {
      # Note: for each test case in the below list, add a metadata file
      # in the `crosier_metadata` build rule above.
      sources += [
        "base/chromeos/crosier/ash_integration_test_test.cc",
        "base/chromeos/crosier/helper/test_sudo_helper_client_test.cc",
        "base/chromeos/crosier/upstart_test.cc",
      ]

      if (is_chrome_branded) {
        sources += [ "base/chromeos/crosier/test_accounts_test.cc" ]
      }

      data = [
        "//chrome/test/data/chromeos/web_handwriting/",
        "//chrome/test/data/scanning/",
      ]

      deps += [
        ":ash_integration_test_support",
        "//chrome/browser/ash/file_manager",
        "//chrome/browser/ui/ash",
        "//chrome/test/base/chromeos/crosier:proto",
        "//chrome/test/base/chromeos/crosier/helper:common",
        "//chromeos/ash/components/dbus/printscanmgr:printscanmgr",
        "//ui/events:test_support",

        # Gather tests from other build files:
        "//chrome/browser/ash:integration_tests",
        "//chrome/browser/ui/ash:integration_tests",
        "//chrome/browser/ui/webui/ash:integration_tests",
      ]

      data_deps += [
        ":crosier_js_helpers",
        ":crosier_metadata",
        "//chrome/test/base/chromeos/crosier/helper",
        "//chrome/test/base/chromeos/crosier/helper/fake_chrome",
      ]
    }
  }
}

if (is_android) {
  test("android_browsertests") {
    configs += [ "//build/config:precompiled_headers" ]
    defines = [
      "HAS_OUT_OF_PROC_TEST_RUNNER",
      "CHROME_VERSION_MAJOR=" + chrome_version_major,
    ]
    use_default_launcher = false
    android_manifest =
        "${target_gen_dir}/android_browsertests_manifest/AndroidManifest.xml"
    android_manifest_dep = ":android_browsertests_manifest"

    if (!is_java_debug) {
      proguard_enabled = true
      proguard_configs = [ "//chrome/android/proguard/main.flags" ]
    }

    deps = [
      ":android_browsertests_assets",
      ":android_browsertests_java",
      ":browser_tests_runner",
      ":chrome_test_launcher",
      ":sync_integration_test_support",
      ":sync_integration_test_support_java",
      ":test_support",
      ":test_support_java",
      ":test_support_jni_headers",
      ":test_support_ui_android",
      "//build:chromeos_buildflags",
      "//chrome:chrome_android_core",
      "//chrome/android:delegate_public_impl_java",
      "//chrome/browser/autofill",
      "//chrome/browser/browsing_data:constants",
      "//chrome/browser/dips:browser_tests",
      "//chrome/browser/flags:flags_android",
      "//chrome/browser/ip_protection:browser_tests",
      "//chrome/browser/metrics:test_support",
      "//chrome/browser/payments:browser_tests",
      "//chrome/browser/policy:browser_tests",
      "//chrome/browser/policy:test_support",
      "//chrome/browser/preloading/prefetch:browser_tests",
      "//chrome/browser/preloading/prerender:browser_tests",
      "//chrome/browser/privacy_budget:browser_tests",
      "//chrome/browser/profiling_host:profiling_browsertests",
      "//chrome/browser/segmentation_platform:test_utils",
      "//chrome/browser/sync",
      "//chrome/browser/ui/android/hats/test:test_support",
      "//chrome/browser/ui/autofill/payments:android_browsertests",
      "//chrome/browser/ui/tabs:tab_enums",
      "//chrome/browser/webaudio:browser_tests",
      "//chrome/test/android:live_signin_test_util_public_impl_java",
      "//components/autofill/content/renderer:test_support",
      "//components/blocked_content",
      "//components/browser_ui/widget/android:java",
      "//components/browsing_data/content:content",
      "//components/browsing_data/content:test_support",
      "//components/commerce/core:commerce_heuristics_data",
      "//components/commerce/core:feature_list",
      "//components/commerce/core:persisted_state_db_content_proto",
      "//components/content_settings/browser:browser",
      "//components/crash/android:crashpad_main",
      "//components/feed:feature_list",
      "//components/feed/core/v2:feed_core_v2",
      "//components/feed/core/v2:ios_shared",
      "//components/feed/core/v2:test_helpers",
      "//components/feed/mojom:mojo_bindings",
      "//components/infobars/content",
      "//components/metrics:content",
      "//components/metrics/demographics",
      "//components/metrics/demographics:test_support",
      "//components/metrics_services_manager",
      "//components/optimization_guide/core",
      "//components/page_content_annotations/core",
      "//components/page_load_metrics/browser:test_support",
      "//components/page_load_metrics/browser/observers/ad_metrics:test_support",
      "//components/privacy_sandbox:privacy_sandbox",
      "//components/privacy_sandbox:privacy_sandbox_prefs",
      "//components/privacy_sandbox:tracking_protection_onboarding",
      "//components/privacy_sandbox:tracking_protection_prefs",
      "//components/privacy_sandbox:tracking_protection_settings",
      "//components/qr_code_generator:bitmap_generator",
      "//components/safe_browsing/core/browser/db:v4_database",
      "//components/safe_browsing/core/common",
      "//components/security_interstitials/core:unsafe_resource",
      "//components/security_state/content",
      "//components/security_state/content/android",
      "//components/segmentation_platform/embedder/default_model",
      "//components/segmentation_platform/internal:internal",
      "//components/segmentation_platform/internal:test_support",
      "//components/session_proto_db:session_proto_db",
      "//components/signin/public/identity_manager",
      "//components/signin/public/identity_manager:test_support",
      "//components/site_isolation",
      "//components/subresource_filter/core/browser:test_support",
      "//components/subresource_filter/core/common:test_support",
      "//components/sync:test_support",
      "//components/ukm:test_support",
      "//components/ukm:ukm_test_helper",
      "//components/ukm/content",
      "//components/unified_consent",
      "//components/variations/service",
      "//components/webapk:proto",
      "//components/webapps/browser",

      # TODO(crbug.com/40626932): This is needed for ShellManager which is what
      # the ChromeBrowserTestsActivity is using to build the java UI. It's
      # likely we want to replace it with something new that uses ChromeWindow
      # and CompositorViewHolder instead.
      "//content/shell:content_shell_lib",
      "//content/test:android_test_message_pump_support",
      "//testing/android/native_test:native_test_support",
    ]

    sources = [
      "../browser/accessibility/accessibility_prefs/android/accessibility_android_policy_browsertest.cc",
      "../browser/accessibility/accessibility_prefs/android/accessibility_prefs_controller_browsertest.cc",
      "../browser/android/auxiliary_search/auxiliary_search_provider_browsertest.cc",
      "../browser/android/cookies/cookies_fetcher_restore_util_browsertest.cc",
      "../browser/android/customtabs/custom_tabs_browsertest.cc",
      "../browser/android/customtabs/tab_interaction_recorder_browsertest.cc",
      "../browser/android/historical_tab_saver_browsertest.cc",
      "../browser/android/persisted_tab_data/persisted_tab_data_android_browsertest.cc",
      "../browser/android/persisted_tab_data/sensitivity_persisted_tab_data_android_browsertest.cc",
      "../browser/android/persisted_tab_data/test/bar_persisted_tab_data.cc",
      "../browser/android/persisted_tab_data/test/bar_persisted_tab_data.h",
      "../browser/android/persisted_tab_data/test/foo_persisted_tab_data.cc",
      "../browser/android/persisted_tab_data/test/foo_persisted_tab_data.h",
      "../browser/android/webapk/webapk_icons_hasher_browsertest.cc",
      "../browser/android/webapk/webapk_installer_browsertest.cc",
      "../browser/android/webapk/webapk_restore_task_browsertest.cc",
      "../browser/android/webview_renderer_extension_browsertest.cc",
      "../browser/banners/android/ambient_badge_manager_browsertest.cc",
      "../browser/banners/app_banner_manager_browsertest.cc",
      "../browser/banners/app_banner_manager_browsertest_base.cc",
      "../browser/banners/app_banner_manager_browsertest_base.h",
      "../browser/browsing_data/browsing_data_remover_browsertest_base.cc",
      "../browser/browsing_data/browsing_data_remover_browsertest_base.h",
      "../browser/browsing_data/chrome_browsing_data_lifetime_manager_browsertest.cc",
      "../browser/engagement/important_sites_util_browsertest.cc",
      "../browser/enterprise/remote_commands/user_remote_commands_service_browsertest.cc",
      "../browser/enterprise/reporting/cloud_profile_reporting_browsertest.cc",
      "../browser/fast_checkout/fast_checkout_tab_helper_browsertest.cc",
      "../browser/feed/rss_links_fetcher_browsertest.cc",
      "../browser/metrics/metrics_log_browsertest.cc",
      "../browser/metrics/metrics_service_user_demographics_browsertest.cc",
      "../browser/metrics/sampled_out_client_id_saved_browsertest.cc",
      "../browser/metrics/startup_metrics_browsertest.cc",
      "../browser/metrics/ukm_browsertest.cc",
      "../browser/net/cert_verifier_policy_browsertest.cc",
      "../browser/net/cert_verifier_service_browsertest.cc",
      "../browser/net/cert_verify_proc_browsertest.cc",
      "../browser/page_load_metrics/observers/ad_metrics/ad_density_intervention_android_browsertest.cc",
      "../browser/password_manager/android/password_manager_android_browsertest.cc",
      "../browser/password_manager/passwords_navigation_observer.cc",
      "../browser/password_manager/passwords_navigation_observer.h",
      "../browser/policy/policy_prefs_browsertest.cc",
      "../browser/preloading/prefetch/search_prefetch/search_preload_test_response_utils.cc",
      "../browser/preloading/prefetch/search_prefetch/search_preload_test_response_utils.h",
      "../browser/preloading/prefetch/search_prefetch/search_preload_unified_browsertest.cc",
      "../browser/profiles/profile_browsertest_android.cc",
      "../browser/safe_browsing/client_side_detection_service_browsertest.cc",
      "../browser/segmentation_platform/service_browsertest.cc",
      "../browser/share/qr_code_generator_pixeltest.cc",
      "../browser/ssl/chrome_security_state_client_browsertest.cc",
      "../browser/ssl/crlset_browsertest.cc",
      "../browser/storage/shared_storage_browsertest.cc",
      "../browser/tpcd/support/origin_trial_service_browsertest.cc",
      "../browser/tpcd/support/tpcd_support_browsertest.cc",
      "../browser/tpcd/support/validity_service_browsertest.cc",
      "../browser/trusted_vault/trusted_vault_encryption_keys_tab_helper_browsertest.cc",
      "../browser/ui/android/autofill/save_update_address_profile_flow_manager_browsertest.cc",
      "../browser/ui/android/hats/survey_client_android_browsertest.cc",
      "../browser/ui/android/plus_addresses/all_plus_addresses_bottom_sheet_view_browsertest.cc",
      "../browser/ui/android/plus_addresses/plus_address_creation_view_android_browsertest.cc",
      "../browser/ui/webui/policy/policy_test_ui_browsertest.cc",
      "../browser/ui/webui/policy/policy_ui_browsertest.cc",
      "../browser/user_agent/android_user_agent_browsertest.cc",
      "../browser/webapps/installable/installable_manager_browsertest.cc",
      "../browser/webapps/web_contents/web_app_url_loader_browsertest.cc",
      "../renderer/accessibility/read_anything_test_utils.cc",
      "../renderer/accessibility/read_anything_test_utils.h",
      "../renderer/autofill/fake_mojo_password_manager_driver.cc",
      "../renderer/autofill/fake_mojo_password_manager_driver.h",
      "../renderer/autofill/fake_password_generation_driver.cc",
      "../renderer/autofill/fake_password_generation_driver.h",
      "../renderer/autofill/password_autofill_agent_browsertest.cc",
      "../renderer/autofill/password_generation_agent_browsertest.cc",
      "../renderer/autofill/password_generation_test_utils.cc",
      "../renderer/autofill/password_generation_test_utils.h",
      "../renderer/cart/commerce_hint_agent_browsertest.cc",
      "../renderer/cart/commerce_hint_agent_renderer_browsertest.cc",
      "../renderer/commerce/commerce_web_extractor_browsertest.cc",
      "../renderer/safe_browsing/phishing_classifier_browsertest.cc",
      "../renderer/wallet/boarding_pass_extractor_browsertest.cc",
      "android/browsertests_apk/android_browsertests_jni_onload.cc",
      "base/android/android_browser_test_browsertest_android.cc",
    ]

    deps += [
      ":persisted_tab_data_test_proto",
      "//chrome/browser/password_manager/android:test_support",
      "//chrome/browser/search_engines",
      "//components/autofill/content/browser:test_support",
      "//components/back_forward_cache:back_forward_cache",
      "//components/browsing_data/core:core",
      "//components/commerce/content/renderer",
      "//components/commerce/core:commerce_constants",
      "//components/enterprise:enterprise",
      "//components/enterprise:test_support",
      "//components/invalidation:test_support",
      "//components/invalidation/impl:test_support",
      "//components/messages/android:android",
      "//components/messages/android:feature_flags",
      "//components/messages/android/test:test_support_cpp",
      "//components/messages/android/test:test_support_java",
      "//components/optimization_guide/core:test_support",
      "//components/page_content_annotations/core:test_support",
      "//components/password_manager/content/browser:browser",
      "//components/plus_addresses",
      "//components/plus_addresses:test_support",
      "//components/plus_addresses/settings:test_support",
      "//components/policy:chrome_settings_proto_generated_compile",
      "//components/policy/core/browser:pref_mapping_test_support",
      "//components/policy/core/browser:test_support",
      "//components/policy/test_support:test_support",
      "//components/privacy_sandbox/privacy_sandbox_attestations",
      "//components/privacy_sandbox/privacy_sandbox_attestations:test_support",
      "//components/privacy_sandbox/privacy_sandbox_attestations/proto:proto",
      "//components/safe_browsing/content/browser:client_side_detection",
      "//components/safe_browsing/content/browser:client_side_detection_service",
      "//components/safe_browsing/content/common:interfaces",
      "//components/safe_browsing/content/renderer/phishing_classifier:phishing_classifier",
      "//components/safe_browsing/core/common/fbs:client_model",
      "//components/safe_browsing/core/common/proto:client_model_proto",
      "//components/safe_browsing/core/common/proto:csd_proto",
      "//components/segmentation_platform/public:public",
      "//components/segmentation_platform/public:test_support",
      "//components/site_engagement/content:content",
      "//components/spellcheck:buildflags",
      "//components/spellcheck/renderer:renderer",
      "//components/user_manager:user_manager",
      "//components/webapps/browser:test_support",
    ]

    if (enable_chrome_android_internal) {
      data_deps = [ "//clank/build/bot/filters:android_browsertests_filters" ]
    }

    # Add unwind tables in android_browsertests apk to support enabling
    # sampling profiler. The unwind tables are generated from debug info in the
    # binary. Removing "default_symbols" and adding symbols config removes the
    # "strip_debug" config that strips the debug info, on android_browsertests
    # apk.
    if (enable_arm_cfi_table) {
      sources += [ "../common/profiler/thread_profiler_browsertest.cc" ]

      # Cannot depend on the stack_unwinder/internal:java since it uses a custom
      # GEN_JNI class via @NativeMethods("stack_unwinder").
      deps += [ "//chrome/android/modules/stack_unwinder/internal:stack_unwinder_for_testing" ]
      configs -= [ "//build/config/compiler:default_symbols" ]
      if (symbol_level == 2) {
        configs += [ "//build/config/compiler:symbols" ]
      } else {
        configs += [ "//build/config/compiler:minimal_symbols" ]
      }
      add_unwind_tables_in_apk = true
    }

    if (enable_arcore) {
      # If AR is supported, we should also include WebXR's AR enterprise policy
      # browsertest. The test should not be enabled when AR features are not
      # enabled, since we won't be able to distinguish whether the test cases
      # are failing due to absence of AR, or due to an issue with propagating
      # the enterprise policy setting.
      sources += [ "../browser/android/vr/webxr_policy_browsertest.cc" ]
    }

    data = [
      "$root_gen_dir/chrome/android/chrome_apk_paks/chrome_100_percent.pak",
      "$root_gen_dir/chrome/android/chrome_apk_paks/locales/en-US.pak",
      "$root_gen_dir/chrome/android/chrome_apk_paks/resources.pak",
      "$root_gen_dir/components/components_resources.pak",
      "$root_gen_dir/components/dev_ui_components_resources.pak",
      "//components/test/data/ads_observer/",
      "//components/test/data/payments/",
      "//chrome/test/data/android/customtabs/",
      "//chrome/test/data/banners/",
      "//chrome/test/data/policy/",
      "//chrome/test/data/ssl/",
      "//content/test/data/",
    ]

    if (dfmify_dev_ui) {
      # If DevUI DFM is on, include Java classes and native resource split so
      # that DevUI page tests would work.
      deps += [
        "//chrome/android/features/dev_ui:java",
        "//chrome/android/modules/dev_ui/provider:java",
      ]
    }

    if (enable_allocation_trace_recorder_integration_tests) {
      sources += [ "../browser/allocation_recorder_browsertest.cc" ]
      deps += [ "//components/allocation_recorder/testing" ]
    }

    if (enable_desktop_android_extensions) {
      sources += [ "../browser/extensions/desktop_android/desktop_android_extensions_browsertest.cc" ]
    }
  }

  proto_library("persisted_tab_data_test_proto") {
    sources = [
      "../browser/android/persisted_tab_data/test/bar.proto",
      "../browser/android/persisted_tab_data/test/foo.proto",
    ]
  }

  test("android_sync_integration_tests") {
    configs += [ "//build/config:precompiled_headers" ]
    defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]
    use_default_launcher = false
    android_manifest =
        "${target_gen_dir}/android_browsertests_manifest/AndroidManifest.xml"
    android_manifest_dep = ":android_browsertests_manifest"

    deps = android_sync_integration_tests_deps + [
             "//chrome/browser/sync",
             "//chrome/test/android:live_signin_test_util_public_impl_java",
           ]
    sources = sync_integration_tests_sources
    data = android_sync_integration_tests_data
  }

  static_library("test_support_ui_android") {
    configs += [ "//build/config:precompiled_headers" ]
    testonly = true

    sources = [
      "../browser/ssl/cert_verifier_platform_browser_test.cc",
      "../browser/ssl/cert_verifier_platform_browser_test.h",
      "base/android/android_browser_test.cc",
      "base/android/android_browser_test.h",
      "base/platform_browser_test.h",
    ]
    public_deps = [ "//content/test:test_support" ]
    deps = [
      "//chrome/browser",
      "//chrome/browser/ui",
      "//content/public/browser",
    ]
  }

  android_assets("android_browsertests_assets") {
    testonly = true
    disable_compression = true
    sources = []
    deps = []

    # These are grit() rules so they are in $root_gen_dir.
    deps += [ "//components/resources" ]
    sources += [
      "$root_gen_dir/components/components_resources.pak",
      "$root_gen_dir/components/dev_ui_components_resources.pak",
    ]

    # These are assets rules so we can just depend on them.
    deps += [
      "//chrome/android:chrome_apk_pak_assets",
      "//gin:v8_snapshot_assets",
      "//third_party/icu:icu_assets",
    ]
  }

  android_library("android_browsertests_java") {
    testonly = true
    deps = [
      "//base:base_java",
      "//base:base_java_test_support",
      "//build/android/gtest_apk:native_test_instrumentation_test_runner_java",
      "//chrome/android:base_module_java",
      "//chrome/android:chrome_all_java",
      "//chrome/browser/tabmodel:java",
      "//components/crash/android:handler_java",
      "//components/crash/android:java",
      "//components/module_installer/android:module_installer_java",
      "//content/public/android:content_java",
      "//content/public/test/android:android_test_message_pump_support_java",
      "//content/shell/android:content_shell_browsertests_java",
      "//testing/android/native_test:native_browser_test_java",
      "//testing/android/native_test:native_test_java",
      "//ui/android:ui_full_java",
    ]
    sources = [
      "android/browsertests_apk/src/org/chromium/android_browsertests_apk/ChromeBrowserTestsActivity.java",
      "android/browsertests_apk/src/org/chromium/android_browsertests_apk/ChromeBrowserTestsApplication.java",
      "android/browsertests_apk/src/org/chromium/android_browsertests_apk/ChromeBrowserTestsInstrumentationTestRunner.java",
    ]
  }

  jinja_template("android_browsertests_manifest") {
    testonly = true
    input = "//chrome/test/android/browsertests_apk/AndroidManifest.xml.jinja2"
    output =
        "${target_gen_dir}/android_browsertests_manifest/AndroidManifest.xml"
  }
}

static_library("browser_tests_runner") {
  testonly = true
  sources = []

  deps = [
    ":chrome_test_launcher",
    ":test_support",
    "//ui/gfx:gfx_switches",  # Used by Fuchsia.
  ]

  if (is_chromeos_ash) {
    sources += [ "base/browser_tests_main_chromeos.cc" ]
  } else {
    sources += [ "base/browser_tests_main.cc" ]
  }

  if (is_win) {
    deps += [ "//chrome/installer/util:strings" ]
  }

  if (is_android) {
    deps += [ "//ui/compositor" ]
  }
}

if (!is_android) {
  static_library("webrtc_browser_tests_base") {
    testonly = true

    sources = [
      "../browser/media/webrtc/test_stats_dictionary.cc",
      "../browser/media/webrtc/test_stats_dictionary.h",
      "../browser/media/webrtc/webrtc_browsertest_base.cc",
      "../browser/media/webrtc/webrtc_browsertest_base.h",
      "../browser/media/webrtc/webrtc_browsertest_common.cc",
      "../browser/media/webrtc/webrtc_browsertest_common.h",
    ]
    deps = [ ":test_support" ]
  }

  test("browser_tests") {
    use_xvfb = use_xvfb_in_this_config

    configs += [ "//build/config:precompiled_headers" ]
    configs += [ ":disable_thinlto_cache_flags" ]
    defines = [
      "HAS_OUT_OF_PROC_TEST_RUNNER",
      "CHROME_VERSION_MAJOR=" + chrome_version_major,
    ]

    deps = [
      ":browser_tests_runner",
      ":sync_integration_test_support",
      ":test_support",
      ":test_support_ui",
      ":webrtc_browser_tests_base",
      "//base",
      "//base:i18n",
      "//base/allocator:buildflags",
      "//base/test:test_proto",
      "//base/test:test_support",
      "//build:branding_buildflags",
      "//build:chromeos_buildflags",
      "//build/config/coverage:buildflags",
      "//chrome:packed_resources",
      "//chrome:resources",
      "//chrome:strings",
      "//chrome/app:command_ids",
      "//chrome/app/vector_icons",
      "//chrome/browser",
      "//chrome/browser:buildflags",
      "//chrome/browser:global_features",
      "//chrome/browser:main_extra_parts",
      "//chrome/browser:primitives",
      "//chrome/browser/accessibility:test_support",
      "//chrome/browser/accessibility:utils",
      "//chrome/browser/apps/app_service",
      "//chrome/browser/apps/app_service:app_registry_cache_waiter",
      "//chrome/browser/apps/app_service:constants",
      "//chrome/browser/apps/app_service:test_support",
      "//chrome/browser/apps/app_service/app_icon",
      "//chrome/browser/apps/link_capturing",
      "//chrome/browser/apps/link_capturing:features",
      "//chrome/browser/apps/link_capturing:test_support",
      "//chrome/browser/autofill",
      "//chrome/browser/autofill:browser_tests",
      "//chrome/browser/bitmap_fetcher:browser_tests",
      "//chrome/browser/breadcrumbs:browser_tests",
      "//chrome/browser/browsing_data:constants",
      "//chrome/browser/companion/core",
      "//chrome/browser/companion/core/mojom:mojo_bindings",
      "//chrome/browser/companion/core/proto",
      "//chrome/browser/companion/visual_query:browser_tests",
      "//chrome/browser/companion/visual_query:visual_query",
      "//chrome/browser/devtools",
      "//chrome/browser/devtools:test_support",
      "//chrome/browser/dips:browser_tests",
      "//chrome/browser/enterprise/watermark:watermark_view_lib",
      "//chrome/browser/favicon",
      "//chrome/browser/feedback",
      "//chrome/browser/feedback:feedback_impl",
      "//chrome/browser/first_party_sets",
      "//chrome/browser/headless:browser_tests",
      "//chrome/browser/icon_transcoder:browser_tests",
      "//chrome/browser/image_decoder:browser_tests",
      "//chrome/browser/image_fetcher",
      "//chrome/browser/ip_protection:browser_tests",
      "//chrome/browser/media/router:media_router_feature",
      "//chrome/browser/media/router:test_support",
      "//chrome/browser/media/router/discovery/access_code:access_code_cast_feature",
      "//chrome/browser/media/router/discovery/access_code:access_code_sink_service",
      "//chrome/browser/media/webrtc",
      "//chrome/browser/media/webrtc:test_support",
      "//chrome/browser/metrics:test_support",
      "//chrome/browser/metrics/structured:test_support",
      "//chrome/browser/notifications/scheduler:factory",
      "//chrome/browser/notifications/scheduler/public",
      "//chrome/browser/notifications/scheduler/test:test_support",
      "//chrome/browser/optimization_guide:test_support",
      "//chrome/browser/payments:browser_tests",
      "//chrome/browser/permissions",
      "//chrome/browser/permissions:browser_tests",
      "//chrome/browser/persisted_state_db",
      "//chrome/browser/plus_addresses:browser_tests",
      "//chrome/browser/policy:browser_tests",
      "//chrome/browser/policy:test_support",
      "//chrome/browser/preloading/prefetch:browser_tests",
      "//chrome/browser/preloading/prerender:browser_tests",
      "//chrome/browser/preloading/preview:browser_tests",
      "//chrome/browser/privacy_budget:browser_tests",
      "//chrome/browser/profiling_host:profiling_browsertests",
      "//chrome/browser/resource_coordinator:mojo_bindings",
      "//chrome/browser/resource_coordinator:tab_manager_features",
      "//chrome/browser/safe_browsing:advanced_protection",
      "//chrome/browser/safe_browsing:verdict_cache_manager_factory",
      "//chrome/browser/screen_ai:screen_ai_install_state",
      "//chrome/browser/screen_ai:screen_ai_service_router_factory",
      "//chrome/browser/screen_ai/public:test_support",
      "//chrome/browser/search",
      "//chrome/browser/search_engines",
      "//chrome/browser/segmentation_platform:test_utils",
      "//chrome/browser/storage_access_api",
      "//chrome/browser/supervised_user:test_support",
      "//chrome/browser/support_tool:support_tool_proto",
      "//chrome/browser/sync",
      "//chrome/browser/themes",
      "//chrome/browser/top_level_storage_access_api:permissions",
      "//chrome/browser/tpcd/http_error_observer:browser_tests",
      "//chrome/browser/ui:browser_element_identifiers",
      "//chrome/browser/ui:browser_navigator_params_headers",
      "//chrome/browser/ui:ui_features",
      "//chrome/browser/ui:ui_features",
      "//chrome/browser/ui/apps",
      "//chrome/browser/ui/autofill/payments:browser_tests",
      "//chrome/browser/ui/blocked_content",
      "//chrome/browser/ui/blocked_content:browser_tests",
      "//chrome/browser/ui/browser_window",
      "//chrome/browser/ui/color:color_headers",
      "//chrome/browser/ui/exclusive_access",
      "//chrome/browser/ui/find_bar:browser_tests",
      "//chrome/browser/ui/omnibox",
      "//chrome/browser/ui/permission_bubble:browser_tests",
      "//chrome/browser/ui/tabs",
      "//chrome/browser/ui/tabs:tab_enums",
      "//chrome/browser/ui/toasts",
      "//chrome/browser/ui/views/bubble",
      "//chrome/browser/ui/views/side_panel",
      "//chrome/browser/ui/views/side_panel:side_panel_enums",
      "//chrome/browser/ui/views/toolbar",
      "//chrome/browser/ui/web_applications:browser_tests",
      "//chrome/browser/ui/webui",
      "//chrome/browser/ui/webui/privacy_sandbox:mojo_bindings",
      "//chrome/browser/ui/webui/searchbox",
      "//chrome/browser/ui/webui/top_chrome",
      "//chrome/browser/ui/webui/top_chrome:test_support",
      "//chrome/browser/web_applications:browser_tests",
      "//chrome/browser/web_applications:prevent_close_test_support",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//chrome/browser/webaudio:browser_tests",
      "//chrome/browser/webauthn:test_support",
      "//chrome/common:version_header",
      "//chrome/common/companion/visual_query:flags",
      "//chrome/common/privacy_budget:test_support",
      "//chrome/renderer",
      "//chrome/renderer/companion/visual_query:browser_tests",
      "//chrome/services/removable_storage_writer:lib",
      "//chrome/test/data/webui:resources_grit",
      "//chrome/test/data/webui/mojo:mojo_bindings",
      "//chrome/test/media_router/access_code_cast:access_code_cast_integration_base",
      "//chrome/test/payments:test_support",
      "//components/affiliations/core/browser:affiliation_proto",
      "//components/affiliations/core/browser:test_support",
      "//components/autofill/content/browser:autofill_shared_storage_proto",
      "//components/autofill/content/browser:risk_proto",
      "//components/autofill/content/browser:test_support",
      "//components/autofill/content/common:features",
      "//components/autofill/content/common/mojom",
      "//components/autofill/content/renderer:test_support",
      "//components/back_forward_cache",
      "//components/background_fetch",
      "//components/background_sync",
      "//components/base32",
      "//components/blocked_content",
      "//components/bookmarks/browser",
      "//components/bookmarks/common",
      "//components/bookmarks/managed",
      "//components/browser_sync",
      "//components/browsing_data/content",
      "//components/browsing_data/content:test_support",
      "//components/browsing_data/core",
      "//components/browsing_topics",
      "//components/captive_portal/content",
      "//components/captive_portal/core",
      "//components/captive_portal/core:buildflags",
      "//components/captive_portal/core:test_support",
      "//components/cbor",
      "//components/certificate_transparency",
      "//components/certificate_transparency:proto",
      "//components/commerce/content/browser",
      "//components/commerce/content/renderer",
      "//components/commerce/core:cart_db_content_proto",
      "//components/commerce/core:commerce_constants",
      "//components/commerce/core:commerce_heuristics_data",
      "//components/commerce/core:coupon_db_content_proto",
      "//components/commerce/core:feature_list",
      "//components/commerce/core:shopping_service_test_support",
      "//components/component_updater/installer_policies:installer_policies_no_content_deps",
      "//components/compose:buildflags",
      "//components/compose/core/browser:features",
      "//components/consent_auditor",
      "//components/consent_auditor:test_support",
      "//components/constrained_window",
      "//components/content_settings/browser",
      "//components/content_settings/common:mojom",
      "//components/content_settings/core/browser:test_support",
      "//components/cookie_config",
      "//components/country_codes",
      "//components/crash/content/browser/error_reporting:mock_crash_endpoint",
      "//components/data_sharing/public",
      "//components/dom_distiller/content/browser",
      "//components/dom_distiller/content/browser:test_support",
      "//components/dom_distiller/content/renderer",
      "//components/dom_distiller/core:test_support",
      "//components/domain_reliability:prefs",
      "//components/drive:test_support",
      "//components/embedder_support",
      "//components/embedder_support:browser_util",
      "//components/enterprise",
      "//components/enterprise:test_support",
      "//components/enterprise/browser/identifiers:identifiers",
      "//components/enterprise/common/proto:connectors_proto",
      "//components/enterprise/connectors/core",
      "//components/error_page/content/browser",
      "//components/favicon/content",
      "//components/favicon/core",
      "//components/feature_engagement/public",
      "//components/feature_engagement/test:test_support",
      "//components/feedback:feedback",
      "//components/feedback/redaction_tool",
      "//components/fingerprinting_protection_filter/browser",
      "//components/fingerprinting_protection_filter/common",
      "//components/flags_ui",
      "//components/heavy_ad_intervention",
      "//components/history/content/browser",
      "//components/history/core/common",
      "//components/history_clusters/core:core",
      "//components/history_embeddings",
      "//components/image_fetcher/core",
      "//components/infobars/content",
      "//components/input",
      "//components/invalidation:test_support",
      "//components/invalidation/impl",
      "//components/invalidation/impl:test_support",
      "//components/javascript_dialogs",
      "//components/language/core/browser",
      "//components/language/core/common",
      "//components/lens",
      "//components/lens:buildflags",
      "//components/lens:enterprise_policy",
      "//components/live_caption",
      "//components/live_caption:constants",
      "//components/lookalikes/core",
      "//components/lookalikes/core:proto",
      "//components/lookalikes/core:safety_tips",
      "//components/media_device_salt:media_device_salt",
      "//components/media_router/common/providers/cast/channel",
      "//components/memory_pressure",
      "//components/memory_pressure:test_support",
      "//components/metrics:content",
      "//components/metrics:metrics",
      "//components/metrics/demographics",
      "//components/metrics/demographics:test_support",
      "//components/metrics/structured",
      "//components/metrics/structured:structured_events",
      "//components/metrics/structured:test_support",
      "//components/metrics_services_manager",
      "//components/nacl/common:buildflags",
      "//components/navigation_metrics",
      "//components/no_state_prefetch/browser",
      "//components/no_state_prefetch/common",
      "//components/no_state_prefetch/renderer",
      "//components/offline_items_collection/core/test_support",
      "//components/omnibox/browser:vector_icons",
      "//components/optimization_guide/content/browser",
      "//components/optimization_guide/content/mojom:mojo_interfaces",
      "//components/optimization_guide/content/renderer",
      "//components/optimization_guide/core",
      "//components/optimization_guide/core:bloomfilter",
      "//components/optimization_guide/core:prediction",
      "//components/optimization_guide/core:test_support",
      "//components/optimization_guide/core:test_support",
      "//components/optimization_guide/proto:optimization_guide_proto",
      "//components/origin_trials:browser",
      "//components/origin_trials/test",
      "//components/page_content_annotations/core",
      "//components/page_content_annotations/core:test_support",
      "//components/page_image_service",
      "//components/page_load_metrics/browser",
      "//components/page_load_metrics/browser:test_support",
      "//components/page_load_metrics/browser/observers/ad_metrics",
      "//components/page_load_metrics/browser/observers/ad_metrics:test_support",
      "//components/page_load_metrics/common",
      "//components/page_load_metrics/common:test_support",
      "//components/page_load_metrics/google/browser",
      "//components/password_manager/content/browser",
      "//components/password_manager/content/common",
      "//components/password_manager/core/browser/features:password_features",
      "//components/password_manager/core/browser/form_parsing",
      "//components/payments/content",
      "//components/payments/content:utils",
      "//components/performance_manager",
      "//components/performance_manager/test_support:test_support_common",
      "//components/plus_addresses",
      "//components/plus_addresses:test_support",
      "//components/policy:chrome_settings_proto_generated_compile",
      "//components/policy/core/browser:pref_mapping_test_support",
      "//components/policy/core/browser:test_support",
      "//components/policy/test_support",
      "//components/privacy_sandbox",
      "//components/privacy_sandbox:privacy_sandbox_prefs",
      "//components/privacy_sandbox:test_support",
      "//components/privacy_sandbox:tpcd",
      "//components/privacy_sandbox:tracking_protection_onboarding",
      "//components/privacy_sandbox:tracking_protection_prefs",
      "//components/privacy_sandbox:tracking_protection_settings",
      "//components/privacy_sandbox/privacy_sandbox_attestations",
      "//components/privacy_sandbox/privacy_sandbox_attestations:metrics",
      "//components/privacy_sandbox/privacy_sandbox_attestations:test_support",
      "//components/privacy_sandbox/privacy_sandbox_attestations/proto:proto",
      "//components/proxy_config",
      "//components/qr_code_generator:bitmap_generator",
      "//components/reading_list/core",
      "//components/reading_list/features:flags",
      "//components/resources",
      "//components/safe_browsing:buildflags",
      "//components/safe_browsing/content/browser",
      "//components/safe_browsing/content/browser:client_side_detection",
      "//components/safe_browsing/content/browser:client_side_detection_images_cache",
      "//components/safe_browsing/content/browser:client_side_detection_service",
      "//components/safe_browsing/content/browser:safe_browsing_service",
      "//components/safe_browsing/content/browser/password_protection",
      "//components/safe_browsing/content/browser/password_protection:test_support",
      "//components/safe_browsing/content/browser/web_ui",
      "//components/safe_browsing/content/common:interfaces",
      "//components/safe_browsing/content/common:interfaces_shared_cpp_sources",
      "//components/safe_browsing/content/renderer",
      "//components/safe_browsing/content/renderer/phishing_classifier",
      "//components/safe_browsing/content/renderer/phishing_classifier:unit_tests_support",
      "//components/safe_browsing/core/browser:verdict_cache_manager",
      "//components/safe_browsing/core/browser/db:test_database_manager",
      "//components/safe_browsing/core/browser/db:v4_database",
      "//components/safe_browsing/core/browser/db:v4_get_hash_protocol_manager",
      "//components/safe_browsing/core/browser/password_protection:password_protection_metrics_util",
      "//components/safe_browsing/core/browser/realtime:url_lookup_service_base",
      "//components/safe_browsing/core/common",
      "//components/safe_browsing/core/common/proto:client_model_proto",
      "//components/saved_tab_groups:core",
      "//components/search",
      "//components/security_interstitials/content:proto",
      "//components/security_interstitials/content:security_interstitial_page",
      "//components/security_interstitials/core:unsafe_resource",
      "//components/security_state/content",
      "//components/segmentation_platform/embedder/default_model",
      "//components/segmentation_platform/internal",
      "//components/segmentation_platform/internal:test_support",
      "//components/segmentation_platform/public",
      "//components/segmentation_platform/public:test_support",
      "//components/services/app_service",
      "//components/services/app_service/public/cpp:test_support",
      "//components/services/language_detection/public/cpp",
      "//components/services/language_detection/public/mojom",
      "//components/services/patch/content",
      "//components/services/patch/public/cpp",
      "//components/services/patch/public/mojom",
      "//components/services/quarantine:test_support",
      "//components/services/storage",
      "//components/session_proto_db:session_proto_db",
      "//components/sharing_message/proto",
      "//components/sharing_message/shared_clipboard",
      "//components/sharing_message/web_push",
      "//components/signin/core/browser",
      "//components/signin/public/base:signin_buildflags",
      "//components/signin/public/identity_manager",
      "//components/signin/public/identity_manager:test_support",
      "//components/site_engagement/content",
      "//components/site_isolation",
      "//components/soda",
      "//components/soda:constants",
      "//components/spellcheck:buildflags",
      "//components/spellcheck/browser",
      "//components/spellcheck/common",
      "//components/spellcheck/common:interfaces",
      "//components/spellcheck/common:spellcheck_result",
      "//components/spellcheck/renderer",
      "//components/strings",
      "//components/subresource_filter/core/browser",
      "//components/subresource_filter/core/browser:test_support",
      "//components/subresource_filter/core/common:test_support",
      "//components/supervised_user/core/browser",
      "//components/supervised_user/core/browser:fetcher",
      "//components/supervised_user/core/browser:fetcher_config",
      "//components/supervised_user/core/browser:mocked",
      "//components/supervised_user/core/browser/proto",
      "//components/supervised_user/core/common",
      "//components/supervised_user/core/common:test_utils",
      "//components/supervised_user/test_support",
      "//components/supervised_user/test_support",
      "//components/sync",
      "//components/sync:test_support",
      "//components/sync_device_info:test_support",
      "//components/tab_groups",
      "//components/tpcd/enterprise_reporting:enterprise_reporting",
      "//components/tpcd/metadata/browser",
      "//components/tpcd/metadata/browser:test_support",
      "//components/tpcd/metadata/common/proto",
      "//components/tracing:background_tracing_utils",
      "//components/translate/content/browser:test_support",
      "//components/translate/content/renderer",
      "//components/translate/core/common",
      "//components/translate/core/language_detection",
      "//components/trusted_vault",
      "//components/ukm/content",
      "//components/unified_consent",
      "//components/url_formatter/spoof_checks/top_domains:generate_top_domains_test_trie",
      "//components/url_formatter/spoof_checks/top_domains:test_top_bucket_domains",
      "//components/url_formatter/spoof_checks/top_domains:test_top_bucket_domains_header",
      "//components/user_annotations",
      "//components/user_annotations",
      "//components/user_education/common",
      "//components/user_education/test",
      "//components/user_education/webui:webui",
      "//components/user_manager",
      "//components/user_notes:features",
      "//components/user_prefs",
      "//components/variations/service",
      "//components/variations/service",
      "//components/version_info",
      "//components/web_package/test_support",
      "//components/webapps/browser",
      "//components/webapps/browser:test_support",
      "//components/webapps/common:common",
      "//components/webapps/services/web_app_origin_association/test:test_support",
      "//components/webauthn/core/browser:passkey_model",
      "//components/webauthn/core/browser:test_support",
      "//components/webrtc",
      "//components/webrtc_logging/browser",
      "//content/public/common",
      "//content/test:browsertest_support",
      "//content/test:test_support",
      "//crypto:test_support",
      "//device/bluetooth:mocks",
      "//device/fido:cablev2_test_util",
      "//device/fido:test_support",
      "//google_apis:test_support",
      "//media:media_buildflags",
      "//media:test_support",
      "//media/cast:test_support",
      "//media/mojo/services",
      "//mojo/core/embedder",
      "//mojo/public/cpp/system",
      "//mojo/public/js:resources_grit",
      "//net",
      "//net:extras",
      "//net:test_support",
      "//pdf:buildflags",
      "//ppapi/buildflags",
      "//printing/buildflags",
      "//rlz/buildflags",
      "//services/audio/public/cpp:test_support",
      "//services/device/public/cpp:test_support",
      "//services/device/public/mojom",
      "//services/image_annotation/public/cpp",
      "//services/network/public/cpp",
      "//services/network/public/mojom",
      "//services/network/public/proto:sct_audit_report_proto",
      "//services/preferences/public/cpp",
      "//services/preferences/public/cpp/tracked",
      "//services/screen_ai:test_support",
      "//services/screen_ai/public/cpp:utilities",
      "//services/screen_ai/public/mojom",
      "//services/service_manager/public/cpp",
      "//services/strings",
      "//services/test/echo/public/mojom",
      "//skia",
      "//storage/browser:test_support",
      "//testing/data_driven_testing",
      "//testing/gmock",
      "//testing/gtest",
      "//testing/perf",
      "//third_party/blink/public:blink_headers",
      "//third_party/blink/public:buildflags",
      "//third_party/blink/public/common",
      "//third_party/blink/public/mojom:web_feature_mojo_bindings",
      "//third_party/icu",
      "//third_party/leveldatabase",
      "//third_party/libwebp",
      "//third_party/openscreen/src/cast/streaming:common",
      "//third_party/protobuf:py_proto_runtime",
      "//third_party/tflite:buildflags",
      "//third_party/webrtc_overrides:webrtc_component",
      "//third_party/widevine/cdm:buildflags",
      "//third_party/widevine/cdm:headers",
      "//third_party/zlib/google:zip",
      "//ui/accessibility:test_support",
      "//ui/base:ozone_buildflags",
      "//ui/base:test_support",
      "//ui/base/clipboard:clipboard_test_support",
      "//ui/base/dragdrop/mojom",
      "//ui/color:color",
      "//ui/color:mixers",
      "//ui/compositor:test_support",
      "//ui/display:test_support",
      "//ui/native_theme:test_support",
      "//ui/resources",
      "//ui/shell_dialogs:test_support",
      "//ui/web_dialogs:test_support",
      "//ui/webui",
      "//ui/webui:test_support",
      "//ui/webui/resources/cr_components/history_clusters:mojo_bindings",
      "//v8",
    ]

    allow_circular_includes_from = []

    if (is_chromeos) {
      deps += [
        "//chrome/browser/chromeos:browser_tests",
        "//chrome/browser/chromeos/app_mode",
        "//chrome/browser/chromeos/arc",
        "//chrome/browser/chromeos/enterprise",
        "//chrome/browser/chromeos/enterprise/cloud_storage",
        "//chrome/browser/chromeos/network",
        "//chrome/browser/chromeos/platform_keys",
        "//chrome/browser/chromeos/policy/dlp",
        "//chrome/browser/chromeos/policy/dlp/test:test_support",
        "//chromeos/dbus/dlp:dlp",
        "//components/onc",
        "//ui/chromeos",
      ]

      if (use_cups) {
        deps += [ "//chrome/browser/chromeos/printing" ]
      }
    }

    if (is_chromeos_ash) {
      deps += [
        "//chrome/browser/accessibility/media_app/test:test_support",
        "//chrome/browser/ash/accessibility",
        "//chrome/browser/ash/accessibility:test_support",
        "//chrome/browser/ash/accessibility/service",
        "//chrome/browser/ash/app_list:test_support",
        "//chrome/browser/ash/app_list/app_service",
        "//chrome/browser/ash/app_list/arc",
        "//chrome/browser/ash/app_list/arc:test_support",
        "//chrome/browser/ash/app_list/search",
        "//chrome/browser/ash/app_list/search/test:test_support",
        "//chrome/browser/ash/app_list/test:test_support",
        "//chrome/browser/ash/arc",
        "//chrome/browser/ash/arc/accessibility",
        "//chrome/browser/ash/arc/auth",
        "//chrome/browser/ash/arc/enterprise/cert_store",
        "//chrome/browser/ash/arc/extensions",
        "//chrome/browser/ash/arc/fileapi",
        "//chrome/browser/ash/arc/intent_helper",
        "//chrome/browser/ash/arc/keymaster",
        "//chrome/browser/ash/arc/keymint",
        "//chrome/browser/ash/arc/policy",
        "//chrome/browser/ash/arc/session",
        "//chrome/browser/ash/arc/tracing",
        "//chrome/browser/ash/arc/tracing/test:test_support",
        "//chrome/browser/ash/arc/user_session",
        "//chrome/browser/ash/arc/vmm",
        "//chrome/browser/ash/base",
        "//chrome/browser/ash/child_accounts",
        "//chrome/browser/ash/child_accounts:test_support",
        "//chrome/browser/ash/child_accounts/parent_access_code",
        "//chrome/browser/ash/child_accounts/parent_access_code:test_support",
        "//chrome/browser/ash/child_accounts/time_limits",
        "//chrome/browser/ash/child_accounts/time_limits:test_support",
        "//chrome/browser/ash/crostini:browser_test_support",
        "//chrome/browser/ash/crostini:test_support",
        "//chrome/browser/ash/crostini/ansible",
        "//chrome/browser/ash/crostini/ansible:test_support",
        "//chrome/browser/ash/customization",
        "//chrome/browser/ash/extensions",
        "//chrome/browser/ash/extensions/autotest_private",
        "//chrome/browser/ash/extensions/file_manager",
        "//chrome/browser/ash/extensions/login_screen_ui",
        "//chrome/browser/ash/extensions/speech",
        "//chrome/browser/ash/extensions/users_private",
        "//chrome/browser/ash/file_manager",
        "//chrome/browser/ash/file_manager:test_support",
        "//chrome/browser/ash/file_suggest",
        "//chrome/browser/ash/file_suggest:test_support",
        "//chrome/browser/ash/input_method",
        "//chrome/browser/ash/input_method:test_support",
        "//chrome/browser/ash/plugin_vm",
        "//chrome/browser/ash/plugin_vm:test_support",
        "//chrome/browser/ash/policy/affiliation:test_support",
        "//chrome/browser/ash/policy/core",
        "//chrome/browser/ash/policy/core:test_support",
        "//chrome/browser/ash/policy/dlp",
        "//chrome/browser/ash/policy/dlp/dialogs",
        "//chrome/browser/ash/policy/dlp/test:test_support",
        "//chrome/browser/ash/policy/enrollment",
        "//chrome/browser/ash/policy/enrollment:test_support",
        "//chrome/browser/ash/policy/enrollment/psm:test_support",
        "//chrome/browser/ash/policy/external_data",
        "//chrome/browser/ash/policy/external_data:test_support",
        "//chrome/browser/ash/policy/handlers",
        "//chrome/browser/ash/policy/handlers:test_support",
        "//chrome/browser/ash/policy/login:test_support",
        "//chrome/browser/ash/policy/remote_commands",
        "//chrome/browser/ash/policy/remote_commands:test_support",
        "//chrome/browser/ash/policy/skyvault",
        "//chrome/browser/ash/policy/test_support",
        "//chrome/browser/ash/printing",
        "//chrome/browser/ash/printing:test_support",
        "//chrome/browser/ash/printing/print_management",
        "//chrome/browser/ui/ash",
        "//chrome/browser/ui/ash:test_support",
        "//remoting/host/chromeos:features",
      ]
    }

    if (is_mac) {
      deps += [ "//device/fido:icloud_keychain_test_support" ]
    }

    # Runtime dependencies
    data_deps = [
      "//chrome:browser_tests_pak",
      "//chrome/browser/resources/media/mei_preload:component",
      "//chrome/test/data/cast:generate_test_files",
      "//components/policy/proto",
      "//components/privacy_sandbox/privacy_sandbox_attestations/preload:component",
      "//testing:test_scripts_shared",
      "//testing/buildbot/filters:browser_tests_filters",
      "//testing/buildbot/filters:linux_trusty_rel_browser_tests_filters",
      "//third_party/angle:includes",
      "//third_party/private_membership:private_membership_proto",
      "//third_party/shell-encryption:serialization_proto",
      "//third_party/widevine/cdm:widevine_test_license_server",
      "//tools/media_engagement_preload:make_dafsa_runtime",
    ]

    if (!is_component_build) {
      # WebRTC's frame_analyzer doesn't build correctly on component builds,
      # because some compilers will get confused by the fact that WebRTC
      # symbols are exported while liking a WebRTC executable (which should
      # instead statically link WebRTC).
      # In any case, the tests that require frame_analyzer are only run in
      # release mode.
      data_deps += [ "//third_party/webrtc/rtc_tools:frame_analyzer" ]
    }

    data = [
      "data/",
      "//ash/components/arc/test/data/icons",
      "//chrome/browser/page_load_metrics/integration_tests/data/",
      "//chrome/renderer/resources/extensions/",
      "//chrome/test/data/cart/",
      "//components/test/data/ad_tagging/",
      "//components/test/data/ads_observer/",
      "//components/test/data/autofill/",
      "//components/test/data/custom_handlers",
      "//components/test/data/optimization_guide/",
      "//components/test/data/payments/",
      "//components/test/data/subresource_filter/",
      "//components/test/data/translate/",
      "//components/test/data/update_client/",
      "//content/test/data/",
      "//google_apis/test/",

      # Media data deps are included individually to prevent runaway isolate
      # size growth.
      "//media/test/data/90rotation.mp4",
      "//media/test/data/bear-320x240-audio-only.webm",
      "//media/test/data/bear-320x240-av_enc-a.webm",
      "//media/test/data/bear-320x240-av_enc-av.webm",
      "//media/test/data/bear-320x240-av_enc-v.webm",
      "//media/test/data/bear-320x240-multitrack.webm",
      "//media/test/data/bear-320x240-opus-av_enc-av.webm",
      "//media/test/data/bear-320x240-opus-av_enc-v.webm",
      "//media/test/data/bear-320x240-v-vp9_fullsample_enc-v.webm",
      "//media/test/data/bear-320x240-v-vp9_profile2_subsample_cenc-v.mp4",
      "//media/test/data/bear-320x240-v-vp9_profile2_subsample_cenc-v.webm",
      "//media/test/data/bear-320x240-v-vp9_subsample_enc-v.webm",
      "//media/test/data/bear-320x240-v_enc-v.webm",
      "//media/test/data/bear-320x240-v_frag-vp9-cenc.mp4",
      "//media/test/data/bear-320x240-video-only.webm",
      "//media/test/data/bear-320x240.webm",
      "//media/test/data/bear-640x360-a_frag-cbcs.mp4",
      "//media/test/data/bear-640x360-a_frag-cenc.mp4",
      "//media/test/data/bear-640x360-av_enc-av.webm",
      "//media/test/data/bear-640x360-v_frag-cbc1.mp4",
      "//media/test/data/bear-640x360-v_frag-cbcs.mp4",
      "//media/test/data/bear-640x360-v_frag-cenc-mdat.mp4",
      "//media/test/data/bear-640x360-v_frag-cenc.mp4",
      "//media/test/data/bear-640x360-v_frag-cens.mp4",
      "//media/test/data/bear-640x360.webm",
      "//media/test/data/bear-a_enc-a.webm",
      "//media/test/data/bear-av1-320x180-10bit-cenc.mp4",
      "//media/test/data/bear-av1-320x180-10bit-cenc.webm",
      "//media/test/data/bear-av1-cenc.mp4",
      "//media/test/data/bear-av1-cenc.webm",
      "//media/test/data/bear-flac-cenc.mp4",
      "//media/test/data/bear-opus-cenc.mp4",
      "//media/test/data/eme_and_get_display_media.html",
      "//media/test/data/eme_load_session_after_close_test.html",
      "//media/test/data/eme_player.html",
      "//media/test/data/eme_player_js/",
      "//media/test/data/eme_remove_session_test.html",
      "//media/test/data/encrypted_frame_size_change.html",
      "//media/test/data/frame_size_change-av_enc-v.webm",
      "//media/test/data/id3_png_test.mp3",
      "//media/test/data/media_foundation_fallback.html",
      "//media/test/data/mse_config_change.html",
      "//media/test/data/mse_different_containers.html",
      "//media/test/data/multiple_cdm_types.html",
      "//media/test/data/no_streams.webm",
      "//media/test/data/sfx.ogg",
      "//media/test/data/test_key_system_instantiation.html",
      "//media/test/data/webaudio_oscillator.html",

      "//net/tools/testserver/",
      "//third_party/node/node_modules/mocha/mocha.js",
      "//third_party/pywebsocket3/src/mod_pywebsocket/",
      "//third_party/simplejson/",
      "//third_party/webrtc/rtc_tools/compare_videos.py",
      "//ui/webui/resources/",
    ]

    if (is_chromeos_ash) {
      # Libraries for tests that inherit from BaseWebUIBrowserTest.
      data += [
        "//chrome/test/data/webui/chromeos/chai_v4.js",
        "//chrome/test/data/webui/chromeos/test_api.js",
      ]
    }
    data += metric_integration_jsdeps

    sources = [
      "../browser/accessibility/accessibility_labels_service_browsertest.cc",
      "../browser/accessibility/ax_main_node_annotator_controller_browsertest.cc",
      "../browser/accessibility/browser_accessibility_state_browsertest.cc",
      "../browser/accessibility/image_annotation_browsertest.cc",
      "../browser/accessibility/interstitial_accessibility_browsertest.cc",
      "../browser/accessibility/page_colors_browsertest.cc",
      "../browser/accessibility/phrase_segmentation/dependency_parser_model_loader_browsertest.cc",
      "../browser/attribution_reporting/chrome_attribution_browsertest.cc",
      "../browser/autocomplete/autocomplete_browsertest.cc",
      "../browser/autofill/content_autofill_shared_storage_handler_browsertest.cc",
      "../browser/background_fetch/background_fetch_browsertest.cc",
      "../browser/background_sync/background_sync_browsertest.cc",
      "../browser/background_sync/background_sync_content_setting_browsertest.cc",
      "../browser/background_sync/background_sync_metrics_browsertest.cc",
      "../browser/banners/app_banner_manager_browsertest.cc",
      "../browser/banners/app_banner_manager_browsertest_base.cc",
      "../browser/banners/app_banner_manager_browsertest_base.h",
      "../browser/banners/app_banner_manager_desktop_browsertest.cc",
      "../browser/battery/battery_metrics_browsertest.cc",
      "../browser/bluetooth/web_bluetooth_browsertest.cc",
      "../browser/browser_encoding_browsertest.cc",
      "../browser/browsing_data/browsing_data_model_browsertest.cc",
      "../browser/browsing_data/browsing_data_remover_browsertest.cc",
      "../browser/browsing_data/browsing_data_remover_browsertest_base.cc",
      "../browser/browsing_data/browsing_data_remover_browsertest_base.h",
      "../browser/browsing_data/chrome_browsing_data_lifetime_manager_browsertest.cc",
      "../browser/browsing_data/counters/autofill_counter_browsertest.cc",
      "../browser/browsing_data/counters/browsing_data_counter_utils_browsertest.cc",
      "../browser/browsing_data/counters/cache_counter_browsertest.cc",
      "../browser/browsing_data/counters/conditional_cache_counting_helper_browsertest.cc",
      "../browser/browsing_data/counters/downloads_counter_browsertest.cc",
      "../browser/browsing_data/counters/history_counter_browsertest.cc",
      "../browser/browsing_data/counters/passwords_counter_browsertest.cc",
      "../browser/browsing_data/counters/sync_aware_counter_browsertest.cc",
      "../browser/browsing_data/incognito_browsing_data_browsertest.cc",
      "../browser/browsing_data/navigation_entry_remover_browsertest.cc",
      "../browser/browsing_topics/browsing_topics_internals_browsertest.cc",
      "../browser/browsing_topics/browsing_topics_service_browsertest.cc",
      "../browser/cart/cart_service_browsertest.cc",
      "../browser/cart/fetch_discount_worker_browsertest.cc",
      "../browser/chained_back_navigation_tracker_browsertest.cc",
      "../browser/chooser_controller/title_util_browsertest.cc",
      "../browser/chrome_back_forward_cache_browsertest.cc",
      "../browser/chrome_content_browser_client_browsertest.cc",
      "../browser/chrome_data_use_measurement_browsertest.cc",
      "../browser/chrome_do_not_track_browsertest.cc",
      "../browser/chrome_navigation_browsertest.cc",
      "../browser/chrome_origin_trials_browsertest.cc",
      "../browser/chrome_security_exploit_browsertest.cc",
      "../browser/chrome_shared_array_buffer_browsertest.cc",
      "../browser/chrome_web_platform_security_metrics_browsertest.cc",
      "../browser/chrome_worker_browsertest.cc",
      "../browser/client_hints/client_hints_browsertest.cc",
      "../browser/component_updater/pki_metadata_component_installer_browsertest.cc",
      "../browser/content_extraction/inner_html_browsertest.cc",
      "../browser/content_extraction/inner_text_browsertest.cc",
      "../browser/content_index/content_index_browsertest.cc",
      "../browser/content_language/content_language_browsertest.cc",
      "../browser/content_settings/mixed_content_settings_tab_helper_browsertest.cc",
      "../browser/content_settings/sound_content_setting_observer_browsertest.cc",
      "../browser/crash_recovery_browsertest.cc",
      "../browser/custom_handlers/protocol_handler_registry_browsertest.cc",
      "../browser/data_saver/data_saver_browsertest.cc",
      "../browser/data_saver/data_saver_webapis_browsertest.cc",
      "../browser/data_sharing/desktop/data_sharing_service_browsertest.cc",
      "../browser/device_api/managed_configuration_api_browsertest.cc",
      "../browser/devtools/device/adb/adb_client_socket_browsertest.cc",
      "../browser/devtools/device/devtools_android_bridge_browsertest.cc",
      "../browser/devtools/device/port_forwarding_browsertest.cc",
      "../browser/devtools/device/usb/android_usb_browsertest.cc",
      "../browser/devtools/devtools_browsertest.cc",
      "../browser/devtools/global_confirm_info_bar_browsertest.cc",
      "../browser/devtools/protocol/devtools_autofill_browsertest.cc",
      "../browser/devtools/protocol/devtools_extensions_browsertest.cc",
      "../browser/devtools/protocol/devtools_protocol_browsertest.cc",
      "../browser/devtools/protocol/devtools_protocol_test_support.cc",
      "../browser/devtools/protocol/devtools_protocol_test_support.h",
      "../browser/devtools/protocol/devtools_pwa_browsertest.cc",
      "../browser/devtools/protocol/form_devtools_issues_browsertest.cc",
      "../browser/direct_sockets/direct_sockets_apitest.cc",
      "../browser/dom_distiller/distillable_page_utils_browsertest.cc",
      "../browser/dom_distiller/dom_distiller_viewer_source_browsertest.cc",
      "../browser/dom_distiller/test_distillation_observers.cc",
      "../browser/dom_distiller/test_distillation_observers.h",
      "../browser/domain_reliability/browsertest.cc",
      "../browser/download/download_browsertest.cc",
      "../browser/download/download_danger_prompt_browsertest.cc",
      "../browser/download/download_frame_policy_browsertest.cc",
      "../browser/download/download_started_animation_browsertest.cc",
      "../browser/download/save_page_browsertest.cc",
      "../browser/engagement/site_engagement_helper_browsertest.cc",
      "../browser/enterprise/browser_management/management_service_browsertest.cc",
      "../browser/enterprise/connectors/reporting/crash_reporting_context_browsertest.cc",
      "../browser/enterprise/util/managed_browser_utils_browsertest.cc",
      "../browser/enterprise/watermark/watermark_browsertest.cc",
      "../browser/extensions/api/bookmark_manager_private/bookmark_manager_private_api_browsertest.cc",
      "../browser/fast_shutdown_browsertest.cc",
      "../browser/favicon/content_favicon_driver_browsertest.cc",
      "../browser/file_system_access/chrome_file_system_access_permission_context_browsertest.cc",
      "../browser/file_system_access/file_system_access_picker_requires_user_gesture_browsertest.cc",
      "../browser/file_system_access/file_system_access_tab_helper_browsertest.cc",
      "../browser/file_system_access/file_system_file_handle_browsertest.cc",
      "../browser/file_system_access/file_system_observer_browsertest.cc",
      "../browser/fingerprinting_protection/fingerprinting_protection_filter_ruleset_browsertest.cc",
      "../browser/first_party_sets/first_party_sets_browsertest.cc",
      "../browser/first_party_sets/first_party_sets_policy_browsertest.cc",
      "../browser/first_run/first_run_browsertest.cc",
      "../browser/geolocation/geolocation_browsertest.cc",
      "../browser/guest_view/mime_handler_view/chrome_mime_handler_view_browsertest.cc",
      "../browser/heavy_ad_intervention/heavy_ad_helper_browsertest.cc",
      "../browser/hid/hid_browsertest.cc",
      "../browser/history/history_browsertest.cc",
      "../browser/history/redirect_browsertest.cc",
      "../browser/history_clusters/history_clusters_metrics_browsertest.cc",
      "../browser/history_embeddings/history_embeddings_service_browsertest.cc",
      "../browser/icon_loader_browsertest.cc",
      "../browser/idle/idle_browsertest.cc",
      "../browser/iframe_browsertest.cc",
      "../browser/image_fetcher/image_fetcher_impl_browsertest.cc",
      "../browser/importer/importer_unittest_utils.cc",
      "../browser/importer/importer_unittest_utils.h",
      "../browser/infobars/infobar_observer.cc",
      "../browser/infobars/infobar_observer.h",
      "../browser/infobars/infobars_browsertest.cc",
      "../browser/interest_group/interest_group_permissions_browsertest.cc",
      "../browser/invalidation/profile_invalidation_provider_factory_browsertest.cc",
      "../browser/k_anonymity_service/k_anonymity_service_client_browsertest.cc",
      "../browser/l10n_util_browsertest.cc",
      "../browser/launch_time_navigation_signal/launch_time_navigation_signal_browsertest.cc",
      "../browser/lifetime/browser_close_manager_browsertest.cc",
      "../browser/lifetime/browser_shutdown_browsertest.cc",
      "../browser/loader/keep_alive_url_browsertest.cc",
      "../browser/loader/signed_exchange_policy_browsertest.cc",
      "../browser/loadtimes_extension_bindings_browsertest.cc",
      "../browser/locale_tests_browsertest.cc",
      "../browser/login_detection/login_detection_browsertest.cc",
      "../browser/lookalikes/lookalike_test_helper.cc",
      "../browser/lookalikes/lookalike_test_helper.h",
      "../browser/lookalikes/lookalike_url_navigation_throttle_browsertest.cc",
      "../browser/media/autoplay_metrics_browsertest.cc",
      "../browser/media/cast_mirroring_service_host_browsertest.cc",
      "../browser/media/defer_background_media_browsertest.cc",
      "../browser/media/encrypted_media_browsertest.cc",
      "../browser/media/encrypted_media_supported_types_browsertest.cc",
      "../browser/media/media_browsertest.cc",
      "../browser/media/media_browsertest.h",
      "../browser/media/media_engagement_autoplay_browsertest.cc",
      "../browser/media/media_engagement_browsertest.cc",
      "../browser/media/media_session_browsertest.cc",
      "../browser/media/test_license_server.cc",
      "../browser/media/test_license_server.h",
      "../browser/media/test_license_server_config.h",
      "../browser/media/unified_autoplay_browsertest.cc",
      "../browser/media/webrtc/display_media_access_handler_browsertest.cc",
      "../browser/media/webrtc/media_stream_devices_controller_browsertest.cc",
      "../browser/media/webrtc/same_origin_observer_browsertest.cc",
      "../browser/media/webrtc/sub_capture_browsertest.cc",
      "../browser/media/webrtc/tab_desktop_media_list_browsertest.cc",
      "../browser/media/webrtc/test_stats_dictionary_unittest.cc",
      "../browser/media/webrtc/webrtc_browsertest_perf.cc",
      "../browser/media/webrtc/webrtc_browsertest_perf.h",
      "../browser/media/webrtc/webrtc_browsertest_perf_unittest.cc",
      "../browser/media/webrtc/webrtc_desktop_capture_browsertest.cc",
      "../browser/media/webrtc/webrtc_disable_encryption_flag_browsertest.cc",
      "../browser/media/webrtc/webrtc_internals_integration_browsertest.cc",
      "../browser/media/webrtc/webrtc_pan_tilt_zoom_browsertest.cc",
      "../browser/media/webrtc/webrtc_stats_perf_browsertest.cc",
      "../browser/media/webrtc/webrtc_video_display_perf_browsertest.cc",
      "../browser/media/webrtc/webrtc_video_high_bitrate_browsertest.cc",
      "../browser/media/webrtc/webrtc_video_quality_browsertest.cc",
      "../browser/media/webrtc/webrtc_webcam_browsertest.cc",
      "../browser/media/wv_test_license_server_config.cc",
      "../browser/media/wv_test_license_server_config.h",
      "../browser/media_galleries/fileapi/media_file_validator_browsertest.cc",
      "../browser/media_galleries/media_galleries_dialog_controller_mock.cc",
      "../browser/media_galleries/media_galleries_dialog_controller_mock.h",
      "../browser/metrics/cloned_install_client_id_reset_browsertest.cc",
      "../browser/metrics/desktop_session_duration/audible_contents_tracker_browsertest.cc",
      "../browser/metrics/metrics_log_browsertest.cc",
      "../browser/metrics/metrics_reporting_state_browsertest.cc",
      "../browser/metrics/metrics_service_browsertest.cc",
      "../browser/metrics/metrics_service_user_demographics_browsertest.cc",
      "../browser/metrics/process_memory_metrics_emitter_browsertest.cc",
      "../browser/metrics/sampled_out_client_id_saved_browsertest.cc",
      "../browser/metrics/startup_metrics_browsertest.cc",
      "../browser/metrics/tab_stats/tab_stats_tracker_browsertest.cc",
      "../browser/metrics/ukm_background_recorder_browsertest.cc",
      "../browser/metrics/ukm_browsertest.cc",
      "../browser/metrics/usage_scenario/tab_usage_scenario_tracker_browsertest.cc",
      "../browser/metrics/variations/field_trials_on_off_browsertest.cc",
      "../browser/metrics/variations/force_field_trials_browsertest.cc",
      "../browser/metrics/variations/limited_entropy_randomization_browsertest.cc",
      "../browser/metrics/variations/variations_http_headers_browsertest.cc",
      "../browser/metrics/variations/variations_safe_mode_browsertest.cc",
      "../browser/metrics/variations/variations_safe_mode_end_to_end_browsertest.cc",
      "../browser/metrics/variations/variations_service_browsertest.cc",
      "../browser/navigation_predictor/anchor_element_preloader_browsertest.cc",
      "../browser/navigation_predictor/navigation_predictor_browsertest.cc",
      "../browser/navigation_predictor/navigation_predictor_preconnect_client_browsertest.cc",
      "../browser/navigation_predictor/search_engine_preconnector_browsertest.cc",
      "../browser/net/cert_verifier_policy_browsertest.cc",
      "../browser/net/cert_verifier_service_browsertest.cc",
      "../browser/net/cert_verify_proc_browsertest.cc",
      "../browser/net/chrome_accept_encoding_header_browsertest.cc",
      "../browser/net/chrome_accept_header_browsertest.cc",
      "../browser/net/chrome_mojo_proxy_resolver_factory_browsertest.cc",
      "../browser/net/chrome_network_delegate_browsertest.cc",
      "../browser/net/chrome_network_service_browsertest.cc",
      "../browser/net/chrome_network_service_restart_browsertest.cc",
      "../browser/net/chrome_shared_dictionary_browsertest.cc",
      "../browser/net/cookie_policy_browsertest.cc",
      "../browser/net/cookie_store_samesite_browsertest.cc",
      "../browser/net/dns_probe_browsertest.cc",
      "../browser/net/errorpage_browsertest.cc",
      "../browser/net/explicitly_allowed_network_ports_browsertest.cc",
      "../browser/net/explicitly_allowed_ports_switch_browsertest.cc",
      "../browser/net/external_protocol_browsertest.cc",
      "../browser/net/load_timing_browsertest.cc",
      "../browser/net/log_net_log_browsertest.cc",
      "../browser/net/net_error_tab_helper_browsertest.cc",
      "../browser/net/netinfo_network_quality_estimator_holdback_browsertest.cc",
      "../browser/net/network_connection_tracker_browsertest.cc",
      "../browser/net/network_context_configuration_browsertest.cc",
      "../browser/net/network_quality_estimator_browsertest.cc",
      "../browser/net/network_quality_estimator_prefs_browsertest.cc",
      "../browser/net/network_quality_netinfo_browsertest.cc",
      "../browser/net/network_quality_tracker_browsertest.cc",
      "../browser/net/network_request_metrics_browsertest.cc",
      "../browser/net/nss_context_chromeos_browsertest.cc",
      "../browser/net/private_network_access_browsertest.cc",
      "../browser/net/profile_network_context_service_browsertest.cc",
      "../browser/net/proxy_browsertest.cc",
      "../browser/net/proxy_test_utils.cc",
      "../browser/net/proxy_test_utils.h",
      "../browser/net/samesite_cookies_policy_browsertest.cc",
      "../browser/net/storage_test_utils.cc",
      "../browser/net/storage_test_utils.h",
      "../browser/net/stub_resolver_config_reader_browsertest.cc",
      "../browser/net/system_network_context_manager_browsertest.cc",
      "../browser/net/trust_token_usecounter_browsertest.cc",
      "../browser/net/websocket_browsertest.cc",
      "../browser/new_tab_page/new_tab_page_util_browsertest.cc",
      "../browser/no_best_effort_tasks_browsertest.cc",
      "../browser/no_best_effort_tasks_during_startup_browsertest.cc",
      "../browser/notifications/notification_permission_browsertest.cc",
      "../browser/notifications/scheduler/notification_schedule_service_browsertest.cc",
      "../browser/ntp_tiles/ntp_tiles_browsertest.cc",
      "../browser/optimization_guide/hints_fetcher_browsertest.cc",
      "../browser/optimization_guide/model_execution/model_execution_browsertest.cc",
      "../browser/optimization_guide/model_execution/model_execution_live_test.cc",
      "../browser/optimization_guide/model_execution/model_execution_validation_browsertest.cc",
      "../browser/optimization_guide/optimization_guide_keyed_service_browsertest.cc",
      "../browser/origin_trials/origin_trials_browsertest.cc",
      "../browser/os_crypt/os_crypt_async_browsertest.cc",
      "../browser/page_content_annotations/page_content_annotations_service_browsertest.cc",
      "../browser/page_content_annotations/page_text_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/abandoned_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/ad_metrics/ad_density_intervention_browsertest.cc",
      "../browser/page_load_metrics/observers/ad_metrics/ads_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/ad_metrics/large_sticky_ad_intervention_browsertest.cc",
      "../browser/page_load_metrics/observers/ad_metrics/overlay_popup_ad_intervention_browsertest.cc",
      "../browser/page_load_metrics/observers/back_forward_cache_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/bookmark_bar_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/core/amp_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/core/ukm_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/foreground_duration_ukm_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/formfill_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/gws_abandoned_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/gws_hp_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/https_engagement_metrics/https_engagement_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/javascript_frameworks_ukm_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/multi_tab_loading_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/new_tab_page_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/page_anchors_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/prefetch_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/prerender_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/preview_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/security_state_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/signed_exchange_page_load_metrics_browsertest.cc",
      "../browser/page_load_metrics/observers/tab_strip_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/third_party_cookie_deprecation_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/third_party_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/observers/use_counter_page_load_metrics_observer_browsertest.cc",
      "../browser/page_load_metrics/page_load_metrics_browsertest.cc",
      "../browser/password_manager/credential_manager_browsertest.cc",
      "../browser/password_manager/password_manager_browsertest.cc",
      "../browser/performance_manager/background_tab_loading_policy_browsertest.cc",
      "../browser/performance_manager/frame_node_impl_browsertest.cc",
      "../browser/performance_manager/mechanisms/page_discarder_browsertest.cc",
      "../browser/performance_manager/observers/page_load_metrics_observer_browsertest.cc",
      "../browser/performance_manager/page_load_tracker_decorator_browsertest.cc",
      "../browser/performance_manager/page_node_browsertest.cc",
      "../browser/performance_manager/persistence/site_data/site_data_cache_facade_browsertest.cc",
      "../browser/performance_manager/policies/bfcache_policy_browsertest.cc",
      "../browser/performance_manager/policies/page_discarding_helper_browsertest.cc",
      "../browser/performance_manager/user_tuning/performance_detection_manager_browsertest.cc",
      "../browser/performance_timeline_browsertest.cc",
      "../browser/picture_in_picture/auto_picture_in_picture_tab_helper_browsertest.cc",
      "../browser/picture_in_picture/auto_picture_in_picture_tab_strip_observer_helper_browsertest.cc",
      "../browser/picture_in_picture/document_picture_in_picture_pixel_browsertest.cc",
      "../browser/picture_in_picture/document_picture_in_picture_window_controller_browsertest.cc",
      "../browser/picture_in_picture/video_picture_in_picture_window_controller_browsertest.cc",
      "../browser/policy/policy_initialization_browsertest.cc",
      "../browser/policy/policy_prefs_browsertest.cc",
      "../browser/policy/test/browsing_history_policy_browsertest.cc",
      "../browser/policy/test/cast_policy_browsertest.cc",
      "../browser/policy/test/content_settings_policy_browsertest.cc",
      "../browser/policy/test/default_search_provider_policy_browsertest.cc",
      "../browser/policy/test/force_google_safe_search_policy_browsertest.cc",
      "../browser/policy/test/history_clusters_policy_browsertest.cc",
      "../browser/policy/test/jit_policy_browsertest.cc",
      "../browser/policy/test/platform_management_service_browsertest.cc",
      "../browser/policy/test/policy_browsertest.cc",
      "../browser/policy/test/policy_test_google_browsertest.cc",
      "../browser/policy/test/restore_on_startup_policy_browsertest.cc",
      "../browser/policy/test/url_blocklist_policy_browsertest.cc",
      "../browser/policy/test/v8_optimizer_policy_browsertest.cc",
      "../browser/predictors/loading_predictor_browsertest.cc",
      "../browser/prefetch/prefetch_browsertest.cc",
      "../browser/prefs/pref_functional_browsertest.cc",
      "../browser/prefs/pref_service_browsertest.cc",
      "../browser/prefs/tracked/pref_hash_browsertest.cc",
      "../browser/preloading/latency_ablation_browsertest.cc",
      "../browser/preloading/prefetch/no_state_prefetch/prerender_nostate_prefetch_browsertest.cc",
      "../browser/preloading/prefetch/search_prefetch/search_prefetch_browser_test_base.cc",
      "../browser/preloading/prefetch/search_prefetch/search_prefetch_browser_test_base.h",
      "../browser/preloading/prefetch/search_prefetch/search_prefetch_service_browsertest.cc",
      "../browser/preloading/prefetch/search_prefetch/search_preload_test_response_utils.cc",
      "../browser/preloading/prefetch/search_prefetch/search_preload_test_response_utils.h",
      "../browser/preloading/prefetch/search_prefetch/search_preload_unified_browsertest.cc",
      "../browser/preloading/prefetch/zero_suggest_prefetch/zero_suggest_prefetch_tab_helper_browsertest.cc",
      "../browser/privacy_sandbox/privacy_sandbox_attestations/privacy_sandbox_attestations_component_installer_browsertest.cc",
      "../browser/privacy_sandbox/privacy_sandbox_countries_browsertest.cc",
      "../browser/privacy_sandbox/privacy_sandbox_notice_confirmation_browsertest.cc",
      "../browser/privacy_sandbox/privacy_sandbox_settings_browsertest.cc",
      "../browser/privacy_sandbox/tracking_protection_settings_browsertest.cc",
      "../browser/private_network_access/chrome_private_network_access_browsertest.cc",
      "../browser/private_network_access/private_network_device_browser_test_utils.cc",
      "../browser/private_network_access/private_network_device_browser_test_utils.h",
      "../browser/profile_resetter/profile_resetter_browsertest.cc",
      "../browser/profiles/host_zoom_map_browsertest.cc",
      "../browser/profiles/incognito_profile_containment_browsertest.cc",
      "../browser/profiles/profile_activity_metrics_recorder_browsertest.cc",
      "../browser/profiles/profile_browsertest.cc",
      "../browser/profiles/profile_list_desktop_browsertest.cc",
      "../browser/profiles/profile_manager_browsertest.cc",
      "../browser/push_messaging/push_messaging_browsertest.cc",
      "../browser/reduce_accept_language/reduce_accept_language_browsertest.cc",
      "../browser/referrer_policy_browsertest.cc",
      "../browser/renderer_context_menu/accessibility_labels_bubble_model_browsertest.cc",
      "../browser/renderer_context_menu/accessibility_labels_menu_observer_browsertest.cc",
      "../browser/renderer_context_menu/render_view_context_menu_browsertest.cc",
      "../browser/renderer_context_menu/spelling_bubble_model_browsertest.cc",
      "../browser/renderer_context_menu/spelling_menu_observer_browsertest.cc",
      "../browser/renderer_host/render_process_host_chrome_browsertest.cc",
      "../browser/repost_form_warning_browsertest.cc",
      "../browser/resource_coordinator/discard_before_unload_helper.cc",
      "../browser/resource_coordinator/discard_before_unload_helper.h",
      "../browser/resource_coordinator/discard_before_unload_helper_browsertest.cc",
      "../browser/resource_coordinator/tab_helper_browsertest.cc",
      "../browser/resource_coordinator/tab_manager_browsertest.cc",
      "../browser/safe_browsing/client_side_detection_service_browsertest.cc",
      "../browser/safe_browsing/download_protection/download_protection_service_browsertest.cc",
      "../browser/safe_xml_parser_browsertest.cc",
      "../browser/screen_ai/optical_character_recognizer_browsertest.cc",
      "../browser/screen_ai/screen_ai_service_router_browsertest.cc",
      "../browser/search/background/wallpaper_search/wallpaper_search_browsertest.cc",
      "../browser/search/ntp_custom_background_enabled_policy_handler_browsertest.cc",
      "../browser/search_engines/template_url_scraper_browsertest.cc",
      "../browser/search_engines/template_url_service_browsertest.cc",
      "../browser/secure_origin_allowlist_browsertest.cc",
      "../browser/segmentation_platform/service_browsertest.cc",
      "../browser/serial/chrome_serial_browsertest.cc",
      "../browser/sessions/better_session_restore_browsertest.cc",
      "../browser/sessions/exit_type_service_browsertest.cc",
      "../browser/sessions/session_id_generator_browsertest.cc",
      "../browser/sessions/session_restore_browsertest.cc",
      "../browser/sessions/session_restore_observer_browsertest.cc",
      "../browser/sessions/session_service_log_browsertest.cc",
      "../browser/sessions/tab_restore_browsertest.cc",
      "../browser/share/qr_code_generator_pixeltest.cc",
      "../browser/signin/e2e_tests/account_capabilities_observer.cc",
      "../browser/signin/e2e_tests/account_capabilities_observer.h",
      "../browser/signin/e2e_tests/accounts_removed_waiter.cc",
      "../browser/signin/e2e_tests/accounts_removed_waiter.h",
      "../browser/signin/e2e_tests/live_sign_in_test.cc",
      "../browser/signin/e2e_tests/live_test.cc",
      "../browser/signin/e2e_tests/live_test.h",
      "../browser/signin/e2e_tests/sign_in_test_observer.cc",
      "../browser/signin/e2e_tests/sign_in_test_observer.h",
      "../browser/signin/e2e_tests/signin_util.cc",
      "../browser/signin/e2e_tests/signin_util.h",
      "../browser/signin/remove_local_account_browsertest.cc",
      "../browser/site_isolation/chrome_site_per_process_browsertest.cc",
      "../browser/site_isolation/chrome_site_per_process_test.cc",
      "../browser/site_isolation/chrome_site_per_process_test.h",
      "../browser/site_isolation/isolated_sandboxed_iframe_browsertest.cc",
      "../browser/site_isolation/origin_agent_cluster_browsertest.cc",
      "../browser/site_isolation/site_details_browsertest.cc",
      "../browser/spellchecker/spellcheck_service_browsertest.cc",
      "../browser/ssl/certificate_transparency_browsertest.cc",
      "../browser/ssl/connection_help_tab_helper_browsertest.cc",
      "../browser/ssl/crlset_browsertest.cc",
      "../browser/ssl/https_upgrades_browsertest.cc",
      "../browser/ssl/known_interception_disclosure_infobar_browsertest.cc",
      "../browser/ssl/known_interception_disclosure_ui_browsertest.cc",
      "../browser/ssl/ocsp_browsertest.cc",
      "../browser/ssl/security_state_tab_helper_browsertest.cc",
      "../browser/ssl/ssl_browsertest.cc",
      "../browser/ssl/ssl_fenced_frame_browsertest.cc",
      "../browser/ssl/ssl_prerender_browsertest.cc",
      "../browser/ssl/stateful_ssl_host_state_delegate_test.cc",
      "../browser/storage/database_access_browsertest.cc",
      "../browser/storage/durable_storage_browsertest.cc",
      "../browser/storage/shared_storage_browsertest.cc",
      "../browser/storage_access_api/api_browsertest.cc",
      "../browser/storage_access_api/storage_access_header_service_browsertest.cc",
      "../browser/subresource_filter/ad_heuristic_tpcd_browsertest.cc",
      "../browser/subresource_filter/ad_tagging_browsertest.cc",
      "../browser/subresource_filter/ads_intervention_manager_browsertest.cc",
      "../browser/subresource_filter/ruleset_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_devtools_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_dns_alias_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_fenced_frame_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_intercepting_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_popup_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_prerender_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_settings_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_special_subframe_navigations_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_web_socket_browsertest.cc",
      "../browser/subresource_filter/subresource_filter_worker_browsertest.cc",
      "../browser/supervised_user/advanced_content_restrictions_interactive_uitest.cc",
      "../browser/supervised_user/incognito_mode_interactive_uitest.cc",
      "../browser/supervised_user/supervised_user_incognito_browsertest.cc",
      "../browser/supervised_user/supervised_user_navigation_throttle_browsertest.cc",
      "../browser/supervised_user/supervised_user_regional_url_filter_browsertest.cc",
      "../browser/supervised_user/supervised_user_service_browsertest.cc",
      "../browser/supervised_user/supervised_user_url_filter_browsertest.cc",
      "../browser/supervised_user/url_filter_interactive_uitest.cc",
      "../browser/support_tool/policy_data_collector_browsertest.cc",
      "../browser/support_tool/screenshot_data_collector_browsertest.cc",
      "../browser/support_tool/support_tool_util_browsertest.cc",
      "../browser/sync/sessions/sync_sessions_router_tab_helper_browsertest.cc",
      "../browser/tab_contents/navigation_metrics_recorder_browsertest.cc",
      "../browser/tab_contents/view_source_browsertest.cc",
      "../browser/task_manager/mock_web_contents_task_manager.cc",
      "../browser/task_manager/mock_web_contents_task_manager.h",
      "../browser/task_manager/providers/web_contents/background_contents_tag_browsertest.cc",
      "../browser/task_manager/providers/web_contents/devtools_tag_browsertest.cc",
      "../browser/task_manager/providers/web_contents/extension_tag_browsertest.cc",
      "../browser/task_manager/providers/web_contents/subframe_task_browsertest.cc",
      "../browser/task_manager/providers/web_contents/tab_contents_tag_browsertest.cc",
      "../browser/task_manager/providers/web_contents/web_app_tag_browsertest.cc",
      "../browser/task_manager/providers/worker_task_provider_browsertest.cc",
      "../browser/task_manager/task_manager_browsertest.cc",
      "../browser/themes/theme_service_browsertest.cc",
      "../browser/top_level_storage_access_api/request_storage_access_for_browsertest.cc",
      "../browser/tpcd/experiment/eligibility_service_browsertest.cc",
      "../browser/tpcd/experiment/experiment_manager_impl_browsertest.cc",
      "../browser/tpcd/heuristics/opener_heuristic_browsertest.cc",
      "../browser/tpcd/metadata/devtools_observer_browsertest.cc",
      "../browser/tpcd/metadata/manager_browsertest.cc",
      "../browser/tpcd/support/origin_trial_service_browsertest.cc",
      "../browser/tpcd/support/top_level_trial_service_browsertest.cc",
      "../browser/tpcd/support/tpcd_support_browsertest.cc",
      "../browser/tpcd/support/validity_service_browsertest.cc",
      "../browser/tracing/chrome_tracing_delegate_browsertest.cc",
      "../browser/translate/language_detection_service_browsertest.cc",
      "../browser/translate/translate_frame_binder_browsertest.cc",
      "../browser/translate/translate_manager_browsertest.cc",
      "../browser/translate/translate_model_service_browsertest.cc",
      "../browser/trusted_vault/trusted_vault_encryption_keys_tab_helper_browsertest.cc",
      "../browser/ui/ask_google_for_suggestions_dialog_browsertest.cc",
      "../browser/ui/bookmarks/bookmark_browsertest.cc",
      "../browser/ui/browser_actions_browsertest.cc",
      "../browser/ui/browser_browsertest.cc",
      "../browser/ui/browser_command_controller_browsertest.cc",
      "../browser/ui/browser_commands_browsertest.cc",
      "../browser/ui/browser_navigator_browsertest.cc",
      "../browser/ui/browser_navigator_browsertest.h",
      "../browser/ui/browser_navigator_iwa_browsertest.cc",
      "../browser/ui/browser_tab_strip_model_delegate_browsertest.cc",
      "../browser/ui/browser_tabrestore_browsertest.cc",
      "../browser/ui/content_settings/content_setting_bubble_model_browsertest.cc",
      "../browser/ui/content_settings/content_setting_image_model_browsertest.cc",
      "../browser/ui/content_settings/framebust_block_browsertest.cc",
      "../browser/ui/exclusive_access/exclusive_access_manager_browsertest.cc",
      "../browser/ui/exclusive_access/fullscreen_controller_browsertest.cc",
      "../browser/ui/exclusive_access/pointer_lock_controller_browsertest.cc",
      "../browser/ui/extensions/extension_enable_flow_browsertest.cc",
      "../browser/ui/extensions/extension_enable_flow_test_delegate.cc",
      "../browser/ui/extensions/extension_enable_flow_test_delegate.h",
      "../browser/ui/extensions/extension_image_util_browsertest.cc",
      "../browser/ui/extensions/extension_side_panel_test_utils.h",
      "../browser/ui/extensions/hosted_app_browsertest.cc",
      "../browser/ui/extensions/notifications_custom_bindings_browsertest.cc",
      "../browser/ui/extensions/settings_overridden_params_providers_browsertest.cc",
      "../browser/ui/hats/hats_service_browsertest.cc",
      "../browser/ui/hats/trust_safety_sentiment_service_browsertest.cc",
      "../browser/ui/javascript_dialogs/javascript_dialog_browsertest.cc",
      "../browser/ui/login/login_handler_browsertest.cc",
      "../browser/ui/managed_ui_browsertest.cc",
      "../browser/ui/native_window_tracker_browsertest.cc",
      "../browser/ui/omnibox/alternate_nav_infobar_delegate_browsertest.cc",
      "../browser/ui/passwords/manage_passwords_test.cc",
      "../browser/ui/passwords/manage_passwords_test.h",
      "../browser/ui/passwords/password_generation_popup_view_browsertest.cc",
      "../browser/ui/passwords/password_generation_popup_view_tester.h",
      "../browser/ui/passwords/well_known_change_password_navigation_throttle_browsertest.cc",
      "../browser/ui/performance_controls/tab_resource_usage_collector_browsertest.cc",
      "../browser/ui/prefs/prefs_tab_helper_browsertest.cc",
      "../browser/ui/privacy_sandbox/privacy_sandbox_prompt_helper_browsertest.cc",
      "../browser/ui/profiles/profile_error_browsertest.cc",
      "../browser/ui/qrcode_generator/qrcode_generator_bubble_controller_policy_browsertest.cc",
      "../browser/ui/renderer_event_injection_browsertest.cc",
      "../browser/ui/safety_hub/mock_safe_browsing_database_manager.cc",
      "../browser/ui/safety_hub/mock_safe_browsing_database_manager.h",
      "../browser/ui/safety_hub/safety_hub_util.cc",
      "../browser/ui/safety_hub/safety_hub_util.h",
      "../browser/ui/safety_hub/unused_site_permissions_service_browsertest.cc",
      "../browser/ui/search/instant_test_base.cc",
      "../browser/ui/search/instant_test_base.h",
      "../browser/ui/search/new_tab_page_navigation_throttle_browsertest.cc",
      "../browser/ui/search/third_party_ntp_browsertest.cc",
      "../browser/ui/search_engines/search_engine_tab_helper_browsertest.cc",
      "../browser/ui/startup/startup_browser_creator_browsertest.cc",
      "../browser/ui/sync/one_click_signin_links_delegate_impl_browsertest.cc",
      "../browser/ui/tab_modal_confirm_dialog_browsertest.cc",
      "../browser/ui/tab_modal_confirm_dialog_browsertest.h",
      "../browser/ui/tab_ui_helper_browsertest.cc",
      "../browser/ui/tabs/organization/tab_declutter_controller_browsertest.cc",
      "../browser/ui/tabs/organization/tab_sensitivity_cache_browsertest.cc",
      "../browser/ui/tabs/pinned_tab_service_browsertest.cc",
      "../browser/ui/tabs/tab_strip_model_browsertest.cc",
      "../browser/ui/test/browser_ui_browsertest.cc",
      "../browser/ui/test/browser_ui_test_base.cc",
      "../browser/ui/test/browser_ui_test_base.h",
      "../browser/ui/test/fullscreen_test_util.cc",
      "../browser/ui/test/fullscreen_test_util.h",
      "../browser/ui/test/popup_browsertest.cc",
      "../browser/ui/test/test_browser_dialog.cc",
      "../browser/ui/test/test_browser_dialog.h",
      "../browser/ui/test/test_infobar.cc",
      "../browser/ui/test/test_infobar.h",
      "../browser/ui/thumbnails/thumbnail_readiness_tracker_browsertest.cc",
      "../browser/ui/toolbar/pinned_toolbar/pinned_toolbar_actions_model_browsertest.cc",
      "../browser/ui/toolbar/toolbar_actions_model_browsertest.cc",
      "../browser/ui/unload_controller_browsertest.cc",
      "../browser/ui/update_chrome_dialog_browsertest.cc",
      "../browser/ui/user_education/low_usage_help_controller_browsertest.cc",
      "../browser/ui/user_education/show_promo_in_page_browsertest.cc",
      "../browser/ui/user_education/start_tutorial_in_page_browsertest.cc",
      "../browser/ui/user_education/user_education_configuration_provider_browsertest.cc",
      "../browser/ui/views/apps/app_info_dialog/app_info_dialog_views_browsertest.cc",
      "../browser/ui/views/autofill/payments/offer_notification_icon_view_browsertest.cc",
      "../browser/ui/views/bluetooth_device_credentials_view_browsertest.cc",
      "../browser/ui/views/bluetooth_device_pair_confirm_view_browsertest.cc",
      "../browser/ui/views/bookmarks/bookmark_bar_view_browsertest.cc",
      "../browser/ui/views/bookmarks/bookmark_bar_view_test_helper.h",
      "../browser/ui/views/bookmarks/saved_tab_groups/saved_tab_group_bar_browsertest.cc",
      "../browser/ui/views/commerce/shopping_ui_handler_delegate_uitest.cc",
      "../browser/ui/views/confirm_bubble_views_browsertest.cc",
      "../browser/ui/views/content_setting_bubble_contents_browsertest.cc",
      "../browser/ui/views/content_test_utils.cc",
      "../browser/ui/views/content_test_utils.h",
      "../browser/ui/views/device_chooser_browsertest.cc",
      "../browser/ui/views/digital_credentials/digital_identity_multi_step_dialog_browsertest.cc",
      "../browser/ui/views/digital_credentials/digital_identity_safety_interstitial_integration_test.cc",
      "../browser/ui/views/extensions/extension_install_dialog_view_supervised_browsertest.cc",
      "../browser/ui/views/eye_dropper/eye_dropper_browsertest.cc",
      "../browser/ui/views/file_system_access/file_system_access_test_utils.cc",
      "../browser/ui/views/file_system_access/file_system_access_test_utils.h",
      "../browser/ui/views/hats/hats_browsertest.cc",
      "../browser/ui/views/incognito_clear_browsing_data_dialog_browsertest.cc",
      "../browser/ui/views/intent_picker_dialog_browsertest.cc",
      "../browser/ui/views/privacy_sandbox/privacy_sandbox_dialog_view_browsertest.cc",
      "../browser/ui/views/profiles/avatar_toolbar_button_browsertest.cc",
      "../browser/ui/views/sharing/remote_copy_browsertest.cc",
      "../browser/ui/views/sharing/shared_clipboard_browsertest.cc",
      "../browser/ui/views/sharing/sharing_browsertest.cc",
      "../browser/ui/views/sharing/sharing_browsertest.h",
      "../browser/ui/views/side_panel/lens/lens_core_tab_side_panel_helper_browsertest.cc",
      "../browser/ui/views/side_panel/search_companion/companion_live_test.cc",
      "../browser/ui/views/tab_search_bubble_host_browsertest.cc",
      "../browser/ui/views/tabs/tab_search_button_browsertest.cc",
      "../browser/ui/views/tabs/tab_search_container_browsertest.cc",
      "../browser/ui/views/tabs/tab_strip_browsertest.cc",
      "../browser/ui/views/toolbar/app_menu_browsertest.cc",
      "../browser/ui/views/toolbar/chrome_labs/chrome_labs_browsertest.cc",
      "../browser/ui/views/toolbar/home_button_browsertest.cc",
      "../browser/ui/views/toolbar/pinned_toolbar_actions_container_browsertest.cc",
      "../browser/ui/views/user_education/browser_user_education_service_browsertest.cc",
      "../browser/ui/views/web_apps/frame_toolbar/web_app_frame_toolbar_browsertest.cc",
      "../browser/ui/views/web_apps/frame_toolbar/web_app_minimal_ui_test.cc",
      "../browser/ui/views/web_apps/isolated_web_apps/isolated_web_app_installer_browsertest.cc",
      "../browser/ui/views/web_apps/isolated_web_apps/isolated_web_app_installer_view_browsertest.cc",
      "../browser/ui/views/web_apps/protocol_handler_launch_dialog_browsertest.cc",
      "../browser/ui/views/web_apps/web_app_detailed_install_dialog_browsertest.cc",
      "../browser/ui/views/web_apps/web_app_diy_install_dialog_browsertest.cc",
      "../browser/ui/views/web_apps/web_app_tab_strip_browsertest.cc",
      "../browser/ui/views/web_apps/web_ui_web_app_browsertest.cc",
      "../browser/ui/views/webauthn/authenticator_dialog_view_browsertest.cc",
      "../browser/ui/views/webid/account_selection_modal_view_browsertest.cc",
      "../browser/ui/views/webid/account_selection_view_test_base.cc",
      "../browser/ui/views/webid/account_selection_view_test_base.h",
      "../browser/ui/views/webid/fake_delegate.cc",
      "../browser/ui/views/webid/fake_delegate.h",
      "../browser/ui/views/webid/fedcm_account_selection_view_desktop_browsertest.cc",
      "../browser/ui/views/webview_accessibility_browsertest.cc",
      "../browser/ui/webauthn/authenticator_dialog_browsertest.cc",
      "../browser/ui/webui/app_service_internals/app_service_internals_browsertest.cc",
      "../browser/ui/webui/autofill_and_password_manager_internals/autofill_internals_ui_browsertest.cc",
      "../browser/ui/webui/chrome_content_browser_client_webui_part_browsertest.cc",
      "../browser/ui/webui/chrome_url_data_manager_browsertest.cc",
      "../browser/ui/webui/chrome_web_ui_controller_factory_browsertest.cc",
      "../browser/ui/webui/chrome_webui_navigation_browsertest.cc",
      "../browser/ui/webui/commerce/product_specifications_disclosure_dialog_browsertest.cc",
      "../browser/ui/webui/commerce/shopping_ui_handler_delegate_browsertest.cc",
      "../browser/ui/webui/constrained_web_dialog_ui_browsertest.cc",
      "../browser/ui/webui/extensions/extension_settings_browsertest.cc",
      "../browser/ui/webui/extensions/extensions_internals_browsertest.cc",
      "../browser/ui/webui/history_clusters/history_clusters_handler_browsertest.cc",
      "../browser/ui/webui/interstitials/interstitial_ui_browsertest.cc",
      "../browser/ui/webui/location_internals/location_internals_ui_browsertest.cc",
      "../browser/ui/webui/log_web_ui_url_browsertest.cc",
      "../browser/ui/webui/management/management_ui_browsertest.cc",
      "../browser/ui/webui/management/management_ui_pwa_browsertest.cc",
      "../browser/ui/webui/new_tab_page/webui_ntp_browsertest.cc",
      "../browser/ui/webui/ntp/new_tab_ui_browsertest.cc",
      "../browser/ui/webui/policy/policy_test_ui_browsertest.cc",
      "../browser/ui/webui/policy/policy_ui_browsertest.cc",
      "../browser/ui/webui/prefs_internals_browsertest.cc",
      "../browser/ui/webui/privacy_sandbox/privacy_sandbox_internals_browsertest.cc",
      "../browser/ui/webui/privacy_sandbox/privacy_sandbox_internals_handler_browsertest.cc",
      "../browser/ui/webui/profile_helper_browsertest.cc",
      "../browser/ui/webui/searchbox/realbox_handler_browsertest.cc",
      "../browser/ui/webui/settings/appearance_handler_browsertest.cc",
      "../browser/ui/webui/settings/settings_secure_dns_handler_browsertest.cc",
      "../browser/ui/webui/settings/settings_ui_browsertest.cc",
      "../browser/ui/webui/side_panel/customize_chrome/customize_chrome_browsertest.cc",
      "../browser/ui/webui/side_panel/read_anything/read_anything_app_e2e_browsertest.cc",
      "../browser/ui/webui/support_tool/support_tool_ui_browsertest.cc",
      "../browser/ui/webui/tab_search/tab_search_ui_browsertest.cc",
      "../browser/ui/webui/top_chrome/webui_contents_preload_manager_browsertest.cc",
      "../browser/ui/webui/webui_load_timer_browsertest.cc",
      "../browser/ui/webui/webui_url_hashes_browsertest.cc",
      "../browser/ukm_worker_browsertest.cc",
      "../browser/unload_browsertest.cc",
      "../browser/usb/chrome_usb_browsertest.cc",
      "../browser/usb/usb_browser_test_utils.cc",
      "../browser/usb/usb_browser_test_utils.h",
      "../browser/user_agent/user_agent_browsertest.cc",
      "../browser/user_annotations/user_annotations_service_browsertest.cc",
      "../browser/wake_lock/wake_lock_browsertest.cc",
      "../browser/web_applications/alternative_error_page_override_info_browsertest.cc",
      "../browser/webapps/installable/installable_manager_browsertest.cc",
      "../browser/webapps/installable/ml_promotion_browsertest.cc",
      "../browser/webapps/web_contents/web_app_url_loader_browsertest.cc",
      "../browser/webauthn/chrome_webauthn_browsertest.cc",
      "../browser/window_management/screen_details_browsertest.cc",
      "../browser/window_management/window_management_browsertest.cc",
      "../browser/window_management/window_management_permission_context_browsertest.cc",
      "../common/time_format_browsertest.cc",
      "../renderer/accessibility/ax_tree_distiller_browsertest.cc",
      "../renderer/accessibility/read_aloud_app_model_browsertest.cc",
      "../renderer/accessibility/read_anything_app_controller_browsertest.cc",
      "../renderer/accessibility/read_anything_app_model_browsertest.cc",
      "../renderer/accessibility/read_anything_test_utils.cc",
      "../renderer/accessibility/read_anything_test_utils.h",
      "../renderer/autofill/autofill_renderer_browsertest.cc",
      "../renderer/autofill/fake_mojo_password_manager_driver.cc",
      "../renderer/autofill/fake_mojo_password_manager_driver.h",
      "../renderer/autofill/fake_password_generation_driver.cc",
      "../renderer/autofill/fake_password_generation_driver.h",
      "../renderer/autofill/form_autocomplete_browsertest.cc",
      "../renderer/autofill/form_autofill_browsertest.cc",
      "../renderer/autofill/page_passwords_analyser_browsertest.cc",
      "../renderer/autofill/password_autofill_agent_browsertest.cc",
      "../renderer/autofill/password_generation_agent_browsertest.cc",
      "../renderer/autofill/password_generation_test_utils.cc",
      "../renderer/autofill/password_generation_test_utils.h",
      "../renderer/cart/commerce_hint_agent_browsertest.cc",
      "../renderer/cart/commerce_hint_agent_renderer_browsertest.cc",
      "../renderer/chrome_content_renderer_client_browsertest.cc",
      "../renderer/chrome_content_settings_agent_delegate_browsertest.cc",
      "../renderer/chrome_render_frame_observer_browsertest.cc",
      "../renderer/commerce/commerce_web_extractor_browsertest.cc",
      "../renderer/translate/translate_agent_browsertest.cc",
      "../renderer/translate/translate_script_browsertest.cc",
      "base/devtools_listener.cc",
      "base/devtools_listener.h",
      "base/devtools_listener_browsertest.cc",
      "base/in_process_browser_test_browsertest.cc",
      "base/memory_tracing_browsertest.cc",
      "base/save_desktop_snapshot_browsertest.cc",
      "base/test_chrome_web_ui_controller_factory_browsertest.cc",
      "base/ui_test_utils_browsertest.cc",
      "base/web_ui_mocha_browser_test_browsertest.cc",
      "data/webui/mojo/mojo_file_system_access_browsertest.cc",
      "data/webui/mojo/mojo_js_interface_broker_browsertest.cc",
      "data/webui/mojo/mojo_web_ui_controller_browsertest.cc",
      "gpu/webgl_infobar_browsertest.cc",
      "interaction/interaction_test_util_browser_browsertest.cc",
      "interaction/interactive_browser_test_browsertest.cc",
      "interaction/webcontents_interaction_test_util_browsertest.cc",
      "supervised_user/family_live_test.cc",
      "supervised_user/family_live_test.h",
      "supervised_user/family_member.cc",
      "supervised_user/family_member.h",
      "supervised_user/test_state_seeded_observer.cc",
      "supervised_user/test_state_seeded_observer.h",
      "v8/wasm_trap_handler_browsertest.cc",
    ]

    if (is_android) {
      sources += [ "../browser/dom_distiller/tab_utils_browsertest.cc" ]
    }

    if (!is_chrome_for_testing) {
      sources += [ "../browser/search_engine_choice/search_engine_choice_dialog_browsertest.cc" ]
    }

    if (enable_compose) {
      sources += [
        "../browser/compose/compose_dialog_browsertest.cc",
        "../browser/compose/compose_enabling_browsertest.cc",
      ]

      deps += [
        "//components/compose/core/browser",
        "//components/compose/core/browser:features",
      ]
    }

    if (is_win || is_mac || is_linux || is_chromeos_ash) {
      sources += [ "../browser/ui/views/device_signals_consent/consent_dialog_browsertest.cc" ]
    }

    if (enable_nacl) {
      sources += [ "../browser/chrome_browser_main_extra_parts_nacl_deprecation_browsertest.cc" ]
    }

    if (is_chrome_branded && !is_chromeos) {
      sources += [ "../browser/ui/views/side_panel/search_companion/companion_page_browsertest.cc" ]
    }

    if (is_chrome_branded && !is_android) {
      sources += [
        "../browser/ui/views/promos/ios_promo_bubble_browsertest.cc",
        "../browser/ui/views/promos/ios_promo_password_bubble_browsertest.cc",
        "../browser/ui/views/user_education/low_usage_promo_browsertest.cc",
      ]

      deps += [ "//chrome/browser/promos:utils" ]
    }

    if (build_with_tflite_lib) {
      sources += [
        "../browser/optimization_guide/prediction/prediction_manager_browsertest.cc",
        "../browser/optimization_guide/prediction/prediction_model_store_browsertest.cc",
      ]
    }

    if (is_chrome_for_testing) {
      sources += [ "../browser/chrome_for_testing/chrome_for_testing_info_bar_browsertest.cc" ]
    }

    if (enable_reporting) {
      sources += [ "../browser/net/reporting_browsertest.cc" ]
    }

    if (enable_screen_ai_browsertests) {
      sources +=
          [ "../browser/screen_ai/main_content_extraction_browsertest.cc" ]

      # Add a data dependency for screen_ai_service_router_browsertest.cc to
      # notify testing builders that this test needs this library, which will
      # need to be downloaded from CIPD as defined in //DEPS.
      data_deps += [ "//third_party/screen-ai:screen_ai" ]
    }

    if (enable_allocation_trace_recorder_integration_tests) {
      sources += [ "../browser/allocation_recorder_browsertest.cc" ]
      deps += [ "//components/allocation_recorder/testing" ]
    }

    if (!is_chromeos_lacros) {
      sources += [
        # Lacros does not seem to have any actual WebView-based UI to test.
        "../browser/accessibility/live_translate_controller_browsertest.cc",

        # These tests also run on Lacros, as part of
        # lacros_chrome_browsertests below.
        "../browser/media/webrtc/capture_handle_browsertest.cc",
        "../browser/media/webrtc/webrtc_getdisplaymedia_browsertest.cc",
        "../browser/ui/autofill/autofill_context_menu_manager_browsertest.cc",
        "../browser/ui/views/intent_picker_bubble_view_browsertest.cc",
        "../browser/ui/views/location_bar/intent_chip_button_browsertest.cc",
        "../browser/ui/views/tabs/alert_indicator_button_browsertest.cc",
        "../browser/ui/views/web_apps/web_app_integration_browsertest.cc",
      ]

      deps += [
        "//chrome/browser/apps/link_capturing:app_service_browser_tests",
        "//chrome/browser/ui/web_applications:app_service_browser_tests",
        "//chrome/browser/web_applications:app_service_browser_tests",
        "//components/autofill_prediction_improvements/core/browser:browser",
        "//components/live_caption:live_translate",
        "//components/plus_addresses:blocklist_data",
      ]
      if (!is_win || target_cpu != "arm64") {
        # SODA doesn't support Windows on Arm64, and Lacros delegates rendering
        # captions to Ash.
        sources += [
          "../browser/accessibility/live_caption/live_caption_controller_browsertest.cc",
          "../browser/accessibility/live_caption/live_caption_speech_recognition_host_browsertest.cc",
          "../browser/accessibility/live_caption/live_caption_speech_recognition_host_browsertest.h",
        ]

        if (is_win || is_mac || is_linux) {
          sources += [ "../browser/accessibility/live_caption/live_caption_automatic_language_download_browsertest.cc" ]
        }
      }

      if (enterprise_cloud_content_analysis) {
        sources += [
          # crbug.com/1230268 These tests need to be fixed for Lacros.
          "../browser/enterprise/connectors/analysis/content_analysis_delegate_browsertest.cc",
          "../browser/safe_browsing/cloud_content_scanning/cloud_binary_upload_service_browsertest.cc",
          "../browser/safe_browsing/download_protection/deep_scanning_browsertest.cc",
        ]
        deps += [ "../browser/enterprise/connectors/analysis:features" ]
      }
    }

    if (is_win) {
      sources += [
        "../browser/accessibility/live_caption/live_caption_unavailability_notifier_browsertest.cc",
        "../browser/ui/views/device_id/pen_id_browsertest_win.cc",
        "../browser/ui/views/tab_search_bubble_ui_browsertest.cc",
        "../browser/ui/views/web_apps/web_app_integration_browsertest_win.cc",
      ]
      sources -= [ "../browser/ui/views/tabs/tab_search_button_browsertest.cc" ]
    }

    if (is_win || is_linux) {
      sources += [ "../browser/ui/views/web_apps/web_app_integration_browsertest_win_linux.cc" ]
    }

    if (is_win || is_linux || is_chromeos_ash) {
      sources += [ "../browser/ui/views/web_apps/web_app_integration_browsertest_win_linux_cros.cc" ]
    }

    if (is_chromeos_ash) {
      data += [ "//chrome/browser/resources/chromeos/arc_support/i18n_template_no_process.js" ]
      sources += [
        "../browser/accessibility/media_app/ax_media_app_untrusted_handler_browsertest.cc",
        "../browser/certificate_manager_model_ash_browsertest.cc",
        "../browser/chromeos/enterprise/cloud_storage/one_drive_pref_observer_browsertest.cc",
        "../browser/media/webrtc/capture_policy_utils_browsertest.cc",
        "../browser/media/webrtc/get_all_screens_media_browsertest.cc",
        "../browser/sessions/tab_restore_service_browsertest.cc",
        "../browser/support_tool/signin_data_collector_browsertest.cc",
        "../browser/ui/quick_answers/ui/quick_answers_pixeltest.cc",
        "../browser/ui/views/mahi/mahi_menu_pixeltest.cc",
        "../browser/ui/views/web_apps/web_app_integration_browsertest_cros.cc",
        "base/ash/web_ui_browser_test_browsertest.cc",
        "data/webui/chromeos/async_gen.cc",
        "data/webui/chromeos/async_gen.h",
      ]
      deps += [
        "//ash/webui/system_apps/public:system_web_app_type",
        "//chrome/browser/apps/app_service/app_install",
        "//chrome/browser/apps/app_service/app_install:proto",
        "//chrome/browser/ash/system_web_apps/test_support",
        "//chrome/browser/ash/system_web_apps/test_support:test_support_ui",
        "//chrome/browser/ash/system_web_apps/types",
        "//chrome/browser/ui/ash/system_web_apps",
        "//chrome/test/data/webui/chromeos:web_ui_test_bindings",
        "//chromeos/ash/components/standalone_browser",
        "//chromeos/components/kiosk:test_support",
        "//chromeos/components/quick_answers/public/cpp:constants",
        "//components/component_updater/ash:test_support",
        "//components/user_manager:test_support",
        "//mojo/public/cpp/test_support:test_utils",
      ]
    }

    if (build_with_tflite_lib) {
      sources += [ "../browser/navigation_predictor/preloading_model_keyed_service_browsertest.cc" ]
      data += [
        "../browser/navigation_predictor/test/preloading_heuristics.tflite",
      ]
    }

    #If this target is used on Android in the future, these browser / speech/*
    # files will probably not be applicable.
    sources += [
      "../browser/speech/extension_api/tts_extension_apitest.cc",
      "../browser/speech/speech_recognition_browsertest.cc",
    ]

    if (enable_click_to_call) {
      sources += [ "../browser/ui/views/sharing/click_to_call_browsertest.cc" ]
      deps += [ "//components/sharing_message" ]
    }

    if (enable_pdf) {
      sources += [
        "../browser/accessibility/pdf_ocr_controller_browsertest.cc",
        "../browser/pdf/pdf_extension_accessibility_test.cc",
        "../browser/pdf/pdf_extension_download_test.cc",
        "../browser/pdf/pdf_extension_js_test.cc",
        "../browser/pdf/pdf_extension_test.cc",
        "../browser/pdf/pdf_find_request_manager_browsertest.cc",
        "../browser/plugins/pdf_iframe_navigation_throttle_browsertest.cc",
      ]
      deps += [
        "../browser/pdf",
        "../browser/pdf:pdf_extension_test_utils",
        "//components/pdf/browser",
        "//components/pdf/common:constants",
        "//components/pdf/common:util",
        "//pdf:features",
        "//pdf/loader",
      ]

      if (enable_printing) {
        sources += [ "../browser/pdf/pdf_extension_printing_test.cc" ]

        # TODO(crbug.com/40892214): All printToPdf tests consistently fail on ChromeOS
        if (!is_chromeos) {
          sources += [
            "../browser/devtools/protocol/devtools_printtopdf_browsertest.cc",
          ]
          deps += [
            "//components/headless/test",
            "//components/printing/browser",
            "//pdf",
          ]
        }
      }
    }

    if (safe_browsing_mode != 0) {
      deps += [ "//components/safe_browsing/content/common/proto:download_file_types_proto" ]
    }

    if (is_linux) {
      sources += [
        "../browser/ozone_platform_browsertest.cc",
        "../browser/ui/views/frame/desktop_browser_frame_aura_linux_browsertest.cc",
      ]
      deps += [
        "//ui/linux:linux_ui",
        "//ui/linux:linux_ui_factory",
      ]
    }

    if (is_linux || is_chromeos) {
      sources += [
        "../browser/error_reporting/webui_js_error_reporting_browsertest.cc",
      ]
      deps += [ "//chrome/browser/error_reporting:test_support" ]
    }

    if (is_chromeos) {
      deps += [
        "//chrome/browser/chromeos",
        "//chrome/browser/chromeos/cros_apps:all_browser_tests",
        "//chrome/browser/chromeos/video_conference",
        "//chrome/browser/ui/chromeos",
        "//chrome/browser/ui/chromeos:test_support",
        "//chrome/browser/web_applications/app_service",
        "//chrome/browser/web_applications/app_service:test_support",
        "//chromeos/components/kcer",
        "//chromeos/constants",
        "//chromeos/dbus/dlp:dlp",
        "//chromeos/dbus/regmon",
        "//chromeos/ui/frame",
        "//components/account_manager_core:test_support",
        "//components/file_access:test_support",
        "//ui/chromeos/styles:cros_tokens_color_mappings",
      ]
      sources += [
        "../browser/browser_process_platform_part_chromeos_browsertest.cc",
        "../browser/chromeos/enterprise/incognito_navigation_throttle_browsertest.cc",
        "../browser/download/notification/download_notification_browsertest.cc",
        "../browser/file_system_access/cloud_identifier/cloud_identifier_util_cros_browsertest.cc",
        "../browser/net/network_annotation_monitor_browsertest.cc",
      ]
    }

    if (is_linux) {
      sources += [
        "../browser/chrome_main_process_singleton_browsertest.cc",
        "../browser/process_singleton_browsertest.cc",
      ]
    }

    if (is_win || is_mac) {
      sources += [
        "../browser/enterprise/platform_auth/platform_auth_policy_observer_browsertest.cc",
        "../browser/enterprise/platform_auth/platform_auth_provider_manager_browsertest.cc",
      ]

      deps += [ "//chrome/browser/enterprise/platform_auth:test_utils" ]
    }

    if (is_win) {
      sources += [
        "../browser/chrome_browser_main_win_browsertest.cc",
        "../browser/chrome_main_process_singleton_browsertest.cc",
        "../browser/font_prewarmer_tab_helper_browsertest.cc",
        "../browser/importer/edge_importer_browsertest_win.cc",
        "../browser/importer/ie_importer_browsertest_win.cc",
        "../browser/net/chrome_mojo_proxy_resolver_win_browsertest.cc",
        "../browser/printing/pdf_to_emf_converter_browsertest.cc",
        "../browser/process_singleton_browsertest.cc",
        "../browser/profiles/profile_shortcut_manager_browsertest_win.cc",
        "../browser/spellchecker/spell_check_host_chrome_impl_win_browsertest.cc",
        "../browser/ui/color/win/native_chrome_color_mixer_win_browsertest.cc",
        "../browser/ui/startup/credential_provider_signin_dialog_win_browsertest.cc",
        "../browser/ui/startup/startup_browser_creator_corrupt_profiles_browsertest_win.cc",
        "../browser/ui/startup/startup_browser_creator_triggered_reset_browsertest_win.cc",
        "../browser/ui/views/uninstall_view_browsertest.cc",
        "../test/delayload/delayload_hook_browsertest.cc",
      ]

      data_deps += [ "//chrome/browser/web_applications/chrome_pwa_launcher" ]
      data += [ "$root_out_dir/chrome_200_percent.pak" ]
      deps += [
        "//chrome:other_version",
        "//chrome/app:chrome_dll_resources",
        "//chrome/app:command_ids",
        "//chrome/browser/ui/startup:buildflags",
        "//chrome/credential_provider/common:common_constants",
        "//chrome/test:credential_provider_test_utils",
        "//components/onc",
        "//sandbox/win:sandbox",
        "//third_party/wtl",
        "//ui/color:accent_color_observer",
        "//ui/resources",
      ]

      if (target_cpu == "x64") {
        sources += [ "../common/profiler/thread_profiler_browsertest.cc" ]
      }

      if (is_chrome_branded) {
        deps += [ "//chrome/browser/win/conflicts:browser_tests" ]
      }
    }

    if (is_mac) {
      sources += [
        "../browser/app_controller_mac_browsertest.mm",
        "../browser/apps/app_shim/app_shim_listener_browsertest.mm",
        "../browser/apps/app_shim/test/app_shim_listener_test_api_mac.cc",
        "../browser/apps/app_shim/test/app_shim_listener_test_api_mac.h",
        "../browser/chrome_browser_application_mac_browsertest.mm",
        "../browser/enterprise/platform_auth/extensible_enterprise_sso_provider_mac_browsertest.cc",
        "../browser/mac/auth_session_request_browsertest.mm",
        "../browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper_browsertest.mm",
        "../browser/spellchecker/spell_check_host_chrome_impl_mac_browsertest.cc",
        "../browser/ui/cocoa/accelerators_cocoa_browsertest.mm",
        "../browser/ui/cocoa/applescript/bookmark_applescript_test_utils.h",
        "../browser/ui/cocoa/applescript/bookmark_applescript_test_utils.mm",
        "../browser/ui/cocoa/applescript/bookmark_folder_applescript_browsertest.mm",
        "../browser/ui/cocoa/applescript/bookmark_item_applescript_browsertest.mm",
        "../browser/ui/cocoa/applescript/browsercrapplication+applescript_browsertest.mm",
        "../browser/ui/cocoa/applescript/tab_applescript_browsertest.mm",
        "../browser/ui/cocoa/applescript/window_applescript_browsertest.mm",
        "../browser/ui/cocoa/apps/native_app_window_cocoa_browsertest.mm",
        "../browser/ui/cocoa/browser_window_mac_browsertest.mm",
        "../browser/ui/cocoa/renderer_context_menu/render_view_context_menu_mac_cocoa_browsertest.mm",
        "../browser/ui/cocoa/share_menu_controller_browsertest.mm",
        "../browser/ui/cocoa/task_manager_mac_browsertest.mm",
        "../browser/ui/cocoa/touchbar/browser_window_touch_bar_controller_browsertest.mm",
        "../browser/ui/fullscreen_util_mac_browsertest.cc",
        "../browser/ui/test/test_browser_dialog_mac.h",
        "../browser/ui/test/test_browser_dialog_mac.mm",
        "../browser/ui/views/frame/browser_non_client_frame_view_mac_browsertest.mm",
        "../browser/ui/views/fullscreen_mac_browsertest.cc",
        "../browser/ui/views/web_apps/app_shim_metrics_browsertest.cc",
        "../browser/ui/views/web_apps/web_app_integration_browsertest_mac.cc",
        "../browser/web_applications/system_media_controls_bridge_browsertest.cc",
        "../browser/webshare/mac/sharing_service_operation_browsertest.cc",
        "../common/mac/app_mode_chrome_locator_browsertest.mm",
        "../common/profiler/thread_profiler_browsertest.cc",
      ]
      sources -= [
        # TODO(groby): This test depends on hunspell and we cannot run it on
        # Mac, which does not use hunspell by default.
        "../browser/spellchecker/spellcheck_service_browsertest.cc",
      ]

      data_deps += [
        "//chrome",
        "//chrome:chrome_framework",
      ]

      deps += [
        "//chrome/app_shim",
        "//chrome/browser/apps/app_shim",
        "//chrome/browser/renderer_host:history_swiper",
        "//chrome/browser/shortcuts",
        "//components/onc",
        "//components/remote_cocoa/app_shim",
        "//components/system_media_controls",
        "//content/test:test_support",
        "//mojo/core/embedder",
        "//third_party/ipcz/src:ipcz_chromium",
        "//third_party/ocmock",
        "//ui/accelerated_widget_mac",
      ]
    } else {
      # !is_mac
      sources += [
        "../browser/ui/views/create_application_shortcut_view_browsertest.cc",
      ]

      data_deps += [ "//chrome:packed_resources" ]
    }

    if (enable_soda_integration_tests) {
      assert(enable_speech_service)
      sources +=
          [ "../browser/speech/speech_recognition_service_browsertest.cc" ]
      deps += [
        "//chrome/services/speech:lib",
        "//chrome/services/speech/soda",
      ]
      if (is_mac) {
        data_deps += [ "//third_party/soda-mac64:soda_resources" ]
      } else if (is_win && target_cpu == "x86") {
        data_deps += [ "//third_party/soda-win32:soda_resources" ]
      } else if (is_win && target_cpu == "x64") {
        data_deps += [ "//third_party/soda-win64:soda_resources" ]
      } else {
        data_deps += [ "//third_party/soda:soda_resources" ]
      }
    }

    if (use_ozone) {
      deps += [ "//ui/ozone" ]
    }

    if (!is_chromeos_ash) {
      sources += [
        "../browser/chrome_multiprofile_startup_browsertest.cc",
        "../browser/enterprise/remote_commands/user_remote_commands_service_browsertest.cc",
        "../browser/enterprise/reporting/cloud_profile_reporting_browsertest.cc",
        "../browser/profiles/avatar_menu_browsertest.cc",
        "../browser/profiles/delete_profile_helper_browsertest.cc",
        "../browser/profiles/profile_keyed_service_browsertest.cc",
        "../browser/profiles/profile_window_browsertest.cc",
        "../browser/ui/views/accessibility/accessibility_focus_highlight_browsertest.cc",
        "../browser/ui/views/profiles/signin_view_controller_delegate_views_browsertest.cc",
      ]
      if (!is_chromeos_lacros) {
        sources += [ "../browser/external_protocol/external_protocol_handler_browsertest.cc" ]
      }
      sources -= [
        "../browser/invalidation/profile_invalidation_provider_factory_browsertest.cc",
        "../browser/net/nss_context_chromeos_browsertest.cc",
      ]
    }

    if (is_chromeos_lacros) {
      sources -= [
        #  Needs crosapi for Lacros, so it's part of lacros_chrome_browsertests.
        "../browser/ui/webui/profile_helper_browsertest.cc",
      ]

      sources += [
        "../browser/apps/app_service/metrics/website_metrics_browsertest.cc",
        "../browser/apps/app_service/webapk/webapk_utils_lacros_browsertest.cc",
        "../browser/certificate_manager_model_lacros_browsertest.cc",
        "../browser/lacros/app_mode/kiosk_accelerator_browsertest.cc",
        "../browser/lacros/app_mode/kiosk_session_service_browsertest.cc",
        "../browser/lacros/lacros_apps_publisher_browsertest.cc",
        "../browser/lacros/lacros_extension_apps_controller_browsertest.cc",
        "../browser/lacros/lacros_extension_apps_publisher_browsertest.cc",
        "../browser/lacros/profile_loader_browsertest.cc",
        "../browser/lacros/profile_util_browsertest.cc",
        "../browser/policy/restricted_mgs_policy_provider_lacros_browsertest.cc",
        "../browser/web_applications/app_service/lacros_web_apps_controller_browsertest.cc",
      ]
      deps += [
        ":lacros_test_support_ui",
        "//chrome/browser/apps/browser_instance",
        "//chrome/browser/lacros/cros_apps:all_browser_tests",
        "//chromeos/crosapi/mojom",
        "//chromeos/lacros",
        "//chromeos/lacros:test_support",
        "//chromeos/startup",
        "//chromeos/ui/base",
        "//chromeos/ui/frame:test_support",
        "//components/account_manager_core:test_support",
        "//components/app_constants",
        "//components/services/app_service",
        "//components/webapk:proto",
        "//ui/wm:wm",
      ]
    }

    if (include_js_tests) {
      deps += [ "//chrome/test/data/webui:browser_tests" ]
    }
    if (is_chromeos_ash && include_js2gtest_tests) {
      deps += [
        "//ash/webui/color_internals:browser_tests_js",
        "//ash/webui/eche_app_ui:browser_tests_js",
        "//ash/webui/system_apps:browser_tests",
        "//chrome/test/data/webui/chromeos:browser_tests_js_mojo_lite_webui",
        "//chrome/test/data/webui/chromeos:browser_tests_js_mojo_webui",
        "//chrome/test/data/webui/chromeos:browser_tests_js_webui",
      ]

      data += js2gtest_js_libraries
      data_deps +=
          [ "//chrome/test/data/webui/chromeos:browser_tests_js_webui" ]

      if (!is_official_build) {
        deps += [ "//ash/webui/sample_system_web_app_ui:browser_tests_js" ]
      }
    }

    if (enable_captive_portal_detection) {
      sources +=
          [ "../browser/ssl/captive_portal_blocking_page_browsertest.cc" ]
    }

    if (is_chromeos_ash) {
      sources +=
          [ "../browser/lifetime/application_lifetime_chromeos_browsertest.cc" ]
      deps += [ "//chrome/browser/ui/ash/keyboard:ash_test_support" ]
    }

    if (!is_chromeos) {
      sources += [
        # chromeos does not support machine level user cloud policies
        "../browser/enterprise/reporting/report_scheduler_browsertest.cc",
        "../browser/external_protocol/external_protocol_policy_browsertest.cc",
        "../browser/lifetime/application_lifetime_browsertest.cc",
        "../browser/ui/views/enable_link_capturing_infobar_browsertest.cc",
      ]
      deps += [
        "//chrome/browser/apps/link_capturing",
        "//chrome/browser/shortcuts:browser_tests",
      ]
    }

    if (is_win || is_chromeos || is_mac) {
      sources += [ "../browser/webshare/share_service_browsertest.cc" ]
    }

    if (enable_plugins) {
      sources += [
        "../browser/plugins/plugin_info_host_impl_browsertest.cc",
        "../browser/plugins/plugin_response_interceptor_url_loader_throttle_browsertest.cc",
      ]
    }

    if (enable_ppapi) {
      sources += [
        "ppapi/ppapi_browsertest.cc",
        "ppapi/ppapi_filechooser_browsertest.cc",
      ]
      deps += [ "//ppapi/shared_impl:test_support" ]

      # TODO(thakis): Why do these need copying in browser_tests?
      # content_browsertests uses the non-copied files instead.
      data_deps += [
        "//ppapi:copy_test_files",
        "//ppapi:copy_test_files2",
        "//ppapi:ppapi_tests",
      ]
    }

    if (enable_dice_support) {
      sources += [
        "../browser/profiles/batch_upload/batch_upload_browsertest.cc",
        "../browser/signin/chrome_signin_client_browsertest.cc",
        "../browser/signin/dice_browsertest.cc",
        "../browser/signin/dice_web_signin_interceptor_browsertest.cc",
        "../browser/signin/signin_ui_util_browsertest.cc",
        "../browser/ui/autofill/autofill_signin_promo_tab_helper_browsertest.cc",
        "../browser/ui/profiles/signin_intercept_first_run_experience_dialog_browsertest.cc",
        "../browser/ui/signin/signin_view_controller_browsertest.cc",
        "../browser/ui/views/sync/inline_login_ui_browsertest.cc",
        "../browser/unified_consent/unified_consent_browsertest.cc",
        "../browser/unified_consent/unified_consent_sync_to_signin_browsertest.cc",
      ]
      if (is_win) {
        sources += [ "../browser/signin/signin_util_win_browsertest.cc" ]
      }
      if (is_win || is_linux) {
        sources +=
            [ "../browser/ui/views/profiles/first_run_intro_browsertest.cc" ]
      }
    } else {
      sources += [ "../browser/signin/mirror_browsertest.cc" ]
    }

    if (enable_bound_session_credentials) {
      sources += [ "../browser/signin/bound_session_credentials/bound_session_cookie_refresh_service_impl_browsertest.cc" ]
    }

    # TODO(crbug.com/40118868): Update guard when pixel tests support widens.
    if (is_win || is_linux || is_chromeos_lacros) {
      sources += [
        "../browser/ui/views/profiles/managed_user_profile_notice_ui_browsertest.cc",
        "../browser/ui/views/profiles/profile_menu_view_ui_browsertest.cc",
        "../browser/ui/views/profiles/profile_picker_ui_browsertest.cc",
        "../browser/ui/views/profiles/profile_type_choice_ui_browsertest.cc",
        "../browser/ui/views/profiles/sync_confirmation_ui_browsertest.cc",
      ]
    }

    if (is_win || is_linux) {
      sources += [ "../browser/ui/webui/search_engine_choice/search_engine_choice_ui_browsertest.cc" ]
    }

    if (enable_nacl) {
      sources += [
        "../browser/extensions/extension_nacl_browsertest.cc",
        "../browser/nacl_host/test/gdb_debug_stub_browsertest.cc",
        "nacl/nacl_browsertest.cc",
        "nacl/nacl_browsertest_uma.cc",
        "nacl/nacl_browsertest_util.cc",
        "nacl/nacl_browsertest_util.h",
        "nacl/pnacl_header_test.cc",
        "nacl/pnacl_header_test.h",
      ]
      deps += [
        "//components/nacl/browser",
        "//components/nacl/renderer",
        "//components/nacl/renderer/plugin:nacl_trusted_plugin",
      ]

      data_deps += [
        "//chrome/test/data/nacl",
        "//ppapi:ppapi_nacl_tests_all",
        "//ppapi/native_client:irt",
        "//ppapi/tests/extensions",
      ]
      if (is_chromeos) {
        sources += [
          "../browser/ui/views/extensions/document_scanner_discovery_confirmation_dialog_browsertest.cc",
          "../browser/ui/views/extensions/document_scanner_start_scan_confirmation_dialog_browsertest.cc",
        ]
      }
      if (is_chromeos_ash) {
        data += [ "//ash/webui/common/resources/cr.js" ]
        sources += [
          "../browser/ui/views/extensions/request_file_system_dialog_browsertest.cc",
          "//third_party/liblouis/wasm/liblouis_wrapper_browsertest.cc",
        ]
        data_deps += [
          "//components/nacl/loader:nacl_helper",
          "//ppapi/native_client:irt",
          "//third_party/liblouis:liblouis_test_data",
        ]
      }

      if (is_linux || is_chromeos) {
        sources += [ "../browser/nacl_host/test/nacl_gdb_browsertest.cc" ]
        data_deps += [ "//chrome/browser/nacl_host/test:mock_nacl_gdb" ]
      }
      if (is_linux || is_chromeos) {
        data_deps += [ "//components/nacl/loader:nacl_helper" ]
      }
    }

    if (enable_extensions) {
      sources += [
        "../../apps/app_restore_service_browsertest.cc",
        "../../apps/load_and_launch_browsertest.cc",
        "../browser/accessibility/embedded_a11y_extension_loader_browsertest.cc",
        "../browser/apps/guest_view/app_view_browsertest.cc",
        "../browser/apps/guest_view/web_view_browsertest.cc",
        "../browser/apps/platform_apps/api/browser/browser_apitest.cc",
        "../browser/apps/platform_apps/api/media_galleries/media_galleries_watch_apitest.cc",
        "../browser/apps/platform_apps/api/sync_file_system/sync_file_system_apitest.cc",
        "../browser/apps/platform_apps/api/sync_file_system/sync_file_system_browsertest.cc",
        "../browser/apps/platform_apps/app_browsertest.cc",
        "../browser/apps/platform_apps/app_speech_recognition_browsertest.cc",
        "../browser/apps/platform_apps/app_window_browsertest.cc",
        "../browser/apps/platform_apps/audio_focus_web_contents_observer_browsertest.cc",
        "../browser/apps/platform_apps/event_page_browsertest.cc",
        "../browser/apps/platform_apps/platform_app_navigation_redirector_browsertest.cc",
        "../browser/apps/platform_apps/service_worker_browsertest.cc",
        "../browser/controlled_frame/controlled_frame_apitest.cc",
        "../browser/controlled_frame/controlled_frame_dialog_browsertest.cc",
        "../browser/controlled_frame/controlled_frame_new_window_browsertest.cc",
        "../browser/controlled_frame/controlled_frame_permission_request_browsertest.cc",
        "../browser/controlled_frame/controlled_frame_wpt_browsertest.cc",
        "../browser/controlled_frame/scoped_test_driver_proxy.cc",
        "../browser/controlled_frame/scoped_test_driver_proxy.h",
        "../browser/extensions/alert_apitest.cc",
        "../browser/extensions/all_urls_apitest.cc",
        "../browser/extensions/api/activity_log_private/activity_log_private_apitest.cc",
        "../browser/extensions/api/alarms/alarms_apitest.cc",
        "../browser/extensions/api/autofill_private/autofill_private_api_unittest.cc",
        "../browser/extensions/api/autofill_private/autofill_private_apitest.cc",
        "../browser/extensions/api/autofill_private/autofill_util_unittest.cc",
        "../browser/extensions/api/bookmarks/bookmark_apitest.cc",
        "../browser/extensions/api/braille_display_private/braille_display_private_apitest.cc",
        "../browser/extensions/api/browsing_data/browsing_data_test.cc",
        "../browser/extensions/api/command_line_private/command_line_private_apitest.cc",
        "../browser/extensions/api/content_settings/content_settings_apitest.cc",
        "../browser/extensions/api/context_menus/context_menu_apitest.cc",
        "../browser/extensions/api/context_menus/extension_context_menu_browsertest.cc",
        "../browser/extensions/api/cookies/cookies_apitest.cc",
        "../browser/extensions/api/debugger/debugger_apitest.cc",
        "../browser/extensions/api/debugger/debugger_extension_apitest.cc",
        "../browser/extensions/api/declarative/declarative_apitest.cc",
        "../browser/extensions/api/declarative_content/declarative_content_apitest.cc",
        "../browser/extensions/api/declarative_content/request_content_script_apitest.cc",
        "../browser/extensions/api/declarative_content/set_icon_apitest.cc",
        "../browser/extensions/api/declarative_net_request/declarative_net_request_apitest.cc",
        "../browser/extensions/api/declarative_net_request/declarative_net_request_browsertest.cc",
        "../browser/extensions/api/desktop_capture/desktop_capture_apitest.cc",
        "../browser/extensions/api/developer_private/developer_private_apitest.cc",
        "../browser/extensions/api/downloads/downloads_api_browsertest.cc",
        "../browser/extensions/api/extension_action/browser_action_apitest.cc",
        "../browser/extensions/api/extension_action/browser_action_browsertest.cc",
        "../browser/extensions/api/extension_action/extension_action_apitest.cc",
        "../browser/extensions/api/extension_action/page_action_apitest.cc",
        "../browser/extensions/api/extension_action/page_action_browsertest.cc",
        "../browser/extensions/api/extension_action/test_extension_action_api_observer.cc",
        "../browser/extensions/api/extension_action/test_extension_action_api_observer.h",
        "../browser/extensions/api/extension_action/test_icon_image_observer.cc",
        "../browser/extensions/api/extension_action/test_icon_image_observer.h",
        "../browser/extensions/api/favicon/favicon_apitest.cc",
        "../browser/extensions/api/feedback_private/feedback_browsertest.cc",
        "../browser/extensions/api/file_system/file_system_apitest.cc",
        "../browser/extensions/api/font_settings/font_settings_apitest.cc",
        "../browser/extensions/api/gcm/gcm_apitest.cc",
        "../browser/extensions/api/history/history_apitest.cc",
        "../browser/extensions/api/i18n/i18n_apitest.cc",
        "../browser/extensions/api/identity/gaia_remote_consent_flow_browsertest.cc",
        "../browser/extensions/api/identity/identity_apitest.cc",
        "../browser/extensions/api/identity/web_auth_flow_browsertest.cc",
        "../browser/extensions/api/idle/idle_apitest.cc",
        "../browser/extensions/api/idltest/idltest_apitest.cc",
        "../browser/extensions/api/image_writer_private/extractor_browsertest.cc",
        "../browser/extensions/api/image_writer_private/test_utils.cc",
        "../browser/extensions/api/image_writer_private/test_utils.h",
        "../browser/extensions/api/instance_id/instance_id_apitest.cc",
        "../browser/extensions/api/management/management_api_browsertest.cc",
        "../browser/extensions/api/management/management_api_non_persistent_apitest.cc",
        "../browser/extensions/api/management/management_apitest.cc",
        "../browser/extensions/api/management/management_browsertest.cc",
        "../browser/extensions/api/messaging/messaging_apitest.cc",
        "../browser/extensions/api/messaging/native_messaging_apitest.cc",
        "../browser/extensions/api/messaging/service_worker_messaging_apitest.cc",
        "../browser/extensions/api/metrics_private/metrics_apitest.cc",
        "../browser/extensions/api/module/module_apitest.cc",
        "../browser/extensions/api/offscreen/audio_lifetime_enforcer_browsertest.cc",
        "../browser/extensions/api/offscreen/offscreen_apitest.cc",
        "../browser/extensions/api/offscreen/offscreen_document_manager_browsertest.cc",
        "../browser/extensions/api/page_capture/page_capture_apitest.cc",
        "../browser/extensions/api/passwords_private/passwords_private_apitest.cc",
        "../browser/extensions/api/permissions/permissions_apitest.cc",
        "../browser/extensions/api/preference/preference_apitest.cc",
        "../browser/extensions/api/printer_provider/printer_provider_apitest.cc",
        "../browser/extensions/api/processes/processes_apitest.cc",
        "../browser/extensions/api/reading_list/reading_list_apitest.cc",
        "../browser/extensions/api/resources_private/resources_private_apitest.cc",
        "../browser/extensions/api/runtime/runtime_apitest.cc",
        "../browser/extensions/api/scripting/scripting_apitest.cc",
        "../browser/extensions/api/search/search_api_apitest.cc",
        "../browser/extensions/api/sessions/sessions_apitest.cc",
        "../browser/extensions/api/settings_overrides/settings_overrides_browsertest.cc",
        "../browser/extensions/api/settings_private/settings_private_apitest.cc",
        "../browser/extensions/api/side_panel/side_panel_apitest.cc",
        "../browser/extensions/api/socket/socket_apitest.cc",
        "../browser/extensions/api/storage/settings_apitest.cc",
        "../browser/extensions/api/system_display/system_display_extension_apitest.cc",
        "../browser/extensions/api/system_private/system_private_apitest.cc",
        "../browser/extensions/api/tab_capture/tab_capture_apitest.cc",
        "../browser/extensions/api/tab_capture/tab_capture_performance_test_base.cc",
        "../browser/extensions/api/tab_capture/tab_capture_performance_test_base.h",
        "../browser/extensions/api/tab_capture/tab_capture_performancetest.cc",
        "../browser/extensions/api/tab_groups/tab_groups_api_apitest.cc",
        "../browser/extensions/api/tabs/execute_script_apitest.cc",
        "../browser/extensions/api/tabs/tabs_apitest.cc",
        "../browser/extensions/api/tabs/tabs_test.cc",
        "../browser/extensions/api/test/apitest_apitest.cc",
        "../browser/extensions/api/top_sites/top_sites_apitest.cc",
        "../browser/extensions/api/usb/chrome_usb_apitest.cc",
        "../browser/extensions/api/user_scripts/user_scripts_apitest.cc",
        "../browser/extensions/api/web_accessible_resources_apitest.cc",
        "../browser/extensions/api/web_navigation/web_navigation_apitest.cc",
        "../browser/extensions/api/web_request/web_request_apitest.cc",
        "../browser/extensions/api/webrtc_audio_private/webrtc_audio_private_browsertest.cc",
        "../browser/extensions/api/webrtc_from_web_accessible_resource_browsertest.cc",
        "../browser/extensions/api/webrtc_logging_private/webrtc_logging_private_apitest.cc",
        "../browser/extensions/api/webrtc_logging_private/webrtc_logging_private_browsertest.cc",
        "../browser/extensions/api/webstore_private/webstore_private_apitest.cc",
        "../browser/extensions/api_binding_perf_browsertest.cc",
        "../browser/extensions/app_background_page_apitest.cc",
        "../browser/extensions/app_process_apitest.cc",
        "../browser/extensions/app_window_overrides_browsertest.cc",
        "../browser/extensions/autoplay_browsertest.cc",
        "../browser/extensions/back_forward_cache_browsertest.cc",
        "../browser/extensions/background_color_provider_browsertest.cc",
        "../browser/extensions/background_header_browsertest.cc",
        "../browser/extensions/background_page_apitest.cc",
        "../browser/extensions/background_script_executor_browsertest.cc",
        "../browser/extensions/background_scripts_apitest.cc",
        "../browser/extensions/background_xhr_browsertest.cc",
        "../browser/extensions/cache_wasm_extension_browsertest.cc",
        "../browser/extensions/calculator_app_browsertest.cc",
        "../browser/extensions/chrome_app_api_browsertest.cc",
        "../browser/extensions/chrome_test_extension_loader_browsertest.cc",
        "../browser/extensions/chrome_theme_url_browsertest.cc",
        "../browser/extensions/commands/command_service_browsertest.cc",
        "../browser/extensions/content_capabilities_browsertest.cc",
        "../browser/extensions/content_script_apitest.cc",
        "../browser/extensions/content_security_policy_apitest.cc",
        "../browser/extensions/content_verifier_browsertest.cc",
        "../browser/extensions/content_verifier_hash_fetch_behavior_browsertest.cc",
        "../browser/extensions/content_verifier_test_utils.cc",
        "../browser/extensions/cross_origin_isolation_browsertest.cc",
        "../browser/extensions/cross_origin_xhr_apitest.cc",
        "../browser/extensions/crx_installer_browsertest.cc",
        "../browser/extensions/dynamic_origin_browsertest.cc",
        "../browser/extensions/error_console/error_console_browsertest.cc",
        "../browser/extensions/error_console/error_console_test_observer.cc",
        "../browser/extensions/error_console/error_console_test_observer.h",
        "../browser/extensions/event_metrics_browsertest.cc",
        "../browser/extensions/events_apitest.cc",
        "../browser/extensions/extension_action_runner_browsertest.cc",
        "../browser/extensions/extension_api_frame_id_map_browsertest.cc",
        "../browser/extensions/extension_bindings_apitest.cc",
        "../browser/extensions/extension_bookmarklet_browsertest.cc",
        "../browser/extensions/extension_browsertest_browsertest.cc",
        "../browser/extensions/extension_cookies_browsertest.cc",
        "../browser/extensions/extension_csp_bypass_browsertest.cc",
        "../browser/extensions/extension_disabled_ui_browsertest.cc",
        "../browser/extensions/extension_dom_apitest.cc",
        "../browser/extensions/extension_dom_clipboard_apitest.cc",
        "../browser/extensions/extension_fileapi_apitest.cc",
        "../browser/extensions/extension_function_registration_test.cc",
        "../browser/extensions/extension_functional_browsertest.cc",
        "../browser/extensions/extension_geolocation_apitest.cc",
        "../browser/extensions/extension_get_views_apitest.cc",
        "../browser/extensions/extension_icon_source_apitest.cc",
        "../browser/extensions/extension_incognito_apitest.cc",
        "../browser/extensions/extension_install_prompt_browsertest.cc",
        "../browser/extensions/extension_install_prompt_test_helper.cc",
        "../browser/extensions/extension_install_prompt_test_helper.h",
        "../browser/extensions/extension_install_ui_browsertest.cc",
        "../browser/extensions/extension_l10n_browsertest.cc",
        "../browser/extensions/extension_loading_browsertest.cc",
        "../browser/extensions/extension_modules_apitest.cc",
        "../browser/extensions/extension_override_apitest.cc",
        "../browser/extensions/extension_resource_request_policy_apitest.cc",
        "../browser/extensions/extension_security_exploit_browsertest.cc",
        "../browser/extensions/extension_shared_array_buffer_browsertest.cc",
        "../browser/extensions/extension_startup_browsertest.cc",
        "../browser/extensions/extension_tab_util_browsertest.cc",
        "../browser/extensions/extension_unload_browsertest.cc",
        "../browser/extensions/extension_untrusted_webui_apitest.cc",
        "../browser/extensions/extension_url_loader_throttle_browsertest.cc",
        "../browser/extensions/extension_url_rewrite_browsertest.cc",
        "../browser/extensions/extension_user_script_loader_browsertest.cc",
        "../browser/extensions/extension_view_host_factory_browsertest.cc",
        "../browser/extensions/extension_websocket_apitest.cc",
        "../browser/extensions/extension_webui_apitest.cc",
        "../browser/extensions/extension_with_management_policy_apitest.cc",
        "../browser/extensions/extension_with_management_policy_apitest.h",
        "../browser/extensions/extensions_disabled_browsertest.cc",
        "../browser/extensions/external_install_error_browsertest.cc",
        "../browser/extensions/feature_provider_browsertest.cc",
        "../browser/extensions/fetch_apitest.cc",
        "../browser/extensions/file_handlers/web_file_handlers_browsertest.cc",
        "../browser/extensions/file_iframe_apitest.cc",
        "../browser/extensions/google_docs_offline_ukm_browsertest.cc",
        "../browser/extensions/gpu_browsertest.cc",
        "../browser/extensions/isolated_world_csp_browsertest.cc",
        "../browser/extensions/lazy_background_page_apitest.cc",
        "../browser/extensions/loading_predictor_extension_browsertest.cc",
        "../browser/extensions/manifest_v2_experiment_manager_browsertest.cc",
        "../browser/extensions/manifest_v3_browsertest.cc",
        "../browser/extensions/mutation_observers_apitest.cc",
        "../browser/extensions/native_bindings_apitest.cc",
        "../browser/extensions/navigation_extension_enabler_browsertest.cc",
        "../browser/extensions/offscreen_document_browsertest.cc",
        "../browser/extensions/options_page_apitest.cc",
        "../browser/extensions/orb_and_cors_extension_browsertest.cc",
        "../browser/extensions/pack_extension_browsertest.cc",
        "../browser/extensions/permissions/active_tab_apitest.cc",
        "../browser/extensions/permissions/permissions_manager_browsertest.cc",
        "../browser/extensions/permissions/permissions_updater_browsertest.cc",
        "../browser/extensions/permissions/site_permissions_helper_browsertest.cc",
        "../browser/extensions/process_management_browsertest.cc",
        "../browser/extensions/process_manager_browsertest.cc",
        "../browser/extensions/process_map_browsertest.cc",
        "../browser/extensions/process_util_browsertest.cc",
        "../browser/extensions/protocol_handler_apitest.cc",
        "../browser/extensions/renderer_initialization_browsertest.cc",
        "../browser/extensions/sandboxed_pages_apitest.cc",
        "../browser/extensions/scoped_test_mv2_enabler_browsertest.cc",
        "../browser/extensions/script_executor_browsertest.cc",
        "../browser/extensions/script_injection_tracker_browsertest.cc",
        "../browser/extensions/service_worker_apitest.cc",
        "../browser/extensions/service_worker_apitest.h",
        "../browser/extensions/service_worker_event_dispatching_browsertest.cc",
        "../browser/extensions/service_worker_lifetime_keepalive_browsertest.cc",
        "../browser/extensions/service_worker_registration_apitest.cc",
        "../browser/extensions/service_worker_tracking_browsertest.cc",
        "../browser/extensions/shared_module_apitest.cc",
        "../browser/extensions/shared_worker_apitest.cc",
        "../browser/extensions/side_panel_manifest_browsertest.cc",
        "../browser/extensions/startup_helper_browsertest.cc",
        "../browser/extensions/stubs_apitest.cc",
        "../browser/extensions/subscribe_page_action_browsertest.cc",
        "../browser/extensions/system_cpu_apitest.cc",
        "../browser/extensions/system_memory_apitest.cc",
        "../browser/extensions/test_resources_browsertest.cc",
        "../browser/extensions/updater/extension_update_client_base_browsertest.cc",
        "../browser/extensions/updater/extension_update_client_base_browsertest.h",
        "../browser/extensions/updater/update_service_browsertest.cc",
        "../browser/extensions/user_host_restrictions_browsertest.cc",
        "../browser/extensions/user_script_listener_browsertest.cc",
        "../browser/extensions/user_script_world_browsertest.cc",
        "../browser/extensions/view_extension_source_browsertest.cc",
        "../browser/extensions/wasm_app_browsertest.cc",
        "../browser/extensions/wasm_mv3_browsertest.cc",
        "../browser/extensions/web_accessible_resources_browsertest.cc",
        "../browser/extensions/web_contents_browsertest.cc",
        "../browser/extensions/webstore_domain_browsertest.cc",
        "../browser/extensions/webstore_installer_browsertest.cc",
        "../browser/extensions/webstore_installer_test.cc",
        "../browser/extensions/webstore_installer_test.h",
        "../browser/extensions/webstore_reinstaller_browsertest.cc",
        "../browser/extensions/window_open_apitest.cc",
        "../browser/extensions/worker_apitest.cc",
        "../browser/notifications/notification_permission_context_apitest.cc",
        "../browser/preloading/prefetch/no_state_prefetch/no_state_prefetch_test_utils.cc",
        "../browser/preloading/prefetch/no_state_prefetch/no_state_prefetch_test_utils.h",
        "../browser/safe_browsing/extension_telemetry/extension_telemetry_service_browsertest.cc",
        "../browser/supervised_user/desktop/supervised_user_extension_browsertest.cc",
        "../browser/supervised_user/extensions_interactive_uitest.cc",
        "../browser/ui/views/autofill/popup/custom_cursor_suppressor_browsertest.cc",
        "../browser/ui/views/web_apps/create_shortcut_confirmation_view_browsertest.cc",
        "../browser/ui/views/web_apps/simple_install_dialog_bubble_view_browsertest.cc",
        "../browser/ui/views/web_apps/web_app_identity_update_confirmation_view_browsertest.cc",
        "../browser/user_bypass/user_bypass_web_contents_observer_browsertest.cc",
      ]

      if (is_win) {
        data_deps += [
          "//chrome/browser/extensions/api:native_messaging_test_echo_&_host",
          "//chrome/browser/extensions/api:native_messaging_test_echo_host",
          "//chrome/browser/extensions/api:native_messaging_test_echo_space_host",
        ]
      }

      if (is_chromeos_ash) {
        deps +=
            [ "//chromeos/ash/components/network/portal_detector:test_support" ]

        sources += [
          "../browser/extensions/api/identity/launch_web_auth_flow_delegate_ash_browsertest.cc",
          "../browser/ui/views/extensions/web_file_handlers/web_file_handlers_file_launch_browsertest.cc",
        ]
      }

      if (enable_background_mode) {
        sources += [ "../browser/extensions/background_app_browsertest.cc" ]
      }

      if (enable_pdf) {
        sources += [ "../browser/extensions/api/pdf_viewer_private/pdf_viewer_private_apitest.cc" ]
      }

      if (is_win || is_linux || is_mac) {
        sources += [
          "../browser/extensions/api/system_indicator/system_indicator_apitest.cc",
          "../browser/extensions/api/web_authentication_proxy/web_authentication_proxy_apitest.cc",
          "../browser/ui/views/web_apps/file_handler_launch_dialog_browsertest.cc",
          "../browser/ui/webui/app_home/app_home_page_handler_browsertest.cc",
          "../browser/ui/webui/app_home/mock_app_home_page.cc",
          "../browser/ui/webui/app_home/mock_app_home_page.h",
        ]
      }

      if (enterprise_cloud_content_analysis || is_android) {
        # Use this scope to migrate files/deps from
        # `enterprise_cloud_content_analysis` conditions that now need to compile
        # on Android.
        sources += [
          "../browser/enterprise/connectors/connectors_service_browsertest.cc",
        ]
      }

      if (enterprise_cloud_content_analysis) {
        sources += [
          "../browser/enterprise/connectors/analysis/content_analysis_dialog_browsertest.cc",
          "../browser/extensions/api/enterprise_reporting_private/enterprise_reporting_private_apitest.cc",
          "../browser/extensions/api/enterprise_reporting_private/enterprise_reporting_private_browsertest.cc",
        ]
        deps += [
          "//chrome/browser/enterprise/connectors/analysis:features",
          "//chrome/browser/enterprise/connectors/test:test_support",
          "//components/enterprise/buildflags",
          "//components/enterprise/connectors/core",
        ]
      }
      if (is_win || is_linux || is_mac || is_chromeos_ash) {
        sources += [ "../browser/enterprise/connectors/device_trust/device_trust_browsertest.cc" ]

        deps += [
          "//chrome/browser/enterprise/connectors/device_trust:features",
          "//chrome/browser/enterprise/connectors/device_trust/common",
          "//chrome/browser/enterprise/connectors/device_trust/test:test_support",
          "//components/device_signals/core/common",
          "//components/device_signals/core/common:features",
          "//components/device_signals/test:test_support",
          "//components/enterprise/connectors/core",
        ]
      }

      if (is_win || is_linux || is_mac) {
        deps += [
          "//chrome/browser/enterprise/connectors/device_trust/key_management/browser/commands:test_support",
          "//chrome/browser/enterprise/connectors/device_trust/key_management/core/persistence:test_support",
          "//chrome/browser/ui/webui/app_home:mojo_bindings",
          "//components/device_signals/core/browser",
        ]
      }

      if (!is_chromeos_lacros) {
        sources += [
          "../browser/extensions/api/automation/automation_apitest.cc",
          "../browser/extensions/api/image_writer_private/image_writer_private_apitest.cc",
          "../browser/extensions/api/proxy/proxy_apitest.cc",
        ]
      }

      if (is_chromeos) {
        sources += [
          "../browser/chromeos/extensions/info_private_browser_apitest.cc",
          "../browser/extensions/api/certificate_provider/certificate_provider_apitest.cc",
          "../browser/extensions/api/document_scan/document_scan_apitest.cc",
          "../browser/extensions/api/document_scan/fake_document_scan_ash.cc",
          "../browser/extensions/api/document_scan/fake_document_scan_ash.h",
          "../browser/extensions/clipboard_extension_apitest_chromeos.cc",
        ]

        deps += [
          "//chrome/browser/chromeos/extensions/smart_card_provider_private:browser_tests",
          "//chromeos/constants",
          "//chromeos/dbus/constants",
          "//chromeos/dbus/power",
          "//components/device_event_log:device_event_log",
        ]
      }

      if (is_chromeos_ash) {
        sources += [
          "../browser/apps/platform_apps/api/arc_apps_private/arc_apps_private_apitest.cc",
          "../browser/apps/platform_apps/api/enterprise_remote_apps/enterprise_remote_apps_apitest.cc",
          "../browser/chromeos/extensions/info_private_apitest.cc",
          "../browser/chromeos/extensions/login_screen/login/login_apitest.cc",
          "../browser/chromeos/extensions/login_screen/login_screen_i18n_apitest.cc",
          "../browser/chromeos/extensions/login_screen/login_screen_storage/login_screen_storage_apitest.cc",
          "../browser/chromeos/extensions/login_screen/storage_apitest.cc",
          "../browser/chromeos/extensions/wallpaper_apitest.cc",
          "../browser/chromeos/extensions/wm/wm_desks_private_apitest.cc",
          "../browser/extensions/api/bluetooth_low_energy/bluetooth_low_energy_apitest_chromeos.cc",
          "../browser/extensions/api/crash_report_private/crash_report_private_apitest.cc",
          "../browser/extensions/api/enterprise_device_attributes/enterprise_device_attributes_ash_apitest.cc",
          "../browser/extensions/api/enterprise_networking_attributes/enterprise_networking_attributes_ash_apitest.cc",
          "../browser/extensions/api/enterprise_platform_keys/enterprise_platform_keys_apitest_nss.cc",
          "../browser/extensions/api/file_system/file_system_apitest_chromeos.cc",
          "../browser/extensions/api/force_installed_affiliated_extension_apitest.cc",
          "../browser/extensions/api/force_installed_affiliated_extension_apitest.h",
          "../browser/extensions/api/input_ime/input_ime_apitest_chromeos.cc",
          "../browser/extensions/api/networking_private/networking_private_apitest.cc",
          "../browser/extensions/api/networking_private/networking_private_chromeos_apitest.cc",
          "../browser/extensions/api/platform_keys/platform_keys_apitest_nss.cc",
          "../browser/extensions/api/platform_keys/platform_keys_test_base.cc",
          "../browser/extensions/api/platform_keys/platform_keys_test_base.h",
          "../browser/extensions/api/settings_private/settings_private_browsertest_chromeos.cc",
          "../browser/extensions/api/shared_storage/shared_storage_private_apitest.cc",
          "../browser/extensions/api/system_display/system_display_chromeos_apitest.cc",
          "../browser/extensions/api/terminal/terminal_private_apitest.cc",
          "../browser/extensions/api/terminal/terminal_private_browsertest.cc",
          "../browser/extensions/api/video_capture/video_capture_apitest_chromeos.cc",
          "../browser/extensions/api/virtual_keyboard_private/virtual_keyboard_private_apitest.cc",
          "../browser/extensions/api/vpn_provider/vpn_provider_apitest.cc",
        ]

        deps += [
          "//build/config/chromebox_for_meetings:buildflags",
          "//chrome/browser/chromeos/extensions/telemetry/api:browser_tests",
          "//chrome/browser/chromeos/extensions/vpn_provider",
          "//chrome/browser/chromeos/extensions/wm",
          "//chrome/browser/error_reporting:test_support",
          "//chromeos/dbus/dlp:dlp",
          "//components/file_access:test_support",
        ]

        data += [
          "//media/test/data/90rotation.mp4",
          "//media/test/data/id3_png_test.mp3",
        ]
      }

      deps += [
        "../browser/enterprise/connectors/test:test_support",
        "//build:chromeos_buildflags",
        "//chrome/browser/controlled_frame:test_support",
        "//chrome/browser/devtools:test_support",
        "//chrome/browser/extensions:test_support",

        # TODO(357784804): Remove this explicit dependency on `//c/b/ui/zoom`
        # when tests that include chrome_zoom_level_prefs.h get modularized, eg
        # tabs_test.cc, app_browsertest.cc, host_zoom_map_browsertest.cc and ats_browsertest.cc.
        "//chrome/browser/ui/zoom",
        "//chrome/browser/web_applications/extensions",
        "//chrome/common/extensions/api",
        "//chrome/services/media_gallery_util/public/cpp:browser_tests",
        "//components/content_settings/core/test:test_support",
        "//components/guest_view/browser:test_support",
        "//components/history_clusters/history_clusters_internals/webui",
        "//components/history_clusters/history_clusters_internals/webui:constants",
        "//components/keep_alive_registry",
        "//components/media_router/browser:test_support",
        "//components/media_router/common:test_support",
        "//components/optimization_guide/optimization_guide_internals/webui",
        "//components/web_package",

        # TODO(rockot) bug 505926: The chrome_extensions_browsertests_sources
        # target should be deleted and this line removed. See the
        # chrome_extensions_browsertests_sources target for more.
        "//extensions:chrome_extensions_browsertests_sources",
        "//extensions/browser:test_support",
        "//extensions/browser/api/storage:settings_namespace",
        "//extensions/browser/updater",
        "//extensions/buildflags",
        "//extensions/common:mojom",
        "//extensions/common/api",
        "//extensions/renderer",
        "//google_apis/common:test_support",
        "//google_apis/drive",
        "//ui/actions:actions_headers",
        "//ui/base/idle:test_support",
        "//ui/views:test_support",
      ]

      data += [
        "//chrome/test/data/extensions/",
        "//extensions/test/data/",
        "//third_party/blink/web_tests/external/wpt/resources/testharness.js",
        "//third_party/blink/web_tests/external/wpt/resources/testdriver.js",
        "//third_party/blink/web_tests/http/tests/wasm/resources/large.wasm",
      ]

      if (enable_plugins) {
        # The following tests include PPAPI headers.
        sources += [
          "../browser/apps/platform_apps/api/media_galleries/media_galleries_apitest.cc",
          "../browser/chrome_service_worker_browsertest.cc",
          "../browser/content_settings/content_settings_browsertest.cc",
        ]
      }

      if (!is_chromeos_lacros) {
        data_deps += [ "//chrome/browser/resources/accessibility:reading_mode_gdocs_extension_resources" ]
      }
    }

    if (use_aura) {
      deps += [
        "//chrome/browser/ui/aura/accessibility",
        "//components/eye_dropper",
      ]

      if (use_nss_certs) {
        sources += [ "../browser/ui/views/crypto_module_password_dialog_view_browsertest.cc" ]
      }
    }
    if (use_aura || toolkit_views) {
      deps += [ "//ui/events:test_support" ]
    }
    if (toolkit_views) {
      sources += [
        "../browser/ui/commerce/mock_commerce_ui_tab_helper.cc",
        "../browser/ui/commerce/mock_commerce_ui_tab_helper.h",
        "../browser/ui/commerce/product_specifications_entry_point_controller_browsertest.cc",
        "../browser/ui/file_system_access/file_system_access_dangerous_file_dialog_browsertest.cc",
        "../browser/ui/file_system_access/file_system_access_permission_dialog_browsertest.cc",
        "../browser/ui/file_system_access/file_system_access_restricted_directory_dialog_browsertest.cc",
        "../browser/ui/global_error/global_error_browsertest.cc",
        "../browser/ui/global_error/global_error_service_browsertest.cc",
        "../browser/ui/media_router/presentation_receiver_window_controller_browsertest.cc",
        "../browser/ui/views/autofill/payments/autofill_error_dialog_view_native_views_browsertest.cc",
        "../browser/ui/views/autofill/payments/autofill_progress_dialog_views_browsertest.cc",
        "../browser/ui/views/autofill/payments/card_unmask_authentication_selection_dialog_browsertest.cc",
        "../browser/ui/views/autofill/payments/card_unmask_otp_input_dialog_browsertest.cc",
        "../browser/ui/views/autofill/payments/credit_card_access_manager_browsertest.cc",
        "../browser/ui/views/autofill/payments/offer_notification_bubble_views_browsertest.cc",
        "../browser/ui/views/autofill/payments/payments_window_user_consent_dialog_browsertest.cc",
        "../browser/ui/views/autofill/payments/save_card_bubble_views_browsertest.cc",
        "../browser/ui/views/autofill/payments/webauthn_dialog_browsertest.cc",
        "../browser/ui/views/autofill/popup/mock_accessibility_selection_delegate.cc",
        "../browser/ui/views/autofill/popup/mock_accessibility_selection_delegate.h",
        "../browser/ui/views/autofill/popup/mock_selection_delegate.cc",
        "../browser/ui/views/autofill/popup/mock_selection_delegate.h",
        "../browser/ui/views/autofill/popup/popup_base_view_browsertest.cc",
        "../browser/ui/views/autofill/popup/popup_pixel_test.h",
        "../browser/ui/views/autofill/popup/popup_row_factory_utils_browsertest.cc",
        "../browser/ui/views/autofill/popup/popup_view_views_browsertest.cc",
        "../browser/ui/views/bookmarks/bookmark_bubble_view_browsertest.cc",
        "../browser/ui/views/bookmarks/bookmark_editor_view_browsertest.cc",
        "../browser/ui/views/bookmarks/saved_tab_groups/saved_tab_group_iph_promo_test.cc",
        "../browser/ui/views/bubble/bubble_frame_view_browsertest.cc",
        "../browser/ui/views/bubble/webui_bubble_manager_browsertest.cc",
        "../browser/ui/views/certificate_selector_dialog_browsertest.cc",
        "../browser/ui/views/commerce/discounts_icon_view_browsertest.cc",
        "../browser/ui/views/commerce/ntp_discount_consent_dialog_view_browsertest.cc",
        "../browser/ui/views/commerce/price_insights_icon_view_browsertest.cc",
        "../browser/ui/views/commerce/price_tracking_icon_view_browsertest.cc",
        "../browser/ui/views/commerce/product_specifications_button_browsertest.cc",
        "../browser/ui/views/commerce/product_specifications_icon_view_browsertest.cc",
        "../browser/ui/views/desktop_capture/desktop_media_picker_views_browsertest.cc",
        "../browser/ui/views/extensions/device_chooser_extension_browsertest.cc",
        "../browser/ui/views/extensions/extension_install_blocked_dialog_view_browsertest.cc",
        "../browser/ui/views/extensions/extension_install_dialog_view_browsertest.cc",
        "../browser/ui/views/extensions/extension_install_friction_dialog_view_browsertest.cc",
        "../browser/ui/views/extensions/extension_installed_bubble_view_browsertest.cc",
        "../browser/ui/views/extensions/extension_multiple_uninstall_dialog_browsertest.cc",
        "../browser/ui/views/extensions/extension_uninstall_dialog_view_browsertest.cc",
        "../browser/ui/views/extensions/extensions_dialogs_browsertest.cc",
        "../browser/ui/views/extensions/extensions_dialogs_browsertest.h",
        "../browser/ui/views/extensions/extensions_request_access_hover_card_coordinator_browsertest.cc",
        "../browser/ui/views/extensions/media_galleries_dialog_views_browsertest.cc",
        "../browser/ui/views/extensions/mv2_deprecation_disabled_dialog_browsertest.cc",
        "../browser/ui/views/extensions/mv2_deprecation_keep_dialog_browsertest.cc",
        "../browser/ui/views/extensions/mv2_deprecation_reenable_dialog_browsertest.cc",
        "../browser/ui/views/extensions/reload_page_dialog_browsertest.cc",
        "../browser/ui/views/extensions/security_dialog_tracker_browsertest.cc",
        "../browser/ui/views/extensions/settings_overridden_dialog_browsertest.cc",
        "../browser/ui/views/external_protocol_dialog_browsertest.cc",
        "../browser/ui/views/file_system_access/file_system_access_browsertest.cc",
        "../browser/ui/views/file_system_access/file_system_access_usage_bubble_view_browsertest.cc",
        "../browser/ui/views/folder_upload_confirmation_view_browsertest.cc",
        "../browser/ui/views/frame/browser_frame_browsertest.cc",
        "../browser/ui/views/frame/browser_non_client_frame_view_browsertest.cc",
        "../browser/ui/views/frame/browser_root_view_browsertest.cc",
        "../browser/ui/views/frame/browser_view_browsertest.cc",
        "../browser/ui/views/hung_renderer_view_browsertest.cc",
        "../browser/ui/views/importer/import_lock_dialog_view_browsertest.cc",
        "../browser/ui/views/javascript_tab_modal_dialog_view_views_browsertest.cc",
        "../browser/ui/views/location_bar/content_setting_bubble_dialog_browsertest.cc",
        "../browser/ui/views/location_bar/cookie_controls/cookie_controls_bubble_view_browsertest.cc",
        "../browser/ui/views/location_bar/custom_tab_bar_view_browsertest.cc",
        "../browser/ui/views/location_bar/location_bar_view_browsertest.cc",
        "../browser/ui/views/location_bar/location_icon_view_browsertest.cc",
        "../browser/ui/views/location_bar/zoom_bubble_view_browsertest.cc",
        "../browser/ui/views/media_router/cast_dialog_view_browsertest.cc",
        "../browser/ui/views/media_router/media_router_ui_browsertest.cc",
        "../browser/ui/views/media_router/presentation_receiver_window_view_browsertest.cc",
        "../browser/ui/views/omnibox/omnibox_popup_view_views_browsertest.cc",
        "../browser/ui/views/omnibox/omnibox_suggestion_button_row_browsertest.cc",
        "../browser/ui/views/page_action/pwa_install_view_browsertest.cc",
        "../browser/ui/views/page_action/zoom_view_browsertest.cc",
        "../browser/ui/views/page_info/about_this_site_side_panel_coordinator_browsertest.cc",
        "../browser/ui/views/page_info/page_info_bubble_view_browsertest.cc",
        "../browser/ui/views/page_info/page_info_bubble_view_dialog_browsertest.cc",
        "../browser/ui/views/page_info/page_info_bubble_view_sync_browsertest.cc",
        "../browser/ui/views/page_info/safety_tip_page_info_bubble_view_browsertest.cc",
        "../browser/ui/views/passwords/password_bubble_browsertest.cc",
        "../browser/ui/views/passwords/password_cross_domain_confirmation_popup_view_views_browsertest.cc",
        "../browser/ui/views/passwords/password_dialog_view_browsertest.cc",
        "../browser/ui/views/passwords/password_generation_popup_view_tester_views.cc",
        "../browser/ui/views/passwords/password_generation_popup_view_tester_views.h",
        "../browser/ui/views/passwords/password_generation_popup_view_views_browsertest.cc",
        "../browser/ui/views/payments/contact_info_editor_view_controller_browsertest.cc",
        "../browser/ui/views/payments/credit_card_editor_view_controller_browsertest.cc",
        "../browser/ui/views/payments/empty_update_browsertest.cc",
        "../browser/ui/views/payments/error_message_view_controller_browsertest.cc",
        "../browser/ui/views/payments/modifiers_browsertest.cc",
        "../browser/ui/views/payments/order_summary_view_controller_browsertest.cc",
        "../browser/ui/views/payments/payment_handler_icon_refetch_browsertest.cc",
        "../browser/ui/views/payments/payment_handler_web_flow_view_browsertest.cc",
        "../browser/ui/views/payments/payment_handler_window_size_browsertest.cc",
        "../browser/ui/views/payments/payment_method_view_controller_browsertest.cc",
        "../browser/ui/views/payments/payment_request_blob_url_browsertest.cc",
        "../browser/ui/views/payments/payment_request_browsertest.cc",
        "../browser/ui/views/payments/payment_request_browsertest_base.cc",
        "../browser/ui/views/payments/payment_request_browsertest_base.h",
        "../browser/ui/views/payments/payment_request_can_make_payment_metrics_browsertest.cc",
        "../browser/ui/views/payments/payment_request_completion_status_metrics_browsertest.cc",
        "../browser/ui/views/payments/payment_request_data_url_browsertest.cc",
        "../browser/ui/views/payments/payment_request_journey_logger_browsertest.cc",
        "../browser/ui/views/payments/payment_request_no_update_with_browsertest.cc",
        "../browser/ui/views/payments/payment_request_payment_app_browsertest.cc",
        "../browser/ui/views/payments/payment_request_payment_response_browsertest.cc",
        "../browser/ui/views/payments/payment_request_retry_browsertest.cc",
        "../browser/ui/views/payments/payment_request_sheet_controller_browsertest.cc",
        "../browser/ui/views/payments/payment_request_shipping_address_instance_browsertest.cc",
        "../browser/ui/views/payments/payment_request_show_promise_browsertest.cc",
        "../browser/ui/views/payments/payment_request_update_with_browsertest.cc",
        "../browser/ui/views/payments/payment_request_use_stats_browsertest.cc",
        "../browser/ui/views/payments/payment_sheet_view_controller_browsertest.cc",
        "../browser/ui/views/payments/profile_list_view_controller_browsertest.cc",
        "../browser/ui/views/payments/secure_payment_confirmation_dialog_view_browsertest.cc",
        "../browser/ui/views/payments/secure_payment_confirmation_no_creds_dialog_view_browsertest.cc",
        "../browser/ui/views/payments/shipping_address_editor_view_controller_browsertest.cc",
        "../browser/ui/views/payments/shipping_option_view_controller_browsertest.cc",
        "../browser/ui/views/performance_controls/memory_saver_chip_view_browsertest.cc",
        "../browser/ui/views/performance_controls/memory_saver_exclusion_list_browsertest.cc",
        "../browser/ui/views/permissions/embedded_permission_prompt_uitest.cc",
        "../browser/ui/views/permissions/exclusive_access_permission_prompt_browsertest.cc",
        "../browser/ui/views/permissions/permission_prompt_bubble_base_view_browsertest.cc",
        "../browser/ui/views/permissions/permission_request_chip_browsertest.cc",
        "../browser/ui/views/profiles/profile_menu_view_browsertest.cc",
        "../browser/ui/views/safe_browsing/deep_scanning_failure_modal_dialog_browsertest.cc",
        "../browser/ui/views/safe_browsing/password_reuse_modal_warning_dialog_browsertest.cc",
        "../browser/ui/views/safe_browsing/prompt_for_scanning_modal_dialog_browsertest.cc",
        "../browser/ui/views/safe_browsing/tailored_security_desktop_dialog_manager_browsertest.cc",
        "../browser/ui/views/send_tab_to_self/send_tab_to_self_bubble_browsertest.cc",
        "../browser/ui/views/session_crashed_bubble_view_browsertest.cc",
        "../browser/ui/views/side_panel/extensions/extension_side_panel_browsertest.cc",
        "../browser/ui/views/side_panel/extensions/extension_side_panel_test_utils.cc",
        "../browser/ui/views/side_search/default_search_icon_source_browsertest.cc",
        "../browser/ui/views/site_data/page_specific_site_data_dialog_browsertest.cc",
        "../browser/ui/views/status_bubble_views_browsertest.cc",
        "../browser/ui/views/tab_sharing/tab_sharing_ui_views_browsertest.cc",
        "../browser/ui/views/tabs/tab_group_editor_bubble_view_browsertest.cc",
        "../browser/ui/views/translate/translate_bubble_test_utils_views.cc",
        "../browser/ui/views/translate/translate_bubble_view_browsertest.cc",
        "../browser/ui/views/upgrade_notification_controller_browsertest.cc",
        "../browser/ui/views/user_education/help_bubble_factory_views_browsertest.cc",
        "../browser/ui/views/web_apps/web_app_uninstall_dialog_browsertest.cc",
      ]
      if (is_win) {
        sources += [
          "../browser/ui/views/frame/browser_frame_view_browsertest_win.cc",
        ]
      }
      if (is_mac) {
        sources += [
          "../browser/ui/views/javascript_tab_modal_dialog_view_views_browsertest_mac.mm",
          "../browser/ui/views/status_bubble_views_browsertest_mac.h",
          "../browser/ui/views/status_bubble_views_browsertest_mac.mm",
        ]
      } else {
        # TaskManagerView is not used or built on Mac.
        sources += [ "../browser/ui/views/task_manager_view_browsertest.cc" ]
      }
      if (is_win || is_mac || is_linux) {
        sources += [
          "../browser/ui/views/web_apps/deprecated_apps_dialog_view_browsertest.cc",
          "../browser/ui/views/web_apps/force_installed_deprecated_apps_dialog_view_browsertest.cc",
        ]
      }
      if (is_chromeos_ash) {
        sources += [
          "../browser/ui/views/frame/system_web_app_non_client_frame_view_browsertest.cc",
          "../browser/ui/views/select_file_dialog_extension_browsertest.cc",
        ]
        deps += [ "//chromeos/ash/services/multidevice_setup/public/cpp:prefs" ]
      } else {
        sources += [ "../browser/ui/views/profiles/profile_customization_bubble_view_browsertest.cc" ]
      }
      if (!is_chromeos) {
        sources += [
          "../browser/ui/signin/chrome_signout_confirmation_prompt_browsertest.cc",
          "../browser/ui/signin/cookie_clear_on_exit_migration_notice_browsertest.cc",
          "../browser/ui/views/bookmarks/bookmark_bubble_sign_in_delegate_browsertest.cc",
          "../browser/ui/views/frame/opaque_browser_frame_view_browsertest.cc",
          "../browser/ui/views/performance_controls/battery_saver_button_browsertest.cc",
          "../browser/ui/views/policy/enterprise_startup_dialog_view_browsertest.cc",
          "../browser/ui/views/profiles/batch_upload_dialog_view_pixel_browsertest.cc",
          "../browser/ui/views/profiles/dice_web_signin_interception_bubble_view_browsertest.cc",
          "../browser/ui/views/profiles/dice_web_signin_interception_bubble_view_pixel_browsertest.cc",
          "../browser/ui/views/relaunch_notification/relaunch_recommended_bubble_view_browsertest.cc",
          "../browser/ui/views/relaunch_notification/relaunch_required_dialog_view_browsertest.cc",
        ]

        deps += [ "//chrome/browser/ui/views/shortcuts:browser_tests" ]
      }
      deps += [
        ":test_support_ui",
        "//chrome/browser/lens/core/mojom:mojo_bindings",
        "//chrome/browser/ui/actions:actions",
        "//chrome/browser/ui/actions:actions_headers",
        "//chrome/browser/ui/find_bar",
        "//chrome/browser/ui/lens",
        "//chrome/browser/ui/lens:browser_tests",
        "//chrome/browser/ui/toasts:browser_tests",
        "//chrome/browser/ui/zoom:browser_tests",
        "//components/commerce/core:account_checker_test_support",
        "//components/commerce/core:shopping_service_test_support",
        "//components/commerce/core:utils",
        "//components/page_info/core:proto",
        "//components/safe_browsing/core/browser/realtime:test_support",
        "//components/send_tab_to_self",
        "//components/send_tab_to_self:test_support",
        "//components/user_education/views",
        "//ui/base/dragdrop:types",
        "//ui/views",
        "//url",
      ]
      allow_circular_includes_from +=
          [ "//chrome/browser/ui/lens:browser_tests" ]
      if (use_aura) {
        deps += [ "//ui/aura:test_support" ]
      }
    }

    if ((!is_android || enable_vr) && !is_ios) {
      sources += [ "../browser/ui/views/payments/payment_handler_header_view_ui_browsertest.cc" ]
      deps += [ "//components/payments/content/icon" ]
    }

    if ((is_linux || is_chromeos) && !is_component_build) {
      # Set rpath to find the CDM adapter even in a non-component build.
      configs += [ "//build/config/gcc:rpath_for_built_shared_libraries" ]
    }

    if (is_chrome_branded) {
      # Test data used by the end-to-end LiveSignInTest.
      data +=
          [ "//chrome/browser/internal/resources/signin/test_accounts.json" ]
    }

    # NOTE: This is the main "browser_tests" section for |is_chromeos_ash|.
    if (is_chromeos_ash) {
      sources += [
        "../browser/apps/app_service/media_access_browsertest.cc",
        "../browser/apps/app_service/metrics/app_platform_metrics_browsertest.cc",
        "../browser/apps/app_service/metrics/website_metrics_browsertest.cc",
        "../browser/apps/app_service/notifications_browsertest.cc",
        "../browser/apps/app_service/publishers/extension_apps_chromeos_browsertest.cc",
        "../browser/apps/app_service/publishers/web_apps_crosapi_browsertest.cc",
        "../browser/apps/app_service/webapk/webapk_policy_browsertest.cc",
        "../browser/apps/platform_apps/app_window_interactive_uitest_base.cc",
        "../browser/apps/platform_apps/app_window_interactive_uitest_base.h",
        "../browser/chromeos/video_conference/video_conference_manager_client_browsertest.cc",
        "../browser/device_api/device_attribute_api_browsertest.cc",
        "../browser/drive/drive_notification_manager_factory_browsertest.cc",
        "../browser/enterprise/connectors/device_trust/signals/decorators/ash/ash_signals_decorator_browsertest.cc",
        "../browser/extensions/extension_keeplist_ash_browsertest.cc",
        "../browser/feedback/show_feedback_page_browsertest.cc",
        "../browser/file_system_access/cloud_identifier/cloud_identifier_util_ash_browsertest.cc",
        "../browser/metrics/chromeos_family_link_user_metrics_provider_browsertest.cc",
        "../browser/metrics/chromeos_metrics_provider_browsertest.cc",
        "../browser/metrics/family_user_metrics_provider_browsertest.cc",
        "../browser/metrics/majority_age_user_metrics_provider_browsertest.cc",
        "../browser/metrics/per_user_state_manager_chromeos_browsertest.cc",
        "../browser/metrics/structured/ash_structured_metrics_delegate_browsertest.cc",
        "../browser/metrics/structured/metadata_processor_ash_browsertest.cc",
        "../browser/metrics/structured/structured_metrics_key_events_observer_browsertest.cc",
        "../browser/metrics/usertype_by_devicetype_metrics_provider_browsertest.cc",
        "../browser/notifications/chrome_ash_message_center_client_browsertest.cc",
        "../browser/notifications/notification_platform_bridge_chromeos_browsertest.cc",
        "../browser/notifications/notifier_settings_test_observer.cc",
        "../browser/notifications/notifier_settings_test_observer.h",
        "../browser/page_load_metrics/observers/ash_session_restore_page_load_metrics_observer_browsertest.cc",
        "../browser/policy/login_policy_test_base_browsertest.cc",
        "../browser/policy/restricted_mgs_policy_provider_ash_browsertest.cc",
        "../browser/process_singleton_browsertest.cc",
        "../browser/sessions/session_restore_browsertest_chromeos.cc",
        "../browser/signin/chromeos_mirror_account_consistency_browsertest.cc",
        "../browser/speech/extension_api/tts_extension_api_ash_browsertest.cc",
        "../browser/speech/network_speech_recognizer_browsertest.cc",
        "../browser/speech/speech_recognition_recognizer_client_impl_browsertest.cc",
        "../browser/support_tool/ash/ui_hierarchy_data_collector_browsertest.cc",
        "../browser/ui/browser_finder_chromeos_browsertest.cc",
        "../browser/ui/browser_navigator_browsertest_chromeos.cc",
        "../browser/ui/browser_tabstrip_browsertest_chromeos.cc",
        "../browser/ui/extensions/application_launch_browsertest.cc",
        "../browser/ui/quick_answers/quick_answers_browsertest.cc",
        "../browser/ui/quick_answers/quick_answers_browsertest_base.cc",
        "../browser/ui/quick_answers/quick_answers_browsertest_base.h",
        "../browser/ui/quick_answers/quick_answers_controller_browsertest.cc",
        "../browser/ui/settings_window_manager_browsertest_chromeos.cc",
        "../browser/ui/views/apps/app_dialog/app_dialog_view_browsertest.cc",
        "../browser/ui/views/apps/app_dialog/app_uninstall_dialog_view_browsertest.cc",
        "../browser/ui/views/apps/chrome_native_app_window_views_aura_ash_browsertest.cc",
        "../browser/ui/views/arc_app_dialog_view_browsertest.cc",
        "../browser/ui/views/editor_menu/editor_menu_browsertest.cc",
        "../browser/ui/views/extensions/extension_dialog_bounds_browsertest.cc",
        "../browser/ui/views/frame/browser_frame_ash_browsertest.cc",
        "../browser/ui/views/frame/browser_non_client_frame_view_chromeos_browsertest.cc",
        "../browser/ui/views/frame/immersive_mode_browser_view_test.cc",
        "../browser/ui/views/frame/immersive_mode_controller_chromeos_browsertest.cc",
        "../browser/ui/views/frame/system_menu_model_builder_browsertest_chromeos.cc",
        "../browser/ui/views/frame/top_controls_slide_controller_chromeos_browsertest.cc",
        "../browser/ui/views/intent_picker_bubble_view_browsertest_chromeos.cc",
        "../browser/ui/views/plugin_vm/plugin_vm_installer_view_browsertest.cc",
        "../browser/ui/views/tabs/tab_scrubber_chromeos_browsertest.cc",
        "../browser/ui/views/web_apps/web_app_ash_interactive_ui_test.cc",
        "../browser/ui/webui/nearby_share/nearby_share_dialog_ui_browsertest.cc",
        "../browser/ui/webui/signin/ash/inline_login_dialog_browsertest.cc",
        "../browser/ui/webui/signin/ash/inline_login_handler_impl_browsertest.cc",
        "../browser/ui/webui/signin/ash/signin_helper_browsertest.cc",
        "../browser/ui/window_sizer/window_sizer_chromeos_uitest.cc",
        "../browser/web_applications/app_service/web_app_publisher_helper_browsertest.cc",
        "../browser/web_applications/app_service/web_apps_browsertest.cc",
        "../browser/web_applications/app_service/web_apps_chromeos_browsertest.cc",
        "../browser/webshare/chromeos/sharesheet_client_browsertest.cc",
        "//ash/webui/boca_ui/provider/tab_info_collector_browsertest.cc",
        "base/chromeos/demo_ash_requires_lacros_browsertest.cc",
      ]
      data += [
        # TODO(GYP): figure out which of these things are
        # actually needed and also which should be pulled in via
        # data or data_deps and through which dependencies.
        "//chromeos/test/data/",
        "//ui/file_manager/integration_tests/testing_provider/",
        "$root_out_dir/chromevox_test_data/",
        "$root_out_dir/content_shell.pak",
        "$root_out_dir/resources/chromeos/",
        "../browser/resources/chromeos/accessibility/switch_access/test_support.js",

        # For projectorscreencast manager browser tests:
        "//media/test/data/bear-audio-mp4a.69.ts",
        "//media/test/data/tulip2.webm",
      ]
      data_deps += [
        "//ash/keyboard/ui:resources",
        "//chrome",
        "//testing/buildbot/filters:chromeos_filters",
        "//ui/file_manager/integration_tests:build",
      ]
      if (use_dbus) {
        deps += [ "//dbus:test_support" ]
      }
      if (use_cups) {
        sources += [
          "../browser/chromeos/extensions/printing_metrics/printing_metrics_apitest.cc",
          "../browser/extensions/api/printing/printing_apitest.cc",
          "../browser/printing/web_api/web_printing_browsertest.cc",
        ]
        deps += [
          "//chrome/browser/chromeos/extensions/printing_metrics",
          "//chromeos/printing",
          "//printing:test_support",
        ]
      }

      sources -= [
        "../../apps/load_and_launch_browsertest.cc",

        # chromeos does not support profile list avatar menu
        "../browser/profiles/profile_list_desktop_browsertest.cc",
        "../browser/ui/views/external_protocol_dialog_browsertest.cc",

        # chromeos does not use the profile chooser view
        "../browser/ui/views/profiles/profile_menu_view_browsertest.cc",
        "../browser/ui/webui/profile_helper_browsertest.cc",
      ]

      deps += [
        ":test_support_ui",
        "//ash:test_support",
        "//ash/app_list",
        "//ash/app_list:test_support",
        "//ash/app_list/model:app_list_model",
        "//ash/components/arc:arc_base",
        "//ash/components/arc:arc_metrics_constants",
        "//ash/components/arc:arc_test_support",
        "//ash/components/arc:prefs",
        "//ash/components/arc/session:arc_base_enums",
        "//ash/constants:constants",
        "//ash/keyboard/ui:test_support",
        "//ash/public/cpp/external_arc",
        "//ash/public/cpp/holding_space:test_support",
        "//ash/style:style",
        "//ash/webui/annotator",
        "//ash/webui/annotator:test_support",
        "//ash/webui/boca_ui",
        "//ash/webui/boca_ui/mojom",
        "//ash/webui/common:trusted_types_util",
        "//ash/webui/demo_mode_app_ui",
        "//ash/webui/diagnostics_ui",
        "//ash/webui/eche_app_ui",
        "//ash/webui/file_manager:constants",
        "//ash/webui/file_manager:file_manager_ui",
        "//ash/webui/file_manager/resources:file_manager_swa_resources_grit",
        "//ash/webui/firmware_update_ui",
        "//ash/webui/help_app_ui",
        "//ash/webui/help_app_ui:browser_test_support",
        "//ash/webui/help_app_ui:buildflags",
        "//ash/webui/help_app_ui/search:mojo_bindings",
        "//ash/webui/media_app_ui",
        "//ash/webui/media_app_ui:browser_test_support",
        "//ash/webui/media_app_ui:buildflags",
        "//ash/webui/media_app_ui:mojo_bindings_untrusted",
        "//ash/webui/os_feedback_ui:os_feedback_ui",
        "//ash/webui/personalization_app",
        "//ash/webui/print_management",
        "//ash/webui/print_management/backend:backend",
        "//ash/webui/projector_app",
        "//ash/webui/projector_app:buildflags",
        "//ash/webui/projector_app:test_support",
        "//ash/webui/scanning",
        "//ash/webui/settings/public/constants:mojom",
        "//ash/webui/shimless_rma",
        "//ash/webui/shortcut_customization_ui",
        "//ash/webui/shortcut_customization_ui/backend",
        "//ash/webui/shortcut_customization_ui/backend/search:mojo_bindings",
        "//ash/webui/web_applications/test:test_support",
        "//chrome/browser/apps/almanac_api_client:browser_tests",
        "//chrome/browser/apps/app_discovery_service/recommended_arc_apps",
        "//chrome/browser/apps/app_discovery_service/recommended_arc_apps:test_support",
        "//chrome/browser/apps/app_preload_service:browser_tests",
        "//chrome/browser/apps/app_service/app_install:browser_tests",
        "//chrome/browser/apps/app_service/app_install:browser_tests",
        "//chrome/browser/apps/browser_instance",
        "//chrome/browser/apps/browser_instance:browser_tests",
        "//chrome/browser/apps/link_capturing",
        "//chrome/browser/ash:browser_tests",
        "//chrome/browser/ash/app_list/search/test:browser_test_support",
        "//chrome/browser/ash/app_mode/web_app",
        "//chrome/browser/ash/app_restore",
        "//chrome/browser/ash/app_restore:browser_tests",
        "//chrome/browser/ash/app_restore:test_support",
        "//chrome/browser/ash/apps:browser_tests",
        "//chrome/browser/ash/arc",
        "//chrome/browser/ash/arc/boot_phase_monitor",
        "//chrome/browser/ash/arc/session",
        "//chrome/browser/ash/arc/test:arc_test_support",
        "//chrome/browser/ash/attestation",
        "//chrome/browser/ash/attestation:test_support",
        "//chrome/browser/ash/bluetooth",
        "//chrome/browser/ash/borealis:test_support",
        "//chrome/browser/ash/borealis/testing:test_support",
        "//chrome/browser/ash/bruschetta",
        "//chrome/browser/ash/crosapi",
        "//chrome/browser/ash/crosapi:test_support",
        "//chrome/browser/ash/file_system_provider",
        "//chrome/browser/ash/file_system_provider:test_support",
        "//chrome/browser/ash/guest_os",
        "//chrome/browser/ash/guest_os/public",
        "//chrome/browser/ash/login",
        "//chrome/browser/ash/login:test_support",
        "//chrome/browser/ash/login/app_mode/test:test_support",
        "//chrome/browser/ash/login/auth",
        "//chrome/browser/ash/login/demo_mode",
        "//chrome/browser/ash/login/demo_mode:test_support",
        "//chrome/browser/ash/login/enrollment",
        "//chrome/browser/ash/login/lock",
        "//chrome/browser/ash/login/lock:test_support",
        "//chrome/browser/ash/login/lock/online_reauth",
        "//chrome/browser/ash/login/oobe_quick_start/connectivity:test_support",
        "//chrome/browser/ash/login/quick_unlock",
        "//chrome/browser/ash/login/saml:test_support",
        "//chrome/browser/ash/login/screens:test_support",
        "//chrome/browser/ash/login/session",
        "//chrome/browser/ash/login/session:test_support",
        "//chrome/browser/ash/login/signin",
        "//chrome/browser/ash/login/test:test_support",
        "//chrome/browser/ash/login/ui",
        "//chrome/browser/ash/login/ui:test_support",
        "//chrome/browser/ash/login/ui/login_screen_extension_ui",
        "//chrome/browser/ash/login/users",
        "//chrome/browser/ash/login/users/avatar:test_support",
        "//chrome/browser/ash/net",
        "//chrome/browser/ash/notifications",
        "//chrome/browser/ash/os_feedback",
        "//chrome/browser/ash/ownership",
        "//chrome/browser/ash/platform_keys",
        "//chrome/browser/ash/platform_keys:test_support",
        "//chrome/browser/ash/platform_keys/key_permissions",
        "//chrome/browser/ash/policy/display",
        "//chrome/browser/ash/policy/reporting/event_based_logs",
        "//chrome/browser/ash/policy/reporting/event_based_logs/event_observers",
        "//chrome/browser/ash/policy/reporting/metrics_reporting",
        "//chrome/browser/ash/policy/reporting/metrics_reporting:test_support",
        "//chrome/browser/ash/policy/reporting/metrics_reporting/fatal_crash",
        "//chrome/browser/ash/policy/reporting/metrics_reporting/network",
        "//chrome/browser/ash/policy/reporting/os_updates",
        "//chrome/browser/ash/policy/status_collector",
        "//chrome/browser/ash/printing/history",
        "//chrome/browser/ash/printing/history:test_support",
        "//chrome/browser/ash/remote_apps",
        "//chrome/browser/ash/scalable_iph:test_support",
        "//chrome/browser/ash/settings",
        "//chrome/browser/ash/settings:test_support",
        "//chrome/browser/ash/system_web_apps/types:types",
        "//chrome/browser/ash/video_conference",
        "//chrome/browser/chromeos/smart_reader:browser_tests",
        "//chrome/browser/chromeos/tablet_mode:browser_tests",
        "//chrome/browser/enterprise/connectors/device_trust:features",
        "//chrome/browser/enterprise/connectors/device_trust/common",
        "//chrome/browser/image_decoder",
        "//chrome/browser/media/router:test_support",
        "//chrome/browser/nearby_sharing/common",
        "//chrome/browser/policy:onc",
        "//chrome/browser/policy/messaging_layer/proto:add_remove_user_event_proto",
        "//chrome/browser/policy/messaging_layer/proto:login_logout_event_proto",
        "//chrome/browser/resources/chromeos/accessibility:browser_tests",
        "//chrome/browser/scalable_iph:scalable_iph_factory",
        "//chrome/browser/ui/ash:browser_tests",
        "//chrome/browser/ui/ash/capture_mode",
        "//chrome/browser/ui/ash/holding_space:test_support",
        "//chrome/browser/ui/ash/keyboard",
        "//chrome/browser/ui/ash/keyboard:ash_test_support",
        "//chrome/browser/ui/ash/multi_user",
        "//chrome/browser/ui/ash/multi_user:test_support",
        "//chrome/browser/ui/ash/network",
        "//chrome/browser/ui/ash/shelf",
        "//chrome/browser/ui/ash/shelf:test_support",
        "//chrome/browser/ui/ash/system_web_apps",
        "//chrome/browser/ui/chromeos/read_write_cards",
        "//chrome/browser/ui/chromeos/read_write_cards:read_write_cards_manager",
        "//chrome/browser/ui/quick_answers",
        "//chrome/browser/ui/views/borealis:browser_tests",
        "//chrome/browser/ui/views/bruschetta:browser_tests",
        "//chrome/browser/ui/views/crostini",
        "//chrome/browser/ui/views/crostini:browser_test_support",
        "//chrome/browser/ui/views/crostini:browser_tests",
        "//chrome/browser/ui/views/editor_menu:editor_menu",
        "//chrome/browser/ui/views/editor_menu:utils",
        "//chrome/browser/ui/views/editor_menu:views",
        "//chrome/browser/ui/views/mahi",
        "//chrome/browser/ui/webui/ash",
        "//chrome/browser/ui/webui/ash:browser_tests",
        "//chrome/browser/ui/webui/ash/add_supervision",
        "//chrome/browser/ui/webui/ash/add_supervision:mojo_bindings",
        "//chrome/browser/ui/webui/ash/cloud_upload",
        "//chrome/browser/ui/webui/ash/crostini_upgrader:mojo_bindings",
        "//chrome/browser/ui/webui/ash/edu_coexistence",
        "//chrome/browser/ui/webui/ash/login",
        "//chrome/browser/ui/webui/ash/manage_mirrorsync:mojo_bindings",
        "//chrome/browser/ui/webui/ash/parent_access",
        "//chrome/browser/ui/webui/ash/parent_access:mojo_bindings",
        "//chrome/browser/ui/webui/ash/parent_access:proto",
        "//chrome/browser/ui/webui/ash/settings/pages/files/mojom",
        "//chrome/browser/ui/webui/ash/settings/test_support",
        "//chrome/browser/ui/webui/ash/skyvault",
        "//chrome/services/file_util/public/cpp:browser_tests",
        "//chrome/services/keymaster/public/mojom",
        "//chrome/services/keymint/public/mojom",
        "//chromeos:test_support",
        "//chromeos/ash/components/assistant:buildflags",
        "//chromeos/ash/components/attestation",
        "//chromeos/ash/components/attestation:test_support",
        "//chromeos/ash/components/audio",
        "//chromeos/ash/components/browser_context_helper",
        "//chromeos/ash/components/chaps_util:test_support",
        "//chromeos/ash/components/cryptohome",
        "//chromeos/ash/components/dbus:test_support",
        "//chromeos/ash/components/dbus/attestation",
        "//chromeos/ash/components/dbus/attestation:attestation_proto",
        "//chromeos/ash/components/dbus/biod",
        "//chromeos/ash/components/dbus/biod:biod_proto",
        "//chromeos/ash/components/dbus/cicerone",
        "//chromeos/ash/components/dbus/concierge",
        "//chromeos/ash/components/dbus/cros_disks",
        "//chromeos/ash/components/dbus/cryptohome",
        "//chromeos/ash/components/dbus/cryptohome:cryptohome_proto",
        "//chromeos/ash/components/dbus/debug_daemon",
        "//chromeos/ash/components/dbus/image_burner",
        "//chromeos/ash/components/dbus/rmad:rmad",
        "//chromeos/ash/components/dbus/seneschal",
        "//chromeos/ash/components/dbus/services:test_support",
        "//chromeos/ash/components/dbus/session_manager",
        "//chromeos/ash/components/dbus/shill",
        "//chromeos/ash/components/dbus/spaced",
        "//chromeos/ash/components/dbus/system_clock",
        "//chromeos/ash/components/dbus/system_proxy",
        "//chromeos/ash/components/dbus/system_proxy:system_proxy_proto",
        "//chromeos/ash/components/dbus/update_engine",
        "//chromeos/ash/components/dbus/upstart",
        "//chromeos/ash/components/dbus/vm_plugin_dispatcher",
        "//chromeos/ash/components/disks",
        "//chromeos/ash/components/disks:test_support",
        "//chromeos/ash/components/geolocation",
        "//chromeos/ash/components/hid_detection",
        "//chromeos/ash/components/hid_detection:test_support",
        "//chromeos/ash/components/kiosk/vision:vision",
        "//chromeos/ash/components/login/auth",
        "//chromeos/ash/components/login/auth:test_support",
        "//chromeos/ash/components/login/login_state:test_support",
        "//chromeos/ash/components/login/session",
        "//chromeos/ash/components/mojo_service_manager:test_support",
        "//chromeos/ash/components/network/portal_detector",
        "//chromeos/ash/components/osauth/public",
        "//chromeos/ash/components/osauth/test_support",
        "//chromeos/ash/components/phonehub:debug",
        "//chromeos/ash/components/scalable_iph",
        "//chromeos/ash/components/scalable_iph:constants",
        "//chromeos/ash/components/scalable_iph:iph_session",
        "//chromeos/ash/components/scalable_iph:logger",
        "//chromeos/ash/components/scalable_iph:scalable_iph_delegate",
        "//chromeos/ash/components/smbfs",
        "//chromeos/ash/components/standalone_browser:test_support",
        "//chromeos/ash/components/system",
        "//chromeos/ash/components/timezone",
        "//chromeos/ash/services/assistant:lib",
        "//chromeos/ash/services/assistant/public/cpp",
        "//chromeos/ash/services/assistant/public/proto",
        "//chromeos/ash/services/auth_factor_config",
        "//chromeos/ash/services/auth_factor_config",
        "//chromeos/ash/services/cros_healthd/public/cpp:test_support",
        "//chromeos/ash/services/device_sync/public/cpp:test_support",
        "//chromeos/ash/services/multidevice_setup/public/cpp:test_support",
        "//chromeos/ash/services/network_config",
        "//chromeos/ash/services/network_config:in_process_instance",
        "//chromeos/components/kcer:chaps_proto",
        "//chromeos/components/kiosk:kiosk",
        "//chromeos/components/magic_boost/public/cpp",
        "//chromeos/components/mahi/public/cpp",
        "//chromeos/components/mgs",
        "//chromeos/components/onc:test_support",
        "//chromeos/components/quick_answers:quick_answers",
        "//chromeos/components/quick_answers/public/cpp:cpp",
        "//chromeos/components/quick_answers/public/cpp:prefs",
        "//chromeos/components/remote_apps/mojom:mojom",
        "//chromeos/crosapi/cpp:crosapi_constants",
        "//chromeos/dbus/dlp",
        "//chromeos/dbus/missive:test_support",
        "//chromeos/process_proxy",
        "//chromeos/services/machine_learning/public/cpp:stub",
        "//chromeos/services/network_config/public/cpp:test_support",
        "//chromeos/services/tts",
        "//chromeos/strings",
        "//chromeos/ui/base",
        "//chromeos/ui/frame",
        "//chromeos/ui/frame:test_support",
        "//chromeos/ui/wm",
        "//components/access_code_cast/common:metrics",
        "//components/app_constants",
        "//components/app_restore",
        "//components/arc:arc_test_support",
        "//components/crash/content/browser/error_reporting:mock_crash_endpoint",
        "//components/desks_storage:test_support",
        "//components/device_event_log",
        "//components/device_signals/core/browser",
        "//components/drive",
        "//components/enterprise/data_controls/core/browser:dlp_policy_event_proto",
        "//components/exo:test_support",
        "//components/feedback:feedback",
        "//components/feedback/content:content",
        "//components/feedback/content:factory",
        "//components/feedback/redaction_tool",
        "//components/global_media_controls:global_media_controls",
        "//components/global_media_controls:test_support",
        "//components/live_caption:constants",
        "//components/manta",
        "//components/onc",
        "//components/prefs",
        "//components/quirks",
        "//components/reporting/client:report_queue",
        "//components/reporting/client:test_support",
        "//components/reporting/proto:metric_data_proto",
        "//components/reporting/storage:test_support",
        "//components/reporting/util:test_callbacks_support",
        "//components/rlz",
        "//components/services/app_service",
        "//components/services/app_service/public/cpp:test_support",
        "//components/session_manager/core",
        "//components/upload_list",
        "//components/user_manager:test_support",
        "//components/variations/field_trial_config:field_trial_config",
        "//components/web_resource",
        "//extensions/browser:test_support",
        "//extensions/components/native_app_window",
        "//mojo/core/embedder",
        "//services/accessibility/android:android_lib",
        "//services/accessibility/android:test_support",
        "//services/audio/public/cpp",
        "//services/audio/public/cpp:test_support",
        "//services/media_session/public/mojom",
        "//services/preferences/public/cpp",
        "//services/preferences/public/mojom",
        "//services/service_manager/public/cpp",
        "//third_party/blink/public/common",
        "//ui/base/idle",
        "//ui/base/idle:test_support",
        "//ui/base/ime/ash",
        "//ui/chromeos",
        "//ui/display:display_manager_test_api",
        "//ui/display/manager",
        "//ui/events/devices:test_support",
        "//ui/file_manager:file_manager_gen_resources_grit",
        "//ui/file_manager:resources_grit",
        "//ui/file_manager/integration_tests:build",
        "//ui/webui/resources/cr_components/app_management:mojo_bindings",
        "//ui/wm/public",
        "//url",
      ]
    }
    if (safe_browsing_mode == 1) {
      sources += [
        "../browser/safe_browsing/chrome_password_protection_service_browsertest.cc",
        "../browser/safe_browsing/chrome_password_protection_service_sync_browsertest.cc",
        "../browser/safe_browsing/client_side_detection_host_browsertest.cc",
        "../browser/safe_browsing/ohttp_key_service_browsertest.cc",
        "../browser/safe_browsing/safe_browsing_blocking_page_test.cc",
        "../browser/safe_browsing/safe_browsing_navigation_observer_browsertest.cc",
        "../browser/safe_browsing/safe_browsing_service_browsertest.cc",
        "../browser/safe_browsing/url_lookup_service_browsertest.cc",
        "../browser/safe_browsing/v4_embedded_test_server_browsertest.cc",
        "../browser/ssl/sct_reporting_service_browsertest.cc",
        "../renderer/safe_browsing/phishing_dom_feature_extractor_browsertest.cc",
        "../renderer/safe_browsing/threat_dom_details_browsertest.cc",
      ]
      deps += [
        "//chrome/browser/safe_browsing:metrics_collector",
        "//components/safe_browsing/content/browser:safe_browsing_blocking_page",
        "//components/safe_browsing/content/common:file_type_policies_test_support",
        "//components/safe_browsing/core/browser:safe_browsing_metrics_collector",
        "//components/safe_browsing/core/browser/hashprefix_realtime:hash_realtime_service",
        "//components/safe_browsing/core/browser/realtime:url_lookup_service",
        "//components/safe_browsing/core/common/fbs:client_model",
        "//components/safe_browsing/core/common/hashprefix_realtime:hash_realtime_utils",
      ]

      if (!is_mac) {
        sources += [
          # single-process mode hangs on Mac sometimes because of multiple UI
          # message loops. See 306348
          "../renderer/safe_browsing/phishing_classifier_browsertest.cc",
          "../renderer/safe_browsing/phishing_classifier_delegate_browsertest.cc",
        ]
      }
    }

    if (enable_captive_portal_detection) {
      sources += [ "../browser/captive_portal/captive_portal_browsertest.cc" ]
    }

    if (is_mac || is_win) {
      sources += [
        "../browser/extensions/api/networking_private/networking_private_apitest.cc",
        "../browser/extensions/api/networking_private/networking_private_service_client_apitest.cc",
      ]
      deps += [
        "//components/onc",
        "//components/wifi:test_support",
      ]
    }
    if (is_linux || is_chromeos || is_win) {
      sources += [
        # This test is for the spelling options submenu that's only for Windows,
        # ChromeOS, and Linux.
        "../browser/renderer_context_menu/spelling_options_submenu_observer_browsertest.cc",
      ]
    }
    if (is_linux || is_mac) {
      sources += [ "../browser/ui/views/first_run_dialog_browsertest.cc" ]
    }
    if (!is_posix || is_chromeos_ash) {
      sources -= [ "../common/time_format_browsertest.cc" ]
    }

    if (is_mac || is_win || is_linux || is_chromeos_lacros) {
      sources += [
        # Tests for non mobile and non CrOS (includes Linux, Win, Mac).
        "../browser/extensions/api/image_writer_private/image_writer_utility_client_browsertest.cc",
        "../browser/profiles/profile_statistics_browsertest.cc",
        "../browser/ui/signin/signin_reauth_view_controller_browsertest.cc",
        "../browser/ui/webui/signin/turn_sync_on_helper_browsertest.cc",
      ]

      if (!is_chromeos_lacros) {
        sources += [
          "../browser/browser_switcher/browser_switcher_browsertest.cc",
          "../browser/browser_switcher/browser_switcher_service_browsertest.cc",
          "../browser/enterprise/signin/enterprise_signin_service_browsertest.cc",
        ]
      }
    }
    if (is_linux || is_mac) {
      sources +=
          [ "../browser/first_run/first_run_internal_posix_browsertest.cc" ]
    }
    if (enable_service_discovery) {
      sources += [ "../browser/extensions/api/mdns/mdns_apitest.cc" ]
    }

    if ((is_linux || is_chromeos) && is_asan && is_lsan) {
      # TODO(crbug.com/40553979): Fix the flakiness on Linux Asan Lsan bot.
      sources -= [ "../browser/media/encrypted_media_browsertest.cc" ]
    }
    if (enable_library_cdms) {
      deps += [ "//media/cdm:cdm_paths" ]

      # Runtime dependencies.
      data_deps += [
        "//media/cdm/library_cdm/clear_key_cdm",
        "//third_party/widevine/cdm",
      ]
    }
    if (is_win) {
      # Runtime dependencies.
      data_deps += [ "//media/cdm/win/test:media_foundation_clear_key_cdm" ]
    }
    if (enable_oop_printing) {
      sources += [ "../browser/printing/print_backend_browsertest.cc" ]
      deps += [
        "//chrome/services/printing:lib",
        "//components/printing/browser",
        "//components/printing/common:mojo_interfaces",
        "//printing:test_support",
        "//printing/backend",
      ]
    }
    if (enable_print_preview) {
      sources += [
        "../browser/printing/print_browsertest.cc",
        "../browser/printing/print_browsertest.h",
        "../browser/printing/print_preview_dialog_controller_browsertest.cc",
        "../browser/printing/pwg_raster_converter_browsertest.cc",
        "../browser/printing/test_print_preview_observer.cc",
        "../browser/printing/test_print_preview_observer.h",
        "../browser/printing/test_print_view_manager.cc",
        "../browser/printing/test_print_view_manager.h",
        "../browser/ui/webui/print_preview/print_preview_ui_browsertest.cc",
      ]
      deps += [
        ":print_preview_test_support",
        "//printing:test_support",
      ]

      if (enable_pdf) {
        sources +=
            [ "../browser/printing/pdf_nup_converter_client_browsertest.cc" ]
        deps += [ "//pdf" ]
      }

      if (!is_chromeos) {
        sources +=
            [ "../browser/printing/system_access_process_print_browsertest.cc" ]
      }

      if (is_chromeos_ash) {
        sources += [ "../browser/ui/webui/print_preview/extension_printer_handler_adapter_ash_browsertest.cc" ]
      }

      if (is_chromeos_lacros) {
        sources += [ "../browser/ui/webui/print_preview/extension_printer_service_provider_lacros_browsertest.cc" ]
      }
    }
    if (enable_paint_preview) {
      sources += [
        "../browser/paint_preview/paint_preview_browsertest.cc",
        "../browser/paint_preview/paint_preview_compositor_browsertest.cc",
      ]
      deps += [
        "//components/paint_preview/browser",
        "//components/paint_preview/browser:test_support",
        "//components/paint_preview/common",
        "//components/paint_preview/common:test_utils",
        "//components/services/paint_preview_compositor/public/mojom",
      ]
    }
    if (use_brlapi) {
      deps += [ "//third_party/libbrlapi" ]
    } else if (enable_extensions) {
      sources -= [ "../browser/extensions/api/braille_display_private/braille_display_private_apitest.cc" ]
    }

    if (is_chromeos_ash && also_build_lacros_chrome && enable_extensions) {
      # Lacros chrome loads in helper a11y extensions, ensure their resources
      # are available in tests.
      # TODO(b:272150598): There must be a better way to ensure they are available
      # to the lacros binary.
      data += [ "$root_out_dir/lacros_clang_x64/resources/accessibility/" ]
    }

    if (is_chromeos_ash || ((is_linux || is_chromeos_lacros) && use_dbus)) {
      sources += [ "../browser/extensions/api/bluetooth_low_energy/bluetooth_low_energy_apitest.cc" ]
    }

    if (toolkit_views && !is_chromeos) {
      sources +=
          [ "../browser/ui/screen_capture_notification_ui_browsertest.cc" ]
    }

    if (enable_webui_tab_strip) {
      sources += [
        "../browser/ui/views/frame/webui_tab_strip_field_trial_browsertest.cc",
        "../browser/ui/webui/tab_strip/tab_strip_ui_browsertest.cc",
      ]
    }

    if (enable_spellcheck) {
      sources +=
          [ "../browser/site_isolation/spellcheck_per_process_browsertest.cc" ]
    }

    if (!is_chromeos_lacros) {
      sources +=
          [ "../browser/metrics/structured_metrics_service_browsertest.cc" ]
    }

    if (is_win || is_mac || is_linux) {
      sources += [
        "../browser/ui/startup/default_browser_prompt/default_browser_prompt_browsertest.cc",
        "../browser/ui/startup/first_run_service_browsertest.cc",
        "../browser/ui/views/profiles/profile_picker_dice_sign_in_provider_browsertest.cc",
        "../browser/ui/views/profiles/profile_picker_view_browsertest.cc",
        "../browser/ui/views/web_apps/web_app_integration_browsertest_mac_win_linux.cc",

        # Extension approvals tests for Windows/Linux/Mac platforms only.
        # ChromeOS has a different platform-specific approval flow.
        "../browser/ui/views/supervised_user/extension_install_blocked_by_parent_dialog_browsertest.cc",
        "../browser/ui/views/supervised_user/parent_permission_dialog_view_browsertest.cc",
        "../browser/ui/views/supervised_user/parent_permission_extension_flow_view_browsertest.cc",
      ]
      deps += [
        "../browser/enterprise/connectors/test:test_support",
        "//chrome/browser:main_extra_parts",
      ]
    }

    if (enterprise_data_controls && !is_android) {
      sources += [
        "//chrome/browser/enterprise/data_controls/desktop_data_controls_dialog_browsertest.cc",
        "//chrome/browser/enterprise/data_protection/clipboard_browsertest.cc",
        "//chrome/browser/enterprise/data_protection/data_protection_clipboard_utils_browsertest.cc",
      ]
      deps += [ "//chrome/browser/enterprise/data_controls:test_support" ]
    }

    sources += metric_integration_sources

    if (!is_chromeos) {
      sources += [ "../browser/webauthn/enclave_authenticator_browsertest.cc" ]
      deps += [ "//components/os_crypt/sync:test_support" ]
    }

    if (!is_chromeos) {
      sources +=
          [ "../browser/ui/webui/whats_new/whats_new_fetcher_browsertest.cc" ]
      deps += [ "//chrome/browser/ui/webui/whats_new:mojo_bindings" ]
    }
  }
}

if (is_chromeos_lacros) {
  source_set("lacros_test_support_ui") {
    testonly = true

    sources = [
      "../browser/lacros/account_manager/fake_account_manager_ui_dialog_waiter.cc",
      "../browser/lacros/account_manager/fake_account_manager_ui_dialog_waiter.h",
      "../browser/lacros/browser_test_util.cc",
      "../browser/lacros/browser_test_util.h",
    ]

    deps = [
      "//chrome/browser",
      "//chrome/browser/ui",
      "//chromeos/lacros",
      "//chromeos/lacros:test_support",
      "//components/account_manager_core:test_support",
      "//ui/platform_window",
      "//ui/views",
    ]
  }

  # This test target is intended for lacros chrome specific tests that depend
  # on crosapi.
  test("lacros_chrome_browsertests") {
    use_xvfb = use_xvfb_in_this_config

    configs += [ "//build/config:precompiled_headers" ]
    defines = [
      "HAS_OUT_OF_PROC_TEST_RUNNER",
      "CHROME_VERSION_MAJOR=" + chrome_version_major,
    ]

    sources = [
      "../browser/accessibility/live_caption/live_caption_surface_browsertest.cc",
      "../browser/apps/app_service/lacros_browser_shelf_lacros_browsertest.cc",
      "../browser/chromeos/enterprise/cloud_storage/one_drive_pref_observer_browsertest.cc",
      "../browser/chromeos/extensions/info_private_lacros_apitest.cc",
      "../browser/chromeos/extensions/login_screen/login_screen_storage/login_screen_storage_apitest.cc",
      "../browser/chromeos/extensions/wallpaper_apitest.cc",
      "../browser/chromeos/extensions/wm/wm_desks_private_apitest_lacros.cc",
      "../browser/chromeos/video_conference/video_conference_manager_client_browsertest.cc",
      "../browser/extensions/api/enterprise_device_attributes/enterprise_device_attributes_lacros_apitest.cc",
      "../browser/extensions/api/networking_private/networking_private_chromeos_apitest.cc",
      "../browser/extensions/api/offscreen/offscreen_api_lacros_browsertest.cc",
      "../browser/extensions/api/preference/preference_api_lacros_browsertest.cc",
      "../browser/extensions/api/proxy/proxy_apitest.cc",
      "../browser/extensions/api/shared_storage/shared_storage_private_apitest.cc",
      "../browser/extensions/api/vpn_provider/vpn_provider_apitest.cc",
      "../browser/extensions/extension_keeplist_lacros_browsertest.cc",
      "../browser/feedback/show_feedback_page_lacros_browsertest.cc",
      "../browser/lacros/app_mode/web_kiosk_installer_lacros_browsertest.cc",
      "../browser/lacros/browser_launcher_browsertest.cc",
      "../browser/lacros/browser_service_lacros_browsertest.cc",
      "../browser/lacros/cert/cert_db_initializer_browsertest.cc",
      "../browser/lacros/chaps_service_lacros_browsertest.cc",
      "../browser/lacros/clipboard_history_lacros_browsertest.cc",
      "../browser/lacros/clipboard_lacros_browsertest.cc",
      "../browser/lacros/component_policy_lacros_browsertest.cc",
      "../browser/lacros/crosapi_pref_observer_lacros_browsertest.cc",
      "../browser/lacros/desk_template_client_lacros_browsertest.cc",
      "../browser/lacros/device_attributes_lacros_browsertest.cc",
      "../browser/lacros/download_status_updater_lacros_browsertest.cc",
      "../browser/lacros/embedded_a11y_manager_lacros_browsertest.cc",
      "../browser/lacros/field_trial_service_lacros_browsertest.cc",
      "../browser/lacros/file_change_service_bridge_browsertest.cc",
      "../browser/lacros/file_manager_lacros_browsertest.cc",
      "../browser/lacros/full_restore_client_lacros_browsertest.cc",
      "../browser/lacros/geolocation/system_geolocation_source_lacros_browsertest.cc",
      "../browser/lacros/holding_space_service_lacros_browsertest.cc",
      "../browser/lacros/idle_service_lacros_browsertest.cc",
      "../browser/lacros/input_method_lacros_browsertest.cc",
      "../browser/lacros/keystore_service_lacros_browsertest.cc",
      "../browser/lacros/lacros_extension_apps_controller_lacros_browsertest.cc",
      "../browser/lacros/login_screen_storage_lacros_browsertest.cc",
      "../browser/lacros/login_state_lacros_browsertest.cc",
      "../browser/lacros/machine_learning_service_lacros_browsertest.cc",
      "../browser/lacros/magic_boost_lacros_browsertest.cc",
      "../browser/lacros/mahi_lacros_browsertest.cc",
      "../browser/lacros/media_session_lacros_browsertest.cc",
      "../browser/lacros/message_center_lacros_browsertest.cc",
      "../browser/lacros/metrics_lacros_browsertest.cc",
      "../browser/lacros/metrics_reporting_lacros_browsertest.cc",
      "../browser/lacros/multitask_menu_nudge_delegate_lacros_browsertest.cc",
      "../browser/lacros/net/lacros_extension_proxy_tracker_browsertest.cc",
      "../browser/lacros/net/network_settings_observer_browsertest.cc",
      "../browser/lacros/net/proxy_config_service_lacros_browsertest.cc",
      "../browser/lacros/networking_attributes_lacros_browsertest.cc",
      "../browser/lacros/overview_lacros_browsertest.cc",
      "../browser/lacros/parent_access_lacros_browsertest.cc",
      "../browser/lacros/policy_ui_lacros_browsertest.cc",
      "../browser/lacros/popup_lacros_browsertest.cc",
      "../browser/lacros/power_api_lacros_browsertest.cc",
      "../browser/lacros/print_preview_lacros_browsertest.cc",
      "../browser/lacros/remote_apps/remote_apps_proxy_browsertest.cc",
      "../browser/lacros/screen_manager_lacros_browsertest.cc",
      "../browser/lacros/smart_reader_lacros_browsertest.cc",
      "../browser/lacros/tab_scrubber_lacros_browsertest.cc",
      "../browser/lacros/tablet_mode_lacros_browsertest.cc",
      "../browser/lacros/video_conference_lacros_browsertest.cc",
      "../browser/lacros/wallpaper_lacros_browsertest.cc",
      "../browser/lacros/web_contents_can_go_back_observer_browsertest.cc",
      "../browser/lacros/window_lacros_browsertest.cc",
      "../browser/media/router/discovery/access_code/access_code_cast_pref_updater_lacros_browsertest.cc",
      "../browser/media/router/discovery/access_code/access_code_cast_sink_service_browsertest.cc",
      "../browser/media/webrtc/capture_handle_browsertest.cc",
      "../browser/media/webrtc/capture_policy_utils_browsertest.cc",
      "../browser/media/webrtc/get_all_screens_media_browsertest.cc",
      "../browser/media/webrtc/webrtc_getdisplaymedia_browsertest.cc",
      "../browser/metrics/structured/lacros_structured_metrics_delegate_browsertest.cc",
      "../browser/payments/webapps/payment_request_lacros_browsertest.cc",
      "../browser/policy/policy_extension_controlling_proxy_lacros_browsertest.cc",
      "../browser/sessions/app_session_restore_lacros_browsertest.cc",
      "../browser/speech/extension_api/tts_extension_api_lacros_browsertest.cc",
      "../browser/sync/test/lacros/sync_apps_toggle_sharing_lacros_browsertest.cc",
      "../browser/sync/test/lacros/sync_custom_passphrase_sharing_lacros_browsertest.cc",
      "../browser/sync/test/lacros/trusted_vault_keys_sharing_lacros_browsertest.cc",
      "../browser/ui/autofill/autofill_context_menu_manager_lacros_browsertest.cc",
      "../browser/ui/browser_navigator_browsertest.cc",
      "../browser/ui/browser_navigator_browsertest.h",
      "../browser/ui/browser_navigator_browsertest_chromeos.cc",
      "../browser/ui/lacros/screen_capture_notification_ui_lacros_browsertest.cc",
      "../browser/ui/sharing_hub/sharing_hub_bubble_controller_chromeos_lacros_browsertest.cc",
      "../browser/ui/startup/first_run_service_browsertest.cc",
      "../browser/ui/views/chrome_views_delegate_lacros_browsertest.cc",
      "../browser/ui/views/frame/browser_non_client_frame_view_chromeos_browsertest.cc",
      "../browser/ui/views/frame/immersive_mode_browser_view_test.cc",
      "../browser/ui/views/frame/immersive_mode_controller_chromeos_browsertest.cc",
      "../browser/ui/views/intent_picker_bubble_view_browsertest.cc",
      "../browser/ui/views/location_bar/intent_chip_button_browsertest.cc",
      "../browser/ui/views/profiles/profile_picker_view_browsertest.cc",
      "../browser/ui/views/tabs/alert_indicator_button_browsertest.cc",
      "../browser/ui/views/web_apps/web_app_integration_browsertest.cc",
      "../browser/ui/views/web_apps/web_app_integration_browsertest_cros.cc",
      "../browser/ui/views/web_apps/web_app_integration_browsertest_win_linux_cros.cc",
      "../browser/ui/webui/profile_helper_browsertest.cc",
      "../browser/upgrade_detector/get_installed_version_lacros_browsertest.cc",
      "../browser/web_applications/app_service/lacros_web_apps_controller_lacros_browsertest.cc",
      "../browser/web_applications/app_service/web_apps_chromeos_browsertest.cc",
      "../browser/web_applications/externally_managed_app_manager_browsertest.cc",
      "base/in_process_browser_test_browsertest_lacros.cc",

      # download_controller_client_lacros_browsertest.cc should become a unit
      # test.
      "../browser/lacros/download_controller_client_lacros_browsertest.cc",

      # ScreenCapturer should work for lacros with crosapi.
      "base/save_desktop_snapshot_browsertest.cc",
    ]

    deps = [
      ":browser_tests_runner",
      ":lacros_test_support_ui",
      ":sync_integration_test_support",
      ":test_support",
      ":test_support_ui",
      ":webrtc_browser_tests_base",
      "//chrome/app:command_ids",
      "//chrome/browser:main_extra_parts",
      "//chrome/browser/accessibility:test_support",
      "//chrome/browser/apps/app_service",
      "//chrome/browser/apps/app_service:app_registry_cache_waiter",
      "//chrome/browser/apps/app_service/app_icon",
      "//chrome/browser/apps/app_service/app_install:browser_tests",
      "//chrome/browser/apps/browser_instance",
      "//chrome/browser/apps/link_capturing",
      "//chrome/browser/apps/link_capturing:app_service_browser_tests",
      "//chrome/browser/apps/link_capturing:features",
      "//chrome/browser/apps/link_capturing:test_support",
      "//chrome/browser/chromeos",
      "//chrome/browser/chromeos:lacros_chrome_browsertests",
      "//chrome/browser/chromeos/app_mode",
      "//chrome/browser/chromeos/enterprise/cloud_storage",
      "//chrome/browser/chromeos/extensions/telemetry/api:browser_tests",
      "//chrome/browser/chromeos/extensions/vpn_provider",
      "//chrome/browser/chromeos/extensions/wm",
      "//chrome/browser/chromeos/network",
      "//chrome/browser/chromeos/policy/dlp",
      "//chrome/browser/chromeos/policy/dlp/test:test_support",
      "//chrome/browser/chromeos/printing/print_preview",
      "//chrome/browser/chromeos/smart_reader",
      "//chrome/browser/chromeos/video_conference",
      "//chrome/browser/media/router:test_support",
      "//chrome/browser/media/router/discovery/access_code:access_code_cast_feature",
      "//chrome/browser/media/router/discovery/access_code:access_code_sink_service",
      "//chrome/browser/policy:test_support",
      "//chrome/browser/sync",
      "//chrome/browser/themes",
      "//chrome/browser/ui:browser_element_identifiers",
      "//chrome/browser/ui:browser_navigator_params_headers",
      "//chrome/browser/ui/chromeos",
      "//chrome/browser/ui/chromeos:test_support",
      "//chrome/browser/ui/web_applications:app_service_browser_tests",
      "//chrome/browser/web_applications:app_service_browser_tests",
      "//chrome/browser/web_applications:prevent_close_test_support",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//chrome/browser/web_applications/app_service:test_support",
      "//chrome/test/media_router/access_code_cast:access_code_cast_integration_base",
      "//chromeos/components/kcer",
      "//chromeos/components/magic_boost/public/cpp:cpp",
      "//chromeos/components/mahi/public/cpp",
      "//chromeos/crosapi/cpp:cpp",
      "//chromeos/crosapi/cpp:test_support",
      "//chromeos/crosapi/mojom",
      "//chromeos/dbus/missive:test_support",
      "//chromeos/lacros",
      "//chromeos/lacros:test_support",
      "//chromeos/printing:test_support",
      "//chromeos/services/machine_learning/public/cpp",
      "//chromeos/services/machine_learning/public/cpp:stub",
      "//chromeos/services/machine_learning/public/mojom",
      "//chromeos/startup",
      "//chromeos/ui/base",
      "//chromeos/ui/frame",
      "//chromeos/ui/frame:test_support",
      "//components/account_manager_core:test_support",
      "//components/app_constants",
      "//components/captive_portal/content:content",
      "//components/captive_portal/core:buildflags",
      "//components/feature_engagement/public:public",
      "//components/feature_engagement/test:test_support",
      "//components/infobars/content:content",
      "//components/live_caption:constants",
      "//components/live_caption:live_caption",
      "//components/metrics/structured",
      "//components/metrics/structured:structured_events",
      "//components/onc:onc",
      "//components/policy/content",
      "//components/proxy_config:proxy_config",
      "//components/reporting/proto:metric_data_proto",
      "//components/services/app_service",
      "//components/services/app_service/public/cpp:test_support",
      "//components/soda:constants",
      "//components/user_manager:user_manager",
      "//components/web_package",
      "//components/web_package/test_support",
      "//components/webapps/browser",
      "//components/webapps/common",
      "//services/preferences/public/cpp:cpp",
      "//ui/aura:test_support",
      "//ui/display:test_support",
      "//ui/events:test_support",
      "//ui/gfx/codec",
      "//ui/ozone",
      "//ui/platform_window",
      "//ui/strings:ui_strings_grit",
    ]

    if (use_cups) {
      sources += [
        "../browser/chromeos/extensions/printing_metrics/printing_metrics_apitest.cc",
        "../browser/extensions/api/printing/printing_apitest.cc",
        "../browser/printing/web_api/web_printing_browsertest.cc",
      ]
      deps += [
        "//chrome/browser/chromeos/extensions/printing_metrics",
        "//chrome/browser/chromeos/printing",
        "//chromeos/printing",
      ]
    }

    data = [
      "//chrome/test/data/",
      "//content/test/data/",
      "data/banners/",
      "data/extensions/",
      "data/intent_picker/",
      "data/media/",
      "data/policy/test_certs/",
      "data/result_queue.js",
      "data/webapps_integration/",
      "data/web_app_badging/",
      "data/web_app_shortcuts/",
      "data/web_apps/",
      "data/web_share_target/",
      "data/webrtc",
      "data/webshare/",
    ]

    data_deps = [
      "//build:version_metadata",
      "//chrome:packed_resources",
      "//testing/buildbot/filters:lacros_chrome_browsertests_filters",
    ]

    if (enable_extensions) {
      data_deps +=
          [ "//chrome/browser/resources/accessibility:extension_resources" ]
      data += [ "$root_out_dir/resources/accessibility/" ]
    }
  }
}

if (is_linux || is_chromeos || is_mac || is_win || is_android) {
  import("//tools/binary_size/sizes.gni")

  # TODO(b/246519185) - Py3 incompatible, decide if to keep test.
  #  if (!is_android) {
  #    group("browser_tests_apprtc") {
  #      testonly = true
  #      data_deps = [ ":browser_tests" ]
  #      data = [
  #        "//third_party/webrtc/rtc_tools/testing/browsertest/apprtc/out/app_engine/",
  #        "//third_party/webrtc/rtc_tools/testing/browsertest/apprtc/temp/google-cloud-sdk/",
  #        "//third_party/webrtc/rtc_tools/testing/browsertest/collider/",
  #      ]
  #      if (is_win) {
  #        write_runtime_deps = "$root_out_dir/$target_name.exe.runtime_deps"
  #      } else {
  #        write_runtime_deps = "$root_out_dir/$target_name.runtime_deps"
  #      }
  #    }
  #  }

  sizes_test("chrome_sizes") {
    data_deps = [ "//chrome" ]
    if (is_win) {
      data_deps += [ "//chrome/installer/mini_installer" ]
    }
    if (is_android) {
      data_deps -= [ "//chrome" ]
      data_deps += [ "//chrome/android:chrome_public_apk" ]
    }
  }
}

group("telemetry_perf_unittests_base") {
  testonly = true
  data = [
    # For isolate contract.
    "//testing/scripts/run_telemetry_as_googletest.py",

    # For smoke testing run_performance_tests.py
    "//testing/scripts/run_performance_tests.py",

    # For tests in tools/perf/process_perf_results_unittest.py
    "//build/android/pylib/",
    "//third_party/logdog/logdog",
  ]

  data_deps = [ "//testing:test_scripts_shared" ]
}

if (!is_android) {
  _args = [
    "../../tools/perf/run_tests",
    "-v",
    "--chromium-output-directory=@WrappedPath(.)",
  ]
  if (is_debug) {
    _args += [ "--browser=debug" ]
  } else {
    _args += [ "--browser=release" ]
  }
  _data_deps = [
    ":telemetry_perf_unittests_base",
    "//tools/perf:perf",
  ]
  if (is_chromeos_ash && is_chromeos_device) {
    cros_test_wrapper_script_test("telemetry_perf_unittests") {
      args = [ "../../testing/scripts/run_telemetry_as_googletest.py" ] + _args
      data_deps = _data_deps
    }
  } else {
    script_test("telemetry_perf_unittests") {
      script = "//testing/scripts/run_telemetry_as_googletest.py"
      args = _args
      data_deps = _data_deps
    }
  }
} else {
  template("telemetry_perf_unittests_android_template") {
    forward_variables_from(invoker, [ "telemetry_target_suffix" ])
    group(target_name) {
      testonly = true
      data_deps = [
        ":telemetry_perf_unittests_base",
        "//tools/perf:perf${telemetry_target_suffix}",
      ]
    }
  }

  foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
    telemetry_perf_unittests_android_template(
        "telemetry_perf_unittests${_target_suffix}") {
      telemetry_target_suffix = _target_suffix
    }
  }
}

group("telemetry_perf_tests_base") {
  testonly = true
  data_deps = [
    # Needed for isolate script to execute.
    "//testing:test_scripts_shared",
  ]
}

if (!is_android) {
  group("telemetry_perf_tests") {
    testonly = true
    data_deps = [
      ":telemetry_perf_tests_base",
      "//tools/perf/:perf",
    ]
  }
} else {
  # TODO(crbug.com/40190643): Merge this back into "telemetry_perf_tests" since
  # splitting the performance test targets is being postponed.
  template("telemetry_perf_tests_android_template") {
    forward_variables_from(invoker, [ "telemetry_target_suffix" ])
    group(target_name) {
      testonly = true
      data_deps = [
        ":telemetry_perf_tests_base",
        "//tools/perf/:perf${telemetry_target_suffix}",
      ]

      # Needed by startup.mobile benchmark.
      data_deps += [ "//chrome/android/webapk/shell_apk:webapk" ]

      if (telemetry_target_suffix == "_android_clank_chrome") {
        # Depending on Android version, either Chrome.apk or Monochrome.apk can
        # be selected. See ChromeBackendSettings.GetApkName method in
        # catapult/telemetry/telemetry/internal/backends/android_browser_backend_settings.py.
        data_deps += [ "//tools/perf/:perf_android_clank_monochrome" ]
      }

      if (telemetry_target_suffix == "_android_webview" &&
          enable_chrome_android_internal) {
        # This suffix is used by all webview tests. Several different webview
        # APKs can be used, depending on the platform.
        data_deps += [
          "//tools/perf/:perf_android_clank_monochrome",
          "//tools/perf/:perf_android_clank_trichrome_webview_bundle",
          "//tools/perf/:perf_android_clank_webview",
        ]
      }
    }
  }

  foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
    telemetry_perf_tests_android_template(
        "telemetry_perf_tests${_target_suffix}") {
      telemetry_target_suffix = _target_suffix
    }
  }
}

group("ct_telemetry_perf_tests_without_chrome") {
  testonly = true
  deps = [ "//tools/perf/:perf_without_chrome" ]

  data = [ "//tools/perf/contrib/cluster_telemetry/" ]

  data_deps = [
    "//components/subresource_filter/tools:index_ruleset",
    "//testing:run_perf_test",
  ]
}

# New target that will replace telemetry_perf_tests when testing
# is done.
template("performance_test_suite_template_base") {
  forward_variables_from(invoker,
                         [
                           "override_board",
                           "data_deps",
                         ])
  script_test(target_name) {
    script = "//testing/scripts/run_performance_tests.py"
    if (is_chromeos_device) {
      if (defined(override_board)) {
        # TODO(b/248270560): Restore the --flash once the bug is fixed.
        if (is_chromeos_lacros && chrome_pgo_phase == 1 &&
            (override_board == "jacuzzi" || override_board == "jacuzzi64")) {
          args = [ "bin/cros_update_wrapper --board=${override_board} ../../tools/perf/run_benchmark" ]
        } else {
          args = [ "bin/cros_update_wrapper --board=${override_board} --flash ../../tools/perf/run_benchmark" ]
        }
      } else {
        args = [ "bin/cros_update_wrapper ../../tools/perf/run_benchmark" ]
      }
    } else {
      args = [ "../../tools/perf/run_benchmark" ]
    }

    if (!is_chromeos_lacros) {
      data_deps += [
        "//components:components_perftests",
        "//testing:run_perf_test",
      ]
    }

    if (!is_chromeos_lacros && !is_android) {
      data_deps += [
        "//base:base_perftests",
        "//components/tracing:tracing_perftests",
      ]
    }

    if (build_dawn_tests && !is_chromeos_lacros) {
      data_deps += [ "//third_party/dawn/src/dawn/tests:dawn_perf_tests" ]
    }

    if (!is_chromeos_lacros) {
      data_deps += [ "//third_party/dawn/src/tint/cmd/bench:bench_cmd" ]
    }

    if (!is_android && !is_chromeos_lacros) {
      data_deps += [
        "//chrome/test:load_library_perf_tests",
        "//ui/views:views_perftests",
      ]
    }

    if (!is_android) {
      data_deps += [ "//testing:run_perf_test" ]
    }
  }
}

if (!is_android) {
  template("performance_test_suite_template") {
    forward_variables_from(invoker, [ "override_board" ])
    performance_test_suite_template_base(target_name) {
      data_deps = [ "//chrome/test:telemetry_perf_tests" ]
    }
  }
} else {
  # TODO(crbug.com/40190643): Merge this back into
  # "performance_test_suite_template" since splitting the performance test
  # targets is being postponed.
  template("performance_test_suite_template_android") {
    forward_variables_from(invoker,
                           [
                             "override_board",
                             "telemetry_target_suffix",
                           ])
    performance_test_suite_template_base(target_name) {
      data_deps =
          [ "//chrome/test:telemetry_perf_tests${telemetry_target_suffix}" ]
    }
  }
}

if (!is_android) {
  performance_test_suite_template("performance_test_suite") {
  }
} else {
  import("//tools/perf/chrome_telemetry_build/android_browser_types.gni")
  foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
    performance_test_suite_template_android(
        "performance_test_suite${_target_suffix}") {
      telemetry_target_suffix = _target_suffix
    }
  }
}

# Generate performance_test_suite_${board} targets.
# These set --board to ${board} instead of deriving it from the target.
# This is useful for Lacros, where the generic build is deployed to
# many different targets.
if (is_chromeos_device && cros_boards != "") {
  foreach(_board, string_split(cros_boards, ":")) {
    _board_underscore = string_replace(_board, "-", "_")
    performance_test_suite_template(
        "performance_test_suite_${_board_underscore}") {
      override_board = _board
    }
  }
}

if (is_android) {
  # Difference between this and performance_test_suite is that this runs a devil
  # script before the build, to remove the system webview. See
  # //testing/buildbot/gn_isolate_map.pyl
  group("performance_webview_test_suite") {
    testonly = true
    data_deps = [
      "//android_webview/tools/system_webview_shell:system_webview_shell_apk",
      "//chrome/test:performance_test_suite_android_webview",
    ]
  }

  # Difference between this and telemetry_perf_tests is that this runs a devil
  # script before the build, to remove the system webview. See
  # //testing/buildbot/gn_isolate_map.pyl
  group("telemetry_perf_webview_tests") {
    testonly = true
    deps = [ "//chrome/test:telemetry_perf_tests_android_webview" ]
  }
}

config("disable_thinlto_cache_flags") {
  if (is_linux && use_thin_lto) {
    # This build target has so many inputs the LLD will run into the default
    # vm.max_map_count limit of 65530 memory mappings when using the ThinLTO
    # cache.
    # TODO (crbug.com/1183211): Re-enable once the linker has been fixed.
    ldflags = [ "-Wl,--thinlto-cache-dir=" ]
  }
}

test("unit_tests") {
  use_xvfb = use_xvfb_in_this_config

  inputs = [
    # enums.xml is analyzed by AboutFlagsHistogramTest, so this
    # dependency is needed to make commit bots run unit_tests on
    # enums.xml changes.
    "../../tools/metrics/histograms/enums.xml",

    # flag-metadata.json is analyzed by AboutFlagsTest, so this dependency is
    # needed to re-run unit_tests on changes to that file. Likewise for
    # flag-never-expire-list.json.
    "../browser/flag-metadata.json",
    "../browser/flag-never-expire-list.json",
  ]

  if (!is_android) {
    inputs += [
      # These files are analyzed by BrowserUserEducationServiceTest, so this
      # dependency is needed to re-run unit_tests on changes to that file.
      "//tools/metrics/actions/actions.xml",
      "//tools/metrics/histograms/metadata/feature_engagement/histograms.xml",
      "//tools/metrics/histograms/metadata/user_education/histograms.xml",
    ]
  }

  sources = [
    # All unittests in browser, common, renderer and service.
    "../browser/about_flags_unittest.cc",
    "../browser/after_startup_task_utils_unittest.cc",
    "../browser/ai/ai_manager_keyed_service_unittest.cc",
    "../browser/ai/ai_rewriter_unittest.cc",
    "../browser/ai/ai_summarizer_unittest.cc",
    "../browser/ai/ai_text_session_unittest.cc",
    "../browser/ai/ai_writer_unittest.cc",
    "../browser/apps/icon_standardizer_unittest.cc",
    "../browser/apps/user_type_filter_unittest.cc",
    "../browser/autocomplete/chrome_autocomplete_provider_client_unittest.cc",
    "../browser/autocomplete/chrome_autocomplete_scheme_classifier_unittest.cc",
    "../browser/autocomplete/provider_state_service_factory_unittest.cc",
    "../browser/autocomplete/search_provider_unittest.cc",
    "../browser/autocomplete/shortcuts_provider_extension_unittest.cc",
    "../browser/autofill/automated_tests/cache_replayer_unittest.cc",
    "../browser/background_fetch/background_fetch_delegate_impl_unittest.cc",
    "../browser/background_fetch/background_fetch_permission_context_unittest.cc",
    "../browser/background_sync/background_sync_controller_impl_unittest.cc",
    "../browser/background_sync/periodic_background_sync_permission_context_unittest.cc",
    "../browser/battery/battery_saver_unittest.cc",
    "../browser/bluetooth/bluetooth_chooser_context_unittest.cc",
    "../browser/bookmarks/managed_bookmark_service_unittest.cc",
    "../browser/browser_about_handler_unittest.cc",
    "../browser/browsing_data/browsing_data_history_observer_service_unittest.cc",
    "../browser/browsing_data/browsing_data_lifetime_policy_handler_unittest.cc",
    "../browser/browsing_data/chrome_browsing_data_model_delegate_unittest.cc",
    "../browser/browsing_data/chrome_browsing_data_remover_delegate_unittest.cc",
    "../browser/browsing_data/counters/bookmark_counter_unittest.cc",
    "../browser/browsing_data/counters/browsing_data_counter_utils_unittest.cc",
    "../browser/browsing_data/counters/site_data_counting_helper_unittest.cc",
    "../browser/browsing_data/counters/site_settings_counter_unittest.cc",
    "../browser/browsing_data/site_data_size_collector_unittest.cc",
    "../browser/chained_back_navigation_tracker_unittest.cc",
    "../browser/chooser_controller/title_util_unittest.cc",
    "../browser/chrome_browser_field_trials_unittest.cc",
    "../browser/chrome_content_browser_client_unittest.cc",
    "../browser/command_updater_impl_unittest.cc",
    "../browser/commerce/browser_utils_unittest.cc",
    "../browser/commerce/product_specifications/product_specifications_service_factory_unittest.cc",
    "../browser/complex_tasks/task_tab_helper_unittest.cc",
    "../browser/component_updater/afp_blocked_domain_list_component_installer_unittest.cc",
    "../browser/component_updater/chrome_component_updater_configurator_unittest.cc",
    "../browser/component_updater/crl_set_component_installer_unittest.cc",
    "../browser/component_updater/masked_domain_list_component_installer_unittest.cc",
    "../browser/component_updater/origin_trials_component_installer_unittest.cc",
    "../browser/component_updater/pki_metadata_component_installer_unittest.cc",
    "../browser/component_updater/privacy_sandbox_attestations_component_installer_unittest.cc",
    "../browser/component_updater/subresource_filter_component_installer_unittest.cc",
    "../browser/component_updater/tpcd_metadata_component_installer_unittest.cc",
    "../browser/component_updater/trust_token_key_commitments_component_installer_unittest.cc",
    "../browser/content_index/content_index_provider_unittest.cc",
    "../browser/content_settings/content_settings_default_provider_unittest.cc",
    "../browser/content_settings/content_settings_origin_value_map_unittest.cc",
    "../browser/content_settings/content_settings_policy_provider_unittest.cc",
    "../browser/content_settings/content_settings_pref_provider_unittest.cc",
    "../browser/content_settings/cookie_settings_factory_unittest.cc",
    "../browser/content_settings/host_content_settings_map_unittest.cc",
    "../browser/content_settings/mock_settings_observer.cc",
    "../browser/content_settings/mock_settings_observer.h",
    "../browser/content_settings/one_time_permission_provider_unittest.cc",
    "../browser/content_settings/page_specific_content_settings_unittest.cc",
    "../browser/content_settings/sound_content_setting_observer_unittest.cc",
    "../browser/custom_handlers/chrome_protocol_handler_registry_unittest.cc",
    "../browser/data_sharing/data_sharing_navigation_throttle_unittest.cc",
    "../browser/data_sharing/data_sharing_service_factory_unittest.cc",
    "../browser/download/chrome_download_manager_delegate_unittest.cc",
    "../browser/download/deferred_client_wrapper_unittest.cc",
    "../browser/download/download_core_service_impl_unittest.cc",
    "../browser/download/download_history_unittest.cc",
    "../browser/download/download_item_model_unittest.cc",
    "../browser/download/download_item_warning_data_unittest.cc",
    "../browser/download/download_offline_content_provider_unittest.cc",
    "../browser/download/download_prefs_unittest.cc",
    "../browser/download/download_query_unittest.cc",
    "../browser/download/download_request_limiter_unittest.cc",
    "../browser/download/download_stats_unittest.cc",
    "../browser/download/download_status_updater_unittest.cc",
    "../browser/download/download_target_determiner_unittest.cc",
    "../browser/download/download_ui_controller_unittest.cc",
    "../browser/download/offline_item_utils_unittest.cc",
    "../browser/engagement/important_sites_util_unittest.cc",
    "../browser/engagement/site_engagement_service_unittest.cc",
    "../browser/enterprise/connectors/interstitials/enterprise_page_unittest.cc",
    "../browser/enterprise/identifiers/profile_id_service_factory_unittest.cc",
    "../browser/enterprise/reporting/browser_report_generator_unittest.cc",
    "../browser/enterprise/reporting/legacy_tech/legacy_tech_report_generator_unittest.cc",
    "../browser/enterprise/reporting/legacy_tech/legacy_tech_service_unittest.cc",
    "../browser/enterprise/reporting/legacy_tech/legacy_tech_url_matcher_unittest.cc",
    "../browser/enterprise/reporting/policy_info_unittest.cc",
    "../browser/enterprise/reporting/profile_report_generator_unittest.cc",
    "../browser/enterprise/reporting/real_time_report_controller_unittest.cc",
    "../browser/enterprise/reporting/report_generator_unittest.cc",
    "../browser/enterprise/reporting/report_request_queue_generator_unittest.cc",
    "../browser/enterprise/reporting/report_scheduler_unittest.cc",
    "../browser/enterprise/util/managed_browser_utils_unittest.cc",
    "../browser/external_protocol/external_protocol_handler_unittest.cc",
    "../browser/favicon/favicon_utils_unittest.cc",
    "../browser/favicon/large_icon_service_factory_unittest.cc",
    "../browser/file_select_helper_unittest.cc",
    "../browser/file_system_access/chrome_file_system_access_permission_context_unittest.cc",
    "../browser/first_party_sets/first_party_sets_navigation_throttle_unittest.cc",
    "../browser/first_party_sets/first_party_sets_overrides_policy_handler_unittest.cc",
    "../browser/first_party_sets/first_party_sets_policy_service_factory_unittest.cc",
    "../browser/first_party_sets/first_party_sets_policy_service_unittest.cc",
    "../browser/font_pref_change_notifier_unittest.cc",
    "../browser/geolocation/geolocation_permission_context_delegate_unittest.cc",
    "../browser/history/history_tab_helper_unittest.cc",
    "../browser/history_clusters/history_clusters_tab_helper_unittest.cc",
    "../browser/idle/idle_detection_permission_context_unittest.cc",
    "../browser/internal_auth_unittest.cc",
    "../browser/k_anonymity_service/k_anonymity_service_client_unittest.cc",
    "../browser/k_anonymity_service/k_anonymity_service_storage_unittest.cc",
    "../browser/k_anonymity_service/k_anonymity_trust_token_getter_unittest.cc",
    "../browser/k_anonymity_service/remote_trust_token_query_answerer_unittest.cc",
    "../browser/language/language_model_manager_factory_unittest.cc",
    "../browser/language/url_language_histogram_factory_unittest.cc",
    "../browser/logging_chrome_unittest.cc",
    "../browser/login_detection/login_detection_prefs_unittest.cc",
    "../browser/login_detection/login_detection_tab_helper_unittest.cc",
    "../browser/login_detection/oauth_login_detector_unittest.cc",
    "../browser/media/media_engagement_contents_observer_unittest.cc",
    "../browser/media/media_engagement_preloaded_list_unittest.cc",
    "../browser/media/media_engagement_score_unittest.cc",
    "../browser/media/media_engagement_service_unittest.cc",
    "../browser/media/media_engagement_session_unittest.cc",
    "../browser/media/media_storage_id_salt_unittest.cc",
    "../browser/media/router/presentation/presentation_service_delegate_impl_unittest.cc",
    "../browser/media/webrtc/capture_policy_utils_unittest.cc",
    "../browser/media/webrtc/media_device_salt_service_factory_unittest.cc",
    "../browser/media/webrtc/media_stream_device_permission_context_unittest.cc",
    "../browser/media_effects/media_effects_manager_binder_unittest.cc",
    "../browser/media_effects/media_effects_service_factory_unittest.cc",
    "../browser/metrics/chrome_browser_main_extra_parts_metrics_unittest.cc",
    "../browser/metrics/chrome_metrics_extensions_helper_unittest.cc",
    "../browser/metrics/chrome_metrics_service_accessor_unittest.cc",
    "../browser/metrics/chrome_metrics_service_client_unittest.cc",
    "../browser/metrics/chrome_metrics_services_manager_client_unittest.cc",
    "../browser/metrics/process_memory_metrics_emitter_unittest.cc",
    "../browser/metrics/tab_footprint_aggregator_unittest.cc",
    "../browser/metrics/variations/chrome_variations_service_client_unittest.cc",
    "../browser/navigation_predictor/navigation_predictor_unittest.cc",
    "../browser/net/cert_verifier_policy_unittest.cc",
    "../browser/net/chrome_network_delegate_unittest.cc",
    "../browser/net/chrome_report_sender_unittest.cc",
    "../browser/net/convert_explicitly_allowed_network_ports_pref_unittest.cc",
    "../browser/net/dns_probe_runner_unittest.cc",
    "../browser/net/dns_probe_service_factory_unittest.cc",
    "../browser/net/explicitly_allowed_network_ports_policy_handler_unittest.cc",
    "../browser/net/net_error_tab_helper_unittest.cc",
    "../browser/net/probe_message_unittest.cc",
    "../browser/net/secure_dns_config_unittest.cc",
    "../browser/net/secure_dns_policy_handler_unittest.cc",
    "../browser/net/secure_dns_util_unittest.cc",
    "../browser/net/stub_resolver_config_reader_unittest.cc",
    "../browser/notifications/metrics/notification_metrics_logger_unittest.cc",
    "../browser/notifications/notification_display_queue_unittest.cc",
    "../browser/notifications/notification_display_service_impl_unittest.cc",
    "../browser/notifications/notification_permission_context_unittest.cc",
    "../browser/notifications/notification_platform_bridge_unittest.cc",
    "../browser/notifications/notification_trigger_scheduler_unittest.cc",
    "../browser/notifications/persistent_notification_handler_unittest.cc",
    "../browser/notifications/platform_notification_service_unittest.cc",
    "../browser/optimization_guide/chrome_hints_manager_unittest.cc",
    "../browser/optimization_guide/chrome_model_quality_logs_uploader_service_unittest.cc",
    "../browser/page_content_annotations/page_content_annotations_web_contents_observer_unittest.cc",
    "../browser/page_load_metrics/metrics_web_contents_observer_unittest.cc",
    "../browser/page_load_metrics/observers/core/amp_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/core/ukm_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/document_write_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/from_gws_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/gws_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/lcp_critical_path_predictor_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/loading_predictor_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/local_network_requests_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/multi_tab_loading_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/page_anchors_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/page_load_metrics_observer_test_harness.cc",
    "../browser/page_load_metrics/observers/page_load_metrics_observer_test_harness.h",
    "../browser/page_load_metrics/observers/prefetch_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/protocol_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/scheme_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/service_worker_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/signed_exchange_page_load_metrics_observer_unittest.cc",
    "../browser/page_load_metrics/observers/translate_page_load_metrics_observer_unittest.cc",
    "../browser/password_manager/chrome_password_manager_client_unittest.cc",
    "../browser/password_manager/chrome_webauthn_credentials_delegate_unittest.cc",
    "../browser/performance_manager/decorators/helpers/page_live_state_decorator_helper_unittest.cc",
    "../browser/performance_manager/metrics/metrics_provider_common_unittest.cc",
    "../browser/performance_manager/metrics/page_resource_monitor_unittest.cc",
    "../browser/performance_manager/policies/working_set_trimmer_policy_unittest.cc",
    "../browser/performance_monitor/system_monitor_unittest.cc",
    "../browser/persisted_state_db/session_proto_db_factory_unittest.cc",
    "../browser/picture_in_picture/picture_in_picture_bounds_cache_unittest.cc",
    "../browser/picture_in_picture/picture_in_picture_window_manager_unittest.cc",
    "../browser/plugins/pdf_iframe_navigation_throttle_unittest.cc",
    "../browser/policy/chrome_browser_policy_connector_unittest.cc",
    "../browser/policy/cloud/user_policy_signin_service_unittest.cc",
    "../browser/policy/cloud/user_policy_signin_service_util_unittest.cc",
    "../browser/policy/homepage_location_policy_handler_unittest.cc",
    "../browser/policy/javascript_policy_handler_unittest.cc",
    "../browser/policy/messaging_layer/public/report_client_unittest.cc",
    "../browser/policy/messaging_layer/upload/configuration_file_controller_unittest.cc",
    "../browser/policy/messaging_layer/upload/encrypted_reporting_client_unittest.cc",
    "../browser/policy/messaging_layer/upload/event_upload_size_controller_unittest.cc",
    "../browser/policy/messaging_layer/upload/file_upload_job_unittest.cc",
    "../browser/policy/messaging_layer/upload/network_condition_service_unittest.cc",
    "../browser/policy/messaging_layer/upload/record_handler_impl_unittest.cc",
    "../browser/policy/messaging_layer/upload/record_handler_upload_unittest.cc",
    "../browser/policy/messaging_layer/upload/record_upload_request_builder_unittest.cc",
    "../browser/policy/messaging_layer/upload/server_uploader_unittest.cc",
    "../browser/policy/messaging_layer/upload/testing_network_condition_service.cc",
    "../browser/policy/messaging_layer/upload/testing_network_condition_service.h",
    "../browser/policy/messaging_layer/upload/upload_client_unittest.cc",
    "../browser/policy/messaging_layer/upload/upload_provider_unittest.cc",
    "../browser/policy/messaging_layer/util/dm_token_retriever_provider_unittest.cc",
    "../browser/policy/messaging_layer/util/report_queue_manual_test_context_unittest.cc",
    "../browser/policy/messaging_layer/util/upload_response_parser_unittest.cc",
    "../browser/policy/messaging_layer/util/user_dm_token_retriever_unittest.cc",
    "../browser/policy/profile_policy_connector_unittest.cc",
    "../browser/policy/webusb_allow_devices_for_urls_policy_handler_unittest.cc",
    "../browser/predictors/autocomplete_action_predictor_table_unittest.cc",
    "../browser/predictors/autocomplete_action_predictor_unittest.cc",
    "../browser/predictors/lcp_critical_path_predictor/lcp_critical_path_predictor_util_unittest.cc",
    "../browser/predictors/lcp_critical_path_predictor/prewarm_http_disk_cache_manager_unittest.cc",
    "../browser/predictors/loading_data_collector_unittest.cc",
    "../browser/predictors/loading_predictor_config_unittest.cc",
    "../browser/predictors/loading_predictor_tab_helper_unittest.cc",
    "../browser/predictors/loading_predictor_unittest.cc",
    "../browser/predictors/loading_stats_collector_unittest.cc",
    "../browser/predictors/preconnect_manager_unittest.cc",
    "../browser/predictors/prefetch_manager_unittest.cc",
    "../browser/predictors/resource_prefetch_predictor_tables_unittest.cc",
    "../browser/predictors/resource_prefetch_predictor_unittest.cc",
    "../browser/prefs/browser_prefs_unittest.cc",
    "../browser/prefs/chrome_command_line_pref_store_proxy_unittest.cc",
    "../browser/prefs/chrome_command_line_pref_store_ssl_manager_unittest.cc",
    "../browser/prefs/chrome_command_line_pref_store_unittest.cc",
    "../browser/prefs/chrome_pref_service_unittest.cc",
    "../browser/prefs/incognito_mode_prefs_unittest.cc",
    "../browser/prefs/profile_pref_store_manager_unittest.cc",
    "../browser/prefs/proxy_policy_unittest.cc",
    "../browser/prefs/session_startup_pref_unittest.cc",
    "../browser/preloading/prefetch/no_state_prefetch/no_state_prefetch_unit_test_utils.cc",
    "../browser/preloading/prefetch/no_state_prefetch/no_state_prefetch_unit_test_utils.h",
    "../browser/preloading/prefetch/no_state_prefetch/no_state_prefetch_unittest.cc",
    "../browser/preloading/prefetch/prefetch_service/chrome_prefetch_service_delegate_unittest.cc",
    "../browser/preloading/prefetch/prefetch_service/prefetch_origin_decider_unittest.cc",
    "../browser/preloading/preloading_prefs_unittest.cc",
    "../browser/privacy/privacy_metrics_service_unittest.cc",
    "../browser/privacy_sandbox/privacy_sandbox_notice_service_unittest.cc",
    "../browser/privacy_sandbox/privacy_sandbox_policy_handler_unittest.cc",
    "../browser/privacy_sandbox/privacy_sandbox_service_impl_unittest.cc",
    "../browser/privacy_sandbox/privacy_sandbox_settings_delegate_unittest.cc",
    "../browser/profiles/gaia_info_update_service_unittest.cc",
    "../browser/profiles/incognito_mode_policy_handler_unittest.cc",
    "../browser/profiles/profile_attributes_storage_unittest.cc",
    "../browser/profiles/profile_downloader_unittest.cc",
    "../browser/profiles/profile_keyed_service_factory_unittest.cc",
    "../browser/profiles/profile_manager_unittest.cc",
    "../browser/profiles/profile_selections_unittest.cc",
    "../browser/profiles/profile_testing_helper.cc",
    "../browser/profiles/profile_testing_helper.h",
    "../browser/profiles/profiles_state_unittest.cc",
    "../browser/profiling_host/chrome_client_connection_manager_unittest.cc",
    "../browser/push_messaging/budget_database_unittest.cc",
    "../browser/push_messaging/push_messaging_app_identifier_unittest.cc",
    "../browser/push_messaging/push_messaging_notification_manager_unittest.cc",
    "../browser/push_messaging/push_messaging_refresher_unittest.cc",
    "../browser/push_messaging/push_messaging_service_unittest.cc",
    "../browser/reduce_accept_language/reduce_accept_language_service_unittest.cc",
    "../browser/resource_coordinator/tab_load_tracker_unittest.cc",
    "../browser/resources_util_unittest.cc",
    "../browser/search_engines/template_url_fetcher_unittest.cc",
    "../browser/search_engines/template_url_parser_unittest.cc",
    "../browser/search_engines/template_url_service_sync_unittest.cc",
    "../browser/search_engines/template_url_service_unittest.cc",
    "../browser/security_events/security_event_recorder_impl_unittest.cc",
    "../browser/segmentation_platform/segmentation_platform_config_unittest.cc",
    "../browser/segmentation_platform/segmentation_platform_profile_observer_unittest.cc",
    "../browser/segmentation_platform/segmentation_platform_service_factory_unittest.cc",
    "../browser/services_unittest.cc",
    "../browser/sessions/chrome_serialized_navigation_driver_unittest.cc",
    "../browser/sessions/session_common_utils_unittest.cc",
    "../browser/share/share_history_unittest.cc",
    "../browser/share/share_ranking_unittest.cc",
    "../browser/sharing/sharing_device_registration_impl_unittest.cc",
    "../browser/signin/account_consistency_mode_manager_unittest.cc",
    "../browser/signin/account_id_from_account_info_unittest.cc",
    "../browser/signin/chrome_device_id_helper_unittest.cc",
    "../browser/signin/chrome_signin_client_unittest.cc",
    "../browser/signin/chrome_signin_helper_unittest.cc",
    "../browser/signin/chrome_signin_proxying_url_loader_factory_unittest.cc",
    "../browser/signin/chrome_signin_url_loader_throttle_unittest.cc",
    "../browser/signin/e2e_tests/test_accounts_util_unittest.cc",
    "../browser/signin/header_modification_delegate_impl_unittest.cc",
    "../browser/signin/primary_account_policy_manager_unittest.cc",
    "../browser/signin/reauth_tab_helper_unittest.cc",
    "../browser/signin/signin_profile_attributes_updater_unittest.cc",
    "../browser/site_isolation/chrome_site_isolation_policy_unittest.cc",
    "../browser/ssl/daily_navigation_counter_unittest.cc",
    "../browser/ssl/https_first_mode_settings_tracker_unittest.cc",
    "../browser/ssl/security_state_tab_helper_unittest.cc",
    "../browser/ssl/ssl_config_service_manager_unittest.cc",
    "../browser/status_icons/status_icon_menu_model_unittest.cc",
    "../browser/status_icons/status_icon_unittest.cc",
    "../browser/status_icons/status_tray_unittest.cc",
    "../browser/storage/durable_storage_permission_context_unittest.cc",
    "../browser/storage_access_api/site_pair_cache_unittest.cc",
    "../browser/storage_access_api/storage_access_api_service_factory_unittest.cc",
    "../browser/storage_access_api/storage_access_api_service_impl_unittest.cc",
    "../browser/storage_access_api/storage_access_api_tab_helper_unittest.cc",
    "../browser/storage_access_api/storage_access_grant_permission_context_unittest.cc",
    "../browser/storage_access_api/storage_access_header_service_factory_unittest.cc",
    "../browser/storage_access_api/storage_access_header_service_unittest.cc",
    "../browser/subresource_filter/subresource_filter_history_observer_unittest.cc",
    "../browser/supervised_user/classify_url_navigation_throttle_unittest.cc",
    "../browser/supervised_user/supervised_user_browser_utils_unittest.cc",
    "../browser/supervised_user/supervised_user_google_auth_navigation_throttle_unittest.cc",
    "../browser/supervised_user/supervised_user_navigation_throttle_unittest.cc",
    "../browser/sync/session_sync_service_factory_unittest.cc",
    "../browser/sync/sessions/sync_sessions_web_contents_router_unittest.cc",
    "../browser/sync/sync_service_factory_unittest.cc",
    "../browser/sync/sync_startup_tracker_unittest.cc",
    "../browser/tab_group_sync/tab_group_sync_service_factory_unittest.cc",
    "../browser/top_level_storage_access_api/top_level_storage_access_permission_context_unittest.cc",
    "../browser/tracing/background_tracing_field_trial_unittest.cc",
    "../browser/tracing/chrome_background_tracing_metrics_provider_unittest.cc",
    "../browser/tracing/trace_event_system_stats_monitor_unittest.cc",
    "../browser/translate/fake_translate_agent.cc",
    "../browser/translate/fake_translate_agent.h",
    "../browser/translate/translate_service_unittest.cc",
    "../browser/trusted_vault/trusted_vault_encryption_keys_tab_helper_unittest.cc",
    "../browser/ui/autofill/autofill_client_provider_unittest.cc",
    "../browser/ui/autofill/autofill_suggestion_controller_unittest.cc",
    "../browser/ui/autofill/chrome_autofill_client_unittest.cc",
    "../browser/ui/chrome_select_file_policy_unittest.cc",
    "../browser/ui/file_system_access/file_system_access_dangerous_file_dialog_unittest.cc",
    "../browser/ui/file_system_access/file_system_access_permission_dialog_unittest.cc",
    "../browser/ui/file_system_access/file_system_access_restricted_directory_dialog_unittest.cc",
    "../browser/ui/file_system_access/file_system_access_ui_helpers_unittest.cc",
    "../browser/ui/login/login_handler_unittest.cc",
    "../browser/ui/page_info/page_info_unittest.cc",
    "../browser/ui/passwords/manage_passwords_state_unittest.cc",
    "../browser/ui/passwords/password_generation_popup_controller_impl_unittest.cc",
    "../browser/ui/passwords/settings/password_manager_porter_unittest.cc",
    "../browser/ui/safety_hub/menu_notification_service_unittest.cc",
    "../browser/ui/safety_hub/menu_notification_unittest.cc",
    "../browser/ui/safety_hub/safe_browsing_result_unittest.cc",
    "../browser/ui/search_engines/keyword_editor_controller_unittest.cc",
    "../browser/ui/sync/tab_contents_synced_tab_delegate_unittest.cc",
    "../browser/ui/webui/fileicon_source_unittest.cc",
    "../browser/ui/webui/log_web_ui_url_unittest.cc",
    "../browser/update_client/chrome_update_query_params_delegate_unittest.cc",
    "../browser/v8_compile_hints/v8_compile_hints_tab_helper_unittest.cc",
    "../browser/visibility_timer_tab_helper_unittest.cc",
    "../browser/visited_url_ranking/url_deduplication/search_engine_url_strip_handler_unittest.cc",
    "../browser/vr/vr_tab_helper_unittest.cc",
    "../browser/webid/federated_identity_account_keyed_permission_context_unittest.cc",
    "../browser/webid/federated_identity_api_permission_context_unittest.cc",
    "../browser/webid/federated_identity_auto_reauthn_permission_context_unittest.cc",
    "../browser/webid/federated_identity_identity_provider_registration_context_unittest.cc",
    "../browser/webid/federated_identity_identity_provider_signin_status_context_unittest.cc",
    "../browser/webid/federated_identity_permission_context_unittest.cc",
    "../browser/webid/identity_provider_permission_request_unittest.cc",
    "../common/chrome_content_client_unittest.cc",
    "../common/chrome_paths_unittest.cc",
    "../common/crash_keys_unittest.cc",
    "../common/google_url_loader_throttle_unittest.cc",
    "../common/ini_parser_unittest.cc",
    "../common/pref_names_util_unittest.cc",
    "../common/webui_util_unittest.cc",
    "../renderer/cart/commerce_hint_agent_unittest.cc",
    "../renderer/chrome_content_renderer_client_unittest.cc",
    "../renderer/chrome_render_frame_observer_unittest.cc",
    "../renderer/instant_restricted_id_cache_unittest.cc",
    "../renderer/media/flash_embed_rewrite_unittest.cc",
    "../renderer/net/net_error_helper_core_unittest.cc",
    "../renderer/v8_unwinder_unittest.cc",
    "../test/base/menu_model_test.cc",
    "../test/base/menu_model_test.h",
  ]

  if (build_with_tflite_lib) {
    sources += [
      "../browser/navigation_predictor/preloading_model_executor_unittest.cc",
    ]
  }
  if (!is_chromeos_ash) {
    sources += [
      "../browser/metrics/family_link_user_metrics_provider_unittest.cc",
      "../browser/signin/wait_for_network_callback_helper_chrome_unittest.cc",
    ]
  }

  if (!is_android) {
    sources += [
      # The test is disabled for Android. The respective functionality is currently not being used on
      # Android. We should enable this test when Android becomes supported.
      "../browser/content_extraction/inner_text_unittest.cc",
      "../browser/metrics/power/battery_discharge_reporter_unittest.cc",
      "../browser/page_load_metrics/observers/non_tab_webui_page_load_metrics_observer_unittest.cc",
      "../browser/performance_manager/metrics/metrics_provider_desktop_unittest.cc",
      "../browser/picture_in_picture/auto_pip_setting_helper_unittest.cc",
      "../browser/picture_in_picture/auto_pip_setting_overlay_view_unittest.cc",
      "../browser/picture_in_picture/auto_pip_setting_view_unittest.cc",
      "../browser/picture_in_picture/picture_in_picture_occlusion_tracker_unittest.cc",
      "../browser/policy/messaging_layer/util/reporting_server_connector_unittest.cc",
      "../browser/screen_ai/screen_ai_install_state_unittest.cc",
      "../browser/search_engine_choice/search_engine_choice_dialog_service_unittest.cc",
      "../browser/segmentation_platform/client_util/local_tab_handler_unittest.cc",
      "../browser/site_protection/site_protection_metrics_observer_unittest.cc",
      "../browser/ssl/generated_https_first_mode_pref_unittest.cc",
      "../browser/ui/autofill/autofill_popup_controller_impl_unittest.cc",
      "../browser/ui/download/download_bubble_row_list_view_info_unittest.cc",
      "../browser/ui/download/download_bubble_row_view_info_unittest.cc",
      "../browser/ui/download/download_bubble_security_view_info_unittest.cc",
      "../browser/ui/exclusive_access/exclusive_access_permission_manager_unittest.cc",
      "../browser/ui/passwords/password_cross_domain_confirmation_popup_controller_impl_unittest.cc",
      "../browser/ui/plus_addresses/plus_address_creation_controller_desktop_unittest.cc",
      "../browser/ui/safety_hub/card_data_helper_unittest.cc",
      "../browser/ui/safety_hub/notification_permission_review_service_unittest.cc",
      "../browser/ui/safety_hub/safety_hub_service_unittest.cc",
      "../browser/ui/user_education/recent_session_policy_unittest.cc",
      "../browser/user_education/browser_feature_promo_storage_service_unittest.cc",
      "../browser/user_education/recent_session_tracker_unittest.cc",
      "../browser/user_education/user_education_configuration_provider_unittest.cc",
      "../browser/webapps/installable/installable_utils_unittest.cc",
    ]
  }

  if (is_linux) {
    sources += [ "../browser/metrics/pressure/pressure_metrics_unittest.cc" ]
  }

  if (is_linux || is_chromeos) {
    sources +=
        [ "../browser/policy/browser_dm_token_storage_linux_unittest.cc" ]
  }

  if (is_chromeos_ash) {
    sources += [
      "../browser/metrics/chrome_metrics_service_client_ash_unittest.cc",
      "../browser/metrics/chromeos_metrics_provider_unittest.cc",
      "../browser/metrics/structured/arena_event_buffer_unittest.cc",
      "../browser/metrics/structured/ash_structured_metrics_recorder_unittest.cc",
      "../browser/metrics/structured/storage_manager_unittest.cc",
      "../browser/policy/messaging_layer/upload/file_upload_impl_unittest.cc",
      "../browser/prefs/chrome_pref_service_factory_ash_unittest.cc",
      "../browser/webauthn/unexportable_key_utils_chromeos_unittest.cc",
      "../renderer/ash_merge_session_loader_throttle_unittest.cc",
      "../test/base/ash/v8_unit_test.cc",
      "../test/base/ash/v8_unit_test.h",
    ]
  }

  if (enable_downgrade_processing) {
    sources += [
      "../browser/downgrade/snapshot_file_collector_unittest.cc",
      "../browser/downgrade/snapshot_manager_unittest.cc",
      "../browser/downgrade/user_data_downgrade_unittest.cc",
    ]
  }

  if (enable_chrome_notifications) {
    sources += [
      "../browser/notifications/notification_system_observer_unittest.cc",
      "../browser/notifications/notification_ui_manager_unittest.cc",
      "../browser/notifications/popups_only_ui_controller_unittest.cc",
    ]
  }

  if (enable_webui_certificate_viewer) {
    sources += [ "../common/net/x509_certificate_model_unittest.cc" ]
  }

  if (toolkit_views) {
    sources += [
      "../browser/bookmarks/bookmark_expanded_state_tracker_unittest.cc",
      "../browser/page_load_metrics/observers/side_search_page_load_metrics_observer_unittest.cc",
      "../browser/ui/side_search/side_search_side_contents_helper_unittest.cc",
      "../browser/ui/side_search/side_search_tab_contents_helper_unittest.cc",
    ]
  }

  if (enable_webui_tab_strip) {
    sources += [
      "../browser/ui/views/frame/webui_tab_strip_container_view_unittest.cc",
      "../browser/ui/views/toolbar/webui_tab_counter_button_unittest.cc",
      "../browser/ui/webui/tab_strip/tab_strip_page_handler_unittest.cc",
      "../browser/ui/webui/tab_strip/tab_strip_ui_layout_unittest.cc",
      "../browser/ui/webui/tab_strip/thumbnail_tracker_unittest.cc",
    ]
  }

  # Support v8_unwinder_unittest on Android.
  if (is_android && enable_arm_cfi_table) {
    configs -= [ "//build/config/compiler:default_symbols" ]
    if (symbol_level == 2) {
      configs += [ "//build/config/compiler:symbols" ]
    } else {
      configs += [ "//build/config/compiler:minimal_symbols" ]
    }
    add_unwind_tables_in_apk = true
  }

  configs += [ "//build/config:precompiled_headers" ]
  configs += [ ":disable_thinlto_cache_flags" ]

  data_deps = [
    "//chrome/test/data/media/engagement/preload:generate_preload_list",
    "//chrome/test/data/media/engagement/preload:test_data",
    "//testing/buildbot/filters:unit_tests_filters",
    "//third_party/perfetto/protos/perfetto/config/chrome:scenario_descriptor",
  ]

  data = [
    "$root_gen_dir/third_party/perfetto/protos/perfetto/config/chrome/scenario_config.descriptor",
    "../browser/flag-metadata.json",
    "../browser/flag-never-expire-list.json",
    "//base/test/data/",
    "//chrome/test/data/",
    "//components/test/data/",
    "//extensions/test/data/",
    "//google_apis/test/data/",
    "//net/tools/testserver/",
    "//third_party/pywebsocket3/src/mod_pywebsocket/",
    "//tools/metrics/histograms/enums.xml",
    "//tools/metrics/histograms/metadata/sync/enums.xml",
  ]

  if (build_with_tflite_lib) {
    data +=
        [ "../browser/navigation_predictor/test/preloading_heuristics.tflite" ]
  }

  if (is_android) {
    # Trim data specifically to what is used by unit tests on Android.
    data += [
      "data/android/google.png",
      "data/file_select_helper/",
      "data/offline_pages/",
      "data/optimization_guide/",
      "data/osdd/",
      "data/public_offline_pages/",

      # webapk_installer_unittest
      "data/banners/image-512px-corp.png",
      "data/nostore.html",
      "data/simple.html",
      "data/title1.html",
    ]
  } else {
    data += [
      "data/",
      "//tools/metrics/actions/actions.xml",
      "//tools/metrics/histograms/metadata/feature_engagement/histograms.xml",
      "//tools/metrics/histograms/metadata/user_education/histograms.xml",
    ]
  }

  if (is_android) {
    data += [
      "$root_gen_dir/chrome/android/chrome_apk_paks/chrome_100_percent.pak",
      "$root_gen_dir/chrome/android/chrome_apk_paks/locales/en-US.pak",
      "$root_gen_dir/chrome/android/chrome_apk_paks/resources.pak",
    ]
  }
  if (is_linux || is_chromeos || is_win) {
    data_deps += [ "//chrome:packed_resources" ]
  }
  defines = []

  public_deps = [ "//chrome/browser/media/webrtc" ]
  deps = [
    ":test_support",
    ":test_support_unit",
    "//base:base_stack_sampling_profiler_test_util",
    "//base/test:proto_test_support",
    "//base/test:test_support",
    "//build:chromeos_buildflags",
    "//chrome:dependencies",
    "//chrome:resources",
    "//chrome:strings",
    "//chrome/app:command_ids",
    "//chrome/app/theme:chrome_unscaled_resources_grit",
    "//chrome/app/vector_icons",
    "//chrome/browser:active_use_util",
    "//chrome/browser:buildflags",
    "//chrome/browser:font_pref",
    "//chrome/browser:primitives",
    "//chrome/browser/accessibility:utils",
    "//chrome/browser/ai",
    "//chrome/browser/apps:icon_standardizer",
    "//chrome/browser/apps:user_type_filter",
    "//chrome/browser/autofill",
    "//chrome/browser/bitmap_fetcher",
    "//chrome/browser/bitmap_fetcher:unit_tests",
    "//chrome/browser/breadcrumbs",
    "//chrome/browser/breadcrumbs:unit_tests",
    "//chrome/browser/browsing_data:constants",
    "//chrome/browser/crash_upload_list:unit_tests",
    "//chrome/browser/devtools",
    "//chrome/browser/dips:unit_tests",
    "//chrome/browser/favicon",
    "//chrome/browser/feedback",
    "//chrome/browser/feedback:feedback_impl",
    "//chrome/browser/fingerprinting_protection",
    "//chrome/browser/first_party_sets",
    "//chrome/browser/google:unit_tests",
    "//chrome/browser/ip_protection:unit_tests",
    "//chrome/browser/media/prefs",
    "//chrome/browser/media/prefs:unit_tests",
    "//chrome/browser/media/router",
    "//chrome/browser/media/router:media_router_feature",
    "//chrome/browser/media/router:unittests",
    "//chrome/browser/media/router/discovery/access_code:access_code_cast_feature",
    "//chrome/browser/metrics/structured",
    "//chrome/browser/net:key_pinning_proto",
    "//chrome/browser/net:probe_message_proto",
    "//chrome/browser/new_tab_page/chrome_colors:generate_chrome_colors_info",
    "//chrome/browser/new_tab_page/chrome_colors:generate_colors_info",
    "//chrome/browser/notifications:unit_tests",
    "//chrome/browser/payments:unittests",
    "//chrome/browser/permissions",
    "//chrome/browser/permissions:unit_tests",
    "//chrome/browser/persisted_state_db:persisted_state_db",
    "//chrome/browser/policy:test_support",
    "//chrome/browser/policy/messaging_layer/proto:log_upload_event_proto",
    "//chrome/browser/policy/messaging_layer/storage_selector",
    "//chrome/browser/preloading/prerender:unit_tests",
    "//chrome/browser/privacy_budget:unit_tests",
    "//chrome/browser/profile_resetter:profile_reset_report_proto",
    "//chrome/browser/profiling_host",
    "//chrome/browser/push_messaging:budget_proto",
    "//chrome/browser/request_header_integrity:unit_tests",
    "//chrome/browser/safe_browsing:advanced_protection",
    "//chrome/browser/safe_browsing:metrics_collector",
    "//chrome/browser/safe_browsing:verdict_cache_manager_factory",
    "//chrome/browser/search",
    "//chrome/browser/search_engines",
    "//chrome/browser/segmentation_platform:test_utils",
    "//chrome/browser/share",
    "//chrome/browser/storage_access_api",
    "//chrome/browser/supervised_user:test_support",
    "//chrome/browser/sync",
    "//chrome/browser/sync_file_system/drive_backend:sync_file_system_drive_proto",
    "//chrome/browser/top_level_storage_access_api:permissions",
    "//chrome/browser/tpcd/experiment:unit_tests",
    "//chrome/browser/tpcd/heuristics:unit_tests",
    "//chrome/browser/ui:browser_element_identifiers",
    "//chrome/browser/ui:test_support",
    "//chrome/browser/ui:ui_features",
    "//chrome/browser/ui/autofill/payments",
    "//chrome/browser/ui/autofill/payments:unit_tests",
    "//chrome/browser/ui/blocked_content:unit_tests",
    "//chrome/browser/ui/browser_window",
    "//chrome/browser/ui/color:color_headers",
    "//chrome/browser/ui/find_bar:unit_tests",
    "//chrome/browser/updates/announcement_notification:unit_tests",
    "//chrome/browser/web_share_target:unit_tests",
    "//chrome/common:test_support",
    "//chrome/common:version_header",
    "//chrome/common/notifications",
    "//chrome/common/privacy_budget:test_support",
    "//chrome/common/privacy_budget:unit_tests",
    "//chrome/common/profiler:unit_tests",
    "//chrome/common/themes:autogenerated_theme_util",
    "//chrome/common/themes:unit_tests",
    "//chrome/renderer/companion/visual_query:unit_tests",
    "//chrome/services/file_util:unit_tests",
    "//chrome/services/on_device_translation:unit_tests",
    "//components/account_id",
    "//components/affiliations/core/browser:test_support",
    "//components/assist_ranker/proto",
    "//components/autofill/content/browser:test_support",
    "//components/background_sync",
    "//components/blocked_content",
    "//components/blocklist/opt_out_blocklist",
    "//components/bookmarks/browser",
    "//components/bookmarks/common",
    "//components/bookmarks/managed",
    "//components/breadcrumbs/core",
    "//components/breadcrumbs/core:status",
    "//components/browser_sync",
    "//components/browsing_data/content",
    "//components/browsing_data/content:test_support",
    "//components/browsing_data/core",
    "//components/browsing_topics",
    "//components/captive_portal/content",
    "//components/captive_portal/core:buildflags",
    "//components/certificate_transparency",
    "//components/certificate_transparency:proto",
    "//components/commerce/core:commerce_constants",
    "//components/commerce/core:commerce_heuristics_data",
    "//components/commerce/core:feature_list",
    "//components/commerce/core:persisted_state_db_content_proto",
    "//components/commerce/core:shopping_service",
    "//components/commerce/core:shopping_service_test_support",
    "//components/component_updater:test_support",
    "//components/component_updater/installer_policies:installer_policies_no_content_deps",
    "//components/content_settings/browser",
    "//components/content_settings/browser:test_support",
    "//components/content_settings/browser/ui",
    "//components/content_settings/core/browser:test_support",
    "//components/content_settings/core/test:test_support",
    "//components/country_codes",
    "//components/custom_handlers",
    "//components/custom_handlers:test_support",
    "//components/data_sharing:test_support",
    "//components/data_sharing/internal",
    "//components/data_sharing/public",
    "//components/device_reauth",
    "//components/device_signals/core/browser",
    "//components/download/public/background_service/test:test_support",
    "//components/drive",
    "//components/drive:test_support",
    "//components/embedder_support",
    "//components/encrypted_messages",
    "//components/encrypted_messages:encrypted_message_proto",
    "//components/enterprise/browser/identifiers",
    "//components/enterprise/common/proto:connectors_proto",
    "//components/enterprise/common/proto:extensions_workflow_events_proto",
    "//components/enterprise/common/proto:legacy_tech_events_proto",
    "//components/favicon/core/test:test_support",
    "//components/feature_engagement/public",
    "//components/feed/core/v2:feed_core_stubs",
    "//components/feed/core/v2:feed_core_v2",
    "//components/feed/core/v2:test_helpers",
    "//components/feed/mojom:mojo_bindings",
    "//components/feedback",
    "//components/feedback/redaction_tool",
    "//components/fingerprinting_protection_filter/browser",
    "//components/fingerprinting_protection_filter/common",
    "//components/flags_ui",
    "//components/flags_ui:test_support",
    "//components/history/content/browser",
    "//components/history/core/common",
    "//components/history_clusters/core",
    "//components/history_clusters/core:test_support",
    "//components/history_embeddings",
    "//components/image_fetcher/core",
    "//components/image_fetcher/core:test_support",
    "//components/infobars/content",
    "//components/input",
    "//components/invalidation",
    "//components/invalidation/impl",
    "//components/invalidation/impl:test_support",
    "//components/ip_protection:browser",
    "//components/ip_protection:ip_protection",
    "//components/language/core/browser",
    "//components/lens",
    "//components/leveldb_proto:test_support",
    "//components/live_caption:constants",
    "//components/lookalikes/core",
    "//components/lookalikes/core:safety_tips",
    "//components/media_device_salt",
    "//components/media_effects:media_effects",
    "//components/media_router/common/providers/cast/channel",
    "//components/media_router/common/providers/cast/channel:test_support",
    "//components/memory_pressure:test_support",
    "//components/metrics/structured",
    "//components/metrics/structured/lib",
    "//components/mirroring:mirroring_tests",
    "//components/nacl/common:buildflags",
    "//components/no_state_prefetch/browser",
    "//components/no_state_prefetch/common",
    "//components/offline_items_collection/core/test_support",
    "//components/offline_pages/task:test_support",
    "//components/onc",
    "//components/optimization_guide/content/browser",
    "//components/optimization_guide/content/renderer",
    "//components/optimization_guide/core",
    "//components/optimization_guide/core:bloomfilter",
    "//components/optimization_guide/core:test_support",
    "//components/origin_trials:browser",
    "//components/os_crypt/sync:test_support",
    "//components/page_content_annotations/core",
    "//components/page_content_annotations/core:test_support",
    "//components/page_info",
    "//components/page_load_metrics/browser",
    "//components/page_load_metrics/browser:test_support",
    "//components/page_load_metrics/common",
    "//components/page_load_metrics/common:test_support",
    "//components/page_load_metrics/google/browser",
    "//components/paint_preview/common/mojom",
    "//components/password_manager/content/browser",
    "//components/password_manager/core/browser:test_support",
    "//components/password_manager/core/browser/export",
    "//components/password_manager/core/browser/features:password_features",
    "//components/password_manager/core/browser/import:csv",
    "//components/password_manager/core/browser/import:importer",
    "//components/payments/content",
    "//components/payments/content:test_support",
    "//components/payments/content:utils",
    "//components/pdf/common:constants",
    "//components/performance_manager",
    "//components/performance_manager/public/mojom",
    "//components/performance_manager/test_support:test_support_common",
    "//components/plus_addresses",
    "//components/plus_addresses:test_support",
    "//components/plus_addresses/metrics",
    "//components/plus_addresses/settings:test_support",
    "//components/policy:generated",
    "//components/policy/core/browser:test_support",
    "//components/policy/test_support:unittests",
    "//components/privacy_sandbox:privacy_sandbox",
    "//components/privacy_sandbox:privacy_sandbox_notice_constants",
    "//components/privacy_sandbox:privacy_sandbox_notice_storage",
    "//components/privacy_sandbox:privacy_sandbox_prefs",
    "//components/privacy_sandbox:tpcd",
    "//components/privacy_sandbox:tracking_protection_onboarding",
    "//components/privacy_sandbox:tracking_protection_prefs",
    "//components/privacy_sandbox:tracking_protection_settings",
    "//components/privacy_sandbox/privacy_sandbox_attestations",
    "//components/privacy_sandbox/privacy_sandbox_attestations:metrics",
    "//components/privacy_sandbox/privacy_sandbox_attestations:test_support",
    "//components/privacy_sandbox/privacy_sandbox_attestations/proto:proto",
    "//components/proxy_config",
    "//components/qr_code_generator:bitmap_generator",
    "//components/query_parser",
    "//components/reading_list/core",
    "//components/reading_list/core:test_support",
    "//components/reading_list/features:flags",
    "//components/reduce_accept_language/browser",
    "//components/reduce_accept_language/browser:test_support",
    "//components/renderer_context_menu",
    "//components/reporting/client:report_queue",
    "//components/reporting/client:report_queue_configuration",
    "//components/reporting/client:report_queue_provider",
    "//components/reporting/client:test_support",
    "//components/reporting/encryption:decryption",
    "//components/reporting/encryption:primitives",
    "//components/reporting/encryption:test_support",
    "//components/reporting/encryption:testing_primitives",
    "//components/reporting/encryption:verification",
    "//components/reporting/proto:configuration_file_proto",
    "//components/reporting/proto:upload_tracker_proto",
    "//components/reporting/resources:resource_manager",
    "//components/reporting/storage:storage_uploader_interface",
    "//components/reporting/storage:test_support",
    "//components/reporting/util:backoff_settings",
    "//components/reporting/util:status_macros",
    "//components/reporting/util:task_runner_context",
    "//components/reporting/util:test_callbacks_support",
    "//components/resources",
    "//components/safe_browsing:buildflags",
    "//components/safe_browsing/content/browser",
    "//components/safe_browsing/content/browser:client_side_detection",
    "//components/safe_browsing/content/browser:client_side_detection_images_cache",
    "//components/safe_browsing/content/browser:client_side_detection_service",
    "//components/safe_browsing/content/browser/password_protection",
    "//components/safe_browsing/content/browser/password_protection:mock_password_protection",
    "//components/safe_browsing/content/browser/web_ui",
    "//components/safe_browsing/content/common:interfaces",
    "//components/safe_browsing/content/common:interfaces_shared_cpp_sources",
    "//components/safe_browsing/core/browser:browser",
    "//components/safe_browsing/core/browser:referrer_chain_provider",
    "//components/safe_browsing/core/browser:verdict_cache_manager",
    "//components/safe_browsing/core/browser/db",
    "//components/safe_browsing/core/browser/db:test_database_manager",
    "//components/safe_browsing/core/browser/db:v4_local_database_manager",
    "//components/safe_browsing/core/browser/sync",
    "//components/safe_browsing/core/common",
    "//components/safe_browsing/core/common/proto:client_model_proto",
    "//components/safe_browsing/core/common/proto:csd_proto",
    "//components/safe_search_api",
    "//components/safe_search_api:test_support",
    "//components/saved_tab_groups:core",
    "//components/schema_org/common:improved_mojom",
    "//components/search",
    "//components/search_engines",
    "//components/search_provider_logos",
    "//components/security_interstitials/content:proto",
    "//components/security_interstitials/content:security_interstitial_page",
    "//components/security_interstitials/core:unsafe_resource",
    "//components/security_state/content",
    "//components/segmentation_platform/embedder",
    "//components/segmentation_platform/embedder/default_model",
    "//components/segmentation_platform/embedder/default_model:default_model_test_base",
    "//components/segmentation_platform/internal:internal",
    "//components/segmentation_platform/public",
    "//components/segmentation_platform/public:test_support",
    "//components/send_tab_to_self",
    "//components/services/app_service",
    "//components/services/paint_preview_compositor/public/mojom",
    "//components/services/patch/content",
    "//components/services/unzip/content",
    "//components/session_proto_db:session_proto_db",
    "//components/sharing_message:buildflags",
    "//components/sharing_message:test_support",
    "//components/sharing_message:unit_tests",
    "//components/sharing_message/proto",
    "//components/sharing_message/shared_clipboard",
    "//components/sharing_message/web_push",
    "//components/site_engagement/content",
    "//components/site_engagement/core",
    "//components/site_isolation",
    "//components/spellcheck:buildflags",
    "//components/spellcheck/browser",
    "//components/spellcheck/common",
    "//components/spellcheck/common:spellcheck_result",
    "//components/spellcheck/renderer",
    "//components/sqlite_proto",
    "//components/strings",
    "//components/subresource_filter/core/browser",
    "//components/subresource_filter/core/browser:test_support",
    "//components/supervised_user/core/browser",
    "//components/supervised_user/core/browser:fetcher",
    "//components/supervised_user/core/browser/proto",
    "//components/supervised_user/core/common",
    "//components/supervised_user/core/common",
    "//components/supervised_user/core/common:buildflags",
    "//components/supervised_user/core/common:buildflags",
    "//components/sync:test_support",
    "//components/sync_bookmarks",
    "//components/sync_device_info:test_support",
    "//components/sync_sessions:test_support",
    "//components/sync_user_events:test_support",
    "//components/tab_groups",
    "//components/tpcd/metadata/browser",
    "//components/tpcd/metadata/browser:prefs",
    "//components/tpcd/metadata/browser:test_support",
    "//components/tpcd/metadata/common/proto",
    "//components/tracing:background_tracing_utils",
    "//components/tracing:startup_tracing",
    "//components/translate/core/browser:test_support",
    "//components/ukm/content",
    "//components/unexportable_keys",
    "//components/unexportable_keys:test_support",
    "//components/unified_consent",
    "//components/url_formatter/spoof_checks/common_words:common",
    "//components/url_formatter/spoof_checks/common_words:common_words_dafsa",
    "//components/url_formatter/spoof_checks/top_domains:generate_top_domains_test_trie",
    "//components/url_formatter/spoof_checks/top_domains:test_top_bucket_domains",
    "//components/url_formatter/spoof_checks/top_domains:test_top_bucket_domains_header",
    "//components/user_education/common",
    "//components/user_education/test",
    "//components/user_manager",
    "//components/user_prefs/test:test_support",
    "//components/variations:test_support",
    "//components/variations/service:service",
    "//components/vector_icons",
    "//components/version_info:generate_version_info",
    "//components/visited_url_ranking/public",
    "//components/visited_url_ranking/public:test_support",
    "//components/webapps/common",
    "//components/webauthn/core/browser",
    "//components/webauthn/core/browser:passkey_model",
    "//components/webrtc",
    "//content/public/app",
    "//content/test:test_support",
    "//crypto:test_support",
    "//device/bluetooth:mocks",
    "//device/fido",
    "//device/fido:test_support",
    "//gin",
    "//google_apis",
    "//google_apis/gcm",
    "//gpu:test_support",
    "//media:test_support",
    "//mojo/public/cpp/bindings",
    "//net",
    "//net:test_support",
    "//ppapi/buildflags",
    "//services/cert_verifier:lib",
    "//services/data_decoder/public/cpp:test_support",
    "//services/device/public/cpp:device_features",
    "//services/device/public/cpp:test_support",
    "//services/network:test_support",
    "//services/network/public/cpp",
    "//services/network/public/mojom",
    "//services/preferences/public/cpp/tracked",
    "//services/preferences/public/cpp/tracked:test_support",
    "//services/preferences/public/mojom",
    "//services/resource_coordinator/public/cpp/memory_instrumentation:browser",
    "//services/service_manager/public/cpp/test:test_support",
    "//services/video_effects/test:test_support",
    "//skia",
    "//storage/browser:test_support",
    "//testing/gmock",
    "//testing/gtest",
    "//testing/perf:unit_tests",
    "//third_party/abseil-cpp:absl",
    "//third_party/blink/public/common/privacy_budget:test_support",
    "//third_party/icu",
    "//third_party/leveldatabase",
    "//third_party/libaddressinput",
    "//third_party/libphonenumber",
    "//third_party/metrics_proto",
    "//third_party/microsoft_webauthn",
    "//third_party/re2",
    "//third_party/rust/fend_core/v1/wrapper:unit_tests",
    "//third_party/webrtc_overrides:webrtc_component",
    "//third_party/widevine/cdm:headers",
    "//third_party/zlib/google:compression_utils",
    "//third_party/zlib/google:zip",
    "//ui/base:test_support",
    "//ui/base/clipboard:clipboard_test_support",
    "//ui/color:color",
    "//ui/color:mixers",
    "//ui/color/dynamic_color",
    "//ui/display:test_support",
    "//ui/events:gesture_detection",
    "//ui/events:test_support",
    "//ui/gfx:test_support",
    "//ui/gl",
    "//ui/native_theme:test_support",
    "//ui/resources",
    "//ui/shell_dialogs",
    "//ui/strings:app_locale_settings_grit",
    "//ui/strings:ui_strings_grit",
    "//ui/webui",
    "//v8",

    # Duplicate these tests here because PathService has more providers in
    # unit_tests than in base_unittests.
    "//base:path_service_unittest",
  ]

  if (is_chromeos) {
    sources += [ "../browser/device_reauth/chromeos/device_authenticator_chromeos_unittest.cc" ]

    deps += [
      "//chrome/browser/chromeos/mahi",
      "//chrome/browser/chromeos/mahi/test:test_support",
      "//chrome/browser/chromeos/office_web_app:office_web_app",
      "//chrome/browser/chromeos/policy/dlp",
      "//chrome/browser/chromeos/policy/dlp/test:test_support",
      "//chromeos/components/kiosk:test_support",
      "//chromeos/components/mgs:test_support",
      "//chromeos/dbus/tpm_manager:tpm_manager",
    ]
  }

  if (enable_server_based_recognition) {
    deps += [ "//chrome/services/speech/internal:unit_tests" ]
  }

  if (enable_compose) {
    sources += [
      "../browser/compose/chrome_compose_client_unittest.cc",
      "../browser/compose/compose_enabling_unittest.cc",
      "../browser/compose/compose_text_usage_logger_unittest.cc",
      "../browser/compose/proactive_nudge_tracker_unittest.cc",
      "../browser/ui/views/compose/compose_dialog_view_unittest.cc",
      "../common/compose/type_conversions_unittest.cc",
    ]
    deps += [
      "//chrome/common/compose",
      "//components/compose/core/browser:browser",
      "//components/compose/core/browser:features",
      "//components/optimization_guide/core",
      "//components/optimization_guide/proto:optimization_guide_proto",
    ]
  }

  if (is_win || is_mac) {
    sources += [
      "../browser/enterprise/platform_auth/platform_auth_navigation_throttle_unittest.cc",
      "../browser/enterprise/platform_auth/platform_auth_provider_manager_unittest.cc",
    ]

    deps += [ "//chrome/browser/enterprise/platform_auth:test_utils" ]
  }

  if (is_win || is_mac) {
    sources += [ "../browser/updater/browser_updater_client_unittest.cc" ]
    deps += [
      "//chrome/browser/updater:browser_updater_client",
      "//chrome/updater:browser_sources",
    ]
  }

  if (is_win) {
    assert(toolkit_views)
    sources += [
      "../browser/accessibility/live_caption/live_caption_unavailability_notifier_unittest.cc",
      "../browser/chrome_browser_main_win_unittest.cc",
      "../browser/chrome_process_singleton_win_unittest.cc",
      "../browser/device_reauth/win/device_authenticator_win_unittest.cc",
      "../browser/enterprise/platform_auth/cloud_ap_provider_win_unittest.cc",
      "../browser/enterprise/platform_auth/cloud_ap_utils_win_unittest.cc",
      "../browser/install_verification/win/module_info_unittest.cc",
      "../browser/install_verification/win/module_list_unittest.cc",
      "../browser/install_verification/win/module_verification_test.cc",
      "../browser/install_verification/win/module_verification_test.h",
      "../browser/media/cdm_document_service_impl_test.cc",
      "../browser/media/media_foundation_service_monitor_unittest.cc",
      "../browser/metrics/antivirus_metrics_provider_win_unittest.cc",
      "../browser/notifications/notification_platform_bridge_win_unittest.cc",
      "../browser/notifications/win/fake_notification_image_retainer.cc",
      "../browser/notifications/win/fake_notification_image_retainer.h",
      "../browser/notifications/win/notification_helper_launches_chrome_unittest.cc",
      "../browser/notifications/win/notification_launch_id_unittest.cc",
      "../browser/notifications/win/notification_template_builder_unittest.cc",
      "../browser/performance_monitor/metric_evaluator_helper_win_unittest.cc",
      "../browser/policy/browser_dm_token_storage_win_unittest.cc",
      "../browser/process_singleton_win_unittest.cc",
      "../browser/profiles/profile_shortcut_manager_unittest_win.cc",
      "../browser/shell_integration_win_unittest.cc",
      "../browser/ui/startup/credential_provider_signin_info_fetcher_win_unittest.cc",
      "../browser/ui/views/frame/windows_caption_button_unittest.cc",
      "../browser/ui/views/uninstall_view_unittest.cc",
      "../browser/ui/webui/version/version_handler_win_unittest.cc",
      "../browser/upgrade_detector/get_installed_version_win_unittest.cc",
      "../browser/upgrade_detector/registry_monitor_unittest.cc",
      "../browser/webshare/win/fake_buffer_unittest.cc",
      "../browser/webshare/win/fake_data_transfer_manager_interop_unittest.cc",
      "../browser/webshare/win/fake_data_transfer_manager_unittest.cc",
      "../browser/webshare/win/fake_data_writer_factory_unittest.cc",
      "../browser/webshare/win/fake_random_access_stream_unittest.cc",
      "../browser/webshare/win/fake_storage_file_statics_unittest.cc",
      "../browser/webshare/win/fake_uri_runtime_class_factory_unittest.cc",
      "../browser/webshare/win/share_operation_unittest.cc",
      "../browser/webshare/win/show_share_ui_for_window_operation_unittest.cc",
      "../browser/win/chrome_elf_init_unittest.cc",
      "../browser/win/jumplist_file_util_unittest.cc",
      "../browser/win/jumplist_update_util_unittest.cc",
      "../browser/win/remove_app_compat_entries_unittest.cc",
      "../browser/win/uninstallation_via_os_settings_unittest.cc",
      "../common/chrome_constants_win_unittest.cc",
      "../common/conflicts/module_watcher_win_unittest.cc",
      "../common/conflicts/remote_module_watcher_win_unittest.cc",
      "../common/win/delay_load_failure_hook_unittest.cc",
      "../common/win/delay_load_notify_hook_unittest.cc",
    ]

    data += [ "$root_out_dir/chrome.exe" ]

    data_deps += [
      "//chrome",
      "//chrome/browser/safe_browsing/incident_reporting/verifier_test:verifier_test_dll_1",
      "//chrome/browser/safe_browsing/incident_reporting/verifier_test:verifier_test_dll_2",
      "//chrome/notification_helper",
    ]

    deps += [
      "//chrome:other_version",
      "//chrome:packed_resources_integrity_header",
      "//chrome//services/util_win:unit_tests",
      "//chrome/app:chrome_dll_resources",
      "//chrome/app:win_unit_tests",
      "//chrome/browser:chrome_process_finder",
      "//chrome/browser/shortcuts",
      "//chrome/browser/win/conflicts:unit_tests",
      "//chrome/chrome_elf:constants",
      "//chrome/common/notifications",
      "//chrome/install_static:install_static_util",
      "//chrome/installer/setup:lib",
      "//chrome/installer/util:strings",
      "//chrome/installer/util:with_no_strings",
      "//chrome/services/util_win:lib",
      "//chrome/test:credential_provider_test_utils",
      "//chrome/updater:browser_sources",
      "//third_party/iaccessible2",
      "//third_party/isimpledom",
      "//third_party/wtl",
      "//ui/events/devices:test_support",
      "//ui/resources",
    ]

    if (enable_platform_experience) {
      deps += [ "//chrome/browser/platform_experience/win:unit_tests" ]
    }

    ldflags = [
      "/DELAYLOAD:api-ms-win-core-winrt-error-l1-1-0.dll",
      "/DELAYLOAD:api-ms-win-core-winrt-l1-1-0.dll",
      "/DELAYLOAD:api-ms-win-core-winrt-string-l1-1-0.dll",
    ]

    libs = [
      "comsupp.lib",
      "oleacc.lib",
      "rpcrt4.lib",
      "runtimeobject.lib",
      "urlmon.lib",
      "winmm.lib",
    ]

    if (is_chrome_branded) {
      sources += [
        "../browser/component_updater/recovery_improved_component_unittest.cc",
      ]

      data_deps +=
          [ "//components/update_client:recovery_component_tests_bundle_data" ]
    }
  }

  if (is_chrome_branded) {
    deps += [ "//chrome/browser/nearby_sharing/internal/icons:vector_icons" ]
  }

  if (is_mac) {
    sources += [
      "../../testing/gtest_mac_unittest.mm",
      "../app_shim/app_shim_controller_unittest.mm",
      "../browser/app_controller_mac_unittest.mm",
      "../browser/apps/app_shim/mach_bootstrap_acceptor_unittest.mm",
      "../browser/chrome_browser_application_mac_unittest.mm",
      "../browser/device_reauth/mac/device_authenticator_mac_unittest.mm",
      "../browser/global_keyboard_shortcuts_mac_unittest.mm",
      "../browser/mac/auth_session_request_unittest.mm",
      "../browser/mac/code_sign_clone_manager_unittest.mm",
      "../browser/mac/exception_processor_unittest.mm",
      "../browser/mac/metrics_unittest.mm",
      "../browser/notifications/mac/notification_dispatcher_mojo_unittest.cc",
      "../browser/notifications/mac/notification_platform_bridge_mac_unittest.cc",
      "../browser/notifications/mac/notification_utils_unittest.cc",
      "../browser/notifications/mac/stub_notification_dispatcher_mac.cc",
      "../browser/notifications/mac/stub_notification_dispatcher_mac.h",
      "../browser/policy/browser_dm_token_storage_mac_unittest.cc",
      "../browser/renderer_host/chrome_render_widget_host_view_mac_history_swiper_unit_test.mm",
      "../browser/ui/cocoa/applescript/apple_event_util_unittest.mm",
      "../browser/ui/cocoa/bookmarks/bookmark_menu_bridge_unittest.mm",
      "../browser/ui/cocoa/bookmarks/bookmark_menu_cocoa_controller_unittest.mm",
      "../browser/ui/cocoa/confirm_quit_panel_controller_unittest.mm",
      "../browser/ui/cocoa/find_pasteboard_unittest.mm",
      "../browser/ui/cocoa/first_run_dialog_controller_unittest.mm",
      "../browser/ui/cocoa/history_menu_bridge_unittest.mm",
      "../browser/ui/cocoa/history_menu_cocoa_controller_unittest.mm",
      "../browser/ui/cocoa/history_overlay_controller_unittest.mm",
      "../browser/ui/cocoa/main_menu_builder_unittest.mm",
      "../browser/ui/cocoa/profiles/profile_menu_controller_unittest.mm",
      "../browser/ui/cocoa/renderer_context_menu/render_view_context_menu_mac_unittest.mm",
      "../browser/ui/cocoa/scoped_menu_bar_lock_unittest.mm",
      "../browser/ui/cocoa/status_icons/status_icon_mac_unittest.mm",
      "../browser/ui/cocoa/tab_menu_bridge_unittest.mm",
      "../browser/ui/cocoa/test/run_loop_testing_unittest.mm",
      "../browser/ui/cocoa/touchbar/browser_window_default_touch_bar_unittest.mm",
      "../browser/ui/cocoa/touchbar/credit_card_autofill_touch_bar_controller_unittest.mm",
      "../browser/ui/cocoa/window_size_autosaver_unittest.mm",
      "../browser/ui/content_settings/content_setting_media_image_model_unittest.mm",
      "../browser/upgrade_detector/directory_monitor_unittest.cc",
      "../utility/importer/safari_importer_unittest.mm",
    ]

    data_deps += [ "//chrome:chrome_framework" ]

    deps += [
      "//chrome/app_shim",
      "//chrome/browser/apps/app_shim",
      "//chrome/browser/renderer_host:history_swiper",
      "//chrome/browser/updater:browser_updater_client",
      "//chrome/common/notifications",
      "//chrome/common/safe_browsing:archive_analyzer_results",
      "//chrome/common/safe_browsing:disk_image_type_sniffer_mac",
      "//chrome/services/mac_notifications:unit_tests",
      "//chrome/services/mac_notifications/public/mojom",
      "//chrome/updater:browser_sources",
      "//chrome/utility/safe_browsing",
      "//chrome/utility/safe_browsing/mac:dmg_common",
      "//components/power_metrics",

      # The test fetches resources which means Mac need the app bundle to exist
      # on disk so it can pull from it.
      "//third_party/ocmock",
      "//ui/events/devices:test_support",
    ]

    # TODO(mark): We really want this for all non-static library targets,
    # but when we tried to pull it up to the common.gypi level, it broke
    # other things like the ui and startup tests. *shrug*
    ldflags = [ "-Wl,-ObjC" ]
  } else {
    # !is_mac
    deps += [
      "//chrome/tools/convert_dict:lib",
      "//third_party/hunspell",
    ]
  }

  if (enable_paint_preview) {
    sources += [
      "../browser/paint_preview/services/paint_preview_tab_service_unittest.cc",
    ]
    deps += [ "//chrome/browser/paint_preview:services" ]
  }

  if (is_win || is_chromeos || is_mac) {
    deps += [ "//chrome/browser/webshare:unit_tests" ]
  }

  if (is_win || is_mac || is_android) {
    sources += [ "../browser/device_reauth/chrome_device_authenticator_factory_unittest.cc" ]
  }

  if (enable_dice_support) {
    sources += [
      "../browser/password_manager/multi_profile_credentials_filter_unittest.cc",
      "../browser/profiles/batch_upload/batch_upload_controller_unittest.cc",
      "../browser/signin/dice_response_handler_unittest.cc",
      "../browser/signin/dice_signed_in_profile_creator_unittest.cc",
      "../browser/signin/dice_tab_helper_unittest.cc",
      "../browser/signin/dice_web_signin_interceptor_unittest.cc",
      "../browser/signin/logout_tab_helper_unittest.cc",
      "../browser/signin/process_dice_header_delegate_impl_unittest.cc",
      "../browser/ui/autofill/autofill_bubble_signin_promo_controller_unittest.cc",
      "../browser/ui/startup/first_run_service_unittest.cc",
      "../browser/ui/startup/startup_browser_policy_unittest.cc",
      "../browser/ui/views/profiles/batch_upload_dialog_view_unittest.cc",
      "../browser/ui/views/profiles/dice_web_signin_interception_bubble_view_unittest.cc",
      "../browser/ui/webui/signin/dice_web_signin_intercept_handler_unittest.cc",
    ]
  }

  if (enable_bound_session_credentials) {
    sources += [
      "../browser/signin/bound_session_credentials/bound_session_cookie_controller_impl_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_cookie_observer_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_cookie_refresh_service_factory_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_cookie_refresh_service_impl_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_params_storage_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_params_util_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_refresh_cookie_fetcher_impl_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_registration_fetcher_impl_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_registration_fetcher_param_unittest.cc",
      "../browser/signin/bound_session_credentials/bound_session_request_throttled_handler_browser_impl_unittest.cc",
      "../browser/signin/bound_session_credentials/fake_keyed_unexportable_key_service_unittest.cc",
      "../browser/signin/bound_session_credentials/registration_token_helper_unittest.cc",
      "../browser/signin/bound_session_credentials/session_binding_helper_unittest.cc",
      "../browser/signin/bound_session_credentials/throttled_gaia_auth_fetcher_unittest.cc",
      "../renderer/bound_session_credentials/bound_session_request_throttled_handler_renderer_impl_unittest.cc",
      "../renderer/bound_session_credentials/bound_session_request_throttled_in_renderer_manager_unittest.cc",
    ]

    if (enable_dice_support) {
      sources += [ "../browser/signin/bound_session_credentials/dice_bound_session_cookie_service_unittest.cc" ]
    }
  }

  if (enable_offline_pages) {
    sources += [
      "../browser/offline_pages/background_loader_offliner_unittest.cc",
      "../browser/offline_pages/download_archive_manager_unittest.cc",
      "../browser/offline_pages/offline_page_mhtml_archiver_unittest.cc",
      "../browser/offline_pages/offline_page_navigation_throttle_unittest.cc",
      "../browser/offline_pages/offline_page_request_handler_unittest.cc",
      "../browser/offline_pages/offline_page_tab_helper_unittest.cc",
      "../browser/offline_pages/offline_page_utils_unittest.cc",
      "../browser/offline_pages/recent_tab_helper_unittest.cc",
      "../browser/offline_pages/test_offline_page_model_builder.cc",
      "../browser/offline_pages/test_offline_page_model_builder.h",
      "../browser/offline_pages/test_request_coordinator_builder.cc",
      "../browser/offline_pages/test_request_coordinator_builder.h",
      "../browser/offline_pages/visuals_decoder_impl_unittest.cc",
    ]
    if (is_android) {
      sources += [
        "../browser/offline_pages/android/auto_fetch_page_load_watcher_unittest.cc",
        "../browser/offline_pages/android/offline_page_archive_publisher_impl_unittest.cc",
        "../browser/offline_pages/android/offline_page_auto_fetcher_service_unittest.cc",
      ]
    }
    deps += [
      "//chrome/browser/android/locale",
      "//chrome/browser/image_fetcher",
      "//components/image_fetcher/core:test_support",
      "//components/offline_pages/content/background_loader:test_support",
      "//components/offline_pages/core:test_support",
      "//components/offline_pages/core/background:test_support",
    ]
  }

  if (enable_soda_integration_tests) {
    deps += [ "//chrome/services/speech/soda:unit_tests" ]
  }

  if (is_android) {
    sources += [
      "../browser/android/auxiliary_search/auxiliary_search_provider_unittest.cc",
      "../browser/android/bookmarks/partner_bookmarks_shim_unittest.cc",
      "../browser/android/chrome_backup_agent_unittest.cc",
      "../browser/android/compositor/layer/tab_layer_unittest.cc",
      "../browser/android/compositor/tab_content_manager_unittest.cc",
      "../browser/android/customtabs/detached_resource_request_unittest.cc",
      "../browser/android/customtabs/tab_interaction_recorder_android_unittest.cc",
      "../browser/android/customtabs/text_fragment_lookup_state_tracker_unittest.cc",
      "../browser/android/favicon_helper_unittest.cc",
      "../browser/android/framebust_intervention/framebust_blocked_delegate_android_unittest.cc",
      "../browser/android/history/history_deletion_bridge_unittest.cc",
      "../browser/android/locale/locale_template_url_loader_unittest.cc",
      "../browser/android/metrics/android_session_durations_service_unittest.cc",
      "../browser/android/omnibox/chrome_omnibox_navigation_observer_android_unittest.cc",
      "../browser/android/oom_intervention/near_oom_monitor_unittest.cc",
      "../browser/android/oom_intervention/near_oom_reduction_message_delegate_unittest.cc",
      "../browser/android/oom_intervention/oom_intervention_decider_unittest.cc",
      "../browser/android/persisted_tab_data/leveldb_persisted_tab_data_storage_android_factory_unittest.cc",
      "../browser/android/quick_delete/quick_delete_bridge_unittest.cc",
      "../browser/android/recently_closed_tabs_bridge_unittest.cc",
      "../browser/android/search_permissions/search_permissions_service_unittest.cc",
      "../browser/android/signin/signin_manager_android_unittest.cc",
      "../browser/android/signin/web_signin_bridge_unittest.cc",
      "../browser/android/usage_stats/usage_stats_database_unittest.cc",
      "../browser/android/webapk/webapk_database_unittest.cc",
      "../browser/android/webapk/webapk_helpers_unittest.cc",
      "../browser/android/webapk/webapk_restore_manager_unittest.cc",
      "../browser/android/webapk/webapk_sync_bridge_unittest.cc",
      "../browser/autofill/android/save_update_address_profile_message_controller_unittest.cc",
      "../browser/autofill/android/save_update_address_profile_prompt_controller_unittest.cc",
      "../browser/autofill/autofill_save_card_infobar_delegate_mobile_unittest.cc",
      "../browser/bookmarks//android/bookmark_bridge_unittest.cc",
      "../browser/commerce/merchant_viewer/merchant_viewer_data_manager_unittest.cc",
      "../browser/device_reauth/android/device_authenticator_android_unittest.cc",
      "../browser/download/android/available_offline_content_provider_unittest.cc",
      "../browser/download/android/download_controller_unittest.cc",
      "../browser/download/android/download_manager_service_unittest.cc",
      "../browser/enterprise/util/android_enterprise_info_unittest.cc",
      "../browser/fast_checkout/fast_checkout_capabilities_fetcher_impl_unittest.cc",
      "../browser/fast_checkout/fast_checkout_client_impl_unittest.cc",
      "../browser/fast_checkout/fast_checkout_delegate_impl_unittest.cc",
      "../browser/fast_checkout/fast_checkout_personal_data_helper_impl_unittest.cc",
      "../browser/fast_checkout/fast_checkout_trigger_validator_impl_unittest.cc",
      "../browser/feed/feed_service_factory_unittest.cc",
      "../browser/feed/rss_links_fetcher_unittest.cc",
      "../browser/feedback/android/family_info_feedback_source_unittest.cc",
      "../browser/long_screenshots/long_screenshots_tab_service_unittest.cc",
      "../browser/lookalikes/safety_tip_message_delegate_android_unittest.cc",
      "../browser/media/android/cdm/media_drm_origin_id_manager_unittest.cc",
      "../browser/metrics/chrome_android_metrics_provider_unittest.cc",
      "../browser/notifications/notification_channels_provider_android_unittest.cc",
      "../browser/optimization_guide/android/optimization_guide_bridge_unittest.cc",
      "../browser/optimization_guide/android/optimization_guide_tab_url_provider_android_unittest.cc",
      "../browser/page_image_service/android/image_service_bridge_unittest.cc",
      "../browser/page_load_metrics/observers/android_page_load_metrics_observer_unittest.cc",
      "../browser/password_manager/android/local_passwords_migration_warning_util_unittest.cc",
      "../browser/password_manager/android/password_migration_warning_startup_launcher_unittest.cc",
      "../browser/password_manager/android/password_ui_view_android_unittest.cc",
      "../browser/policy/browser_dm_token_storage_android_unittest.cc",
      "../browser/policy/chrome_browser_cloud_management_controller_android_unittest.cc",
      "../browser/policy/client_data_delegate_android_unittest.cc",
      "../browser/profiles/android/profile_resolver_unittest.cc",
      "../browser/readaloud/android/prefs_unittest.cc",
      "../browser/readaloud/android/synthetic_trial_unittest.cc",
      "../browser/search/contextual_search_policy_handler_android_unittest.cc",
      "../browser/segmentation_platform/client_util/tab_data_collection_util_unittest.cc",
      "../browser/share/page_info_sharing_bridge_unittest.cc",
      "../browser/sharing/click_to_call/click_to_call_message_handler_android_unittest.cc",
      "../browser/sharing/optimization_guide/optimization_guide_message_handler_unittest.cc",
      "../browser/sharing/sms/sms_fetch_request_handler_unittest.cc",
      "../browser/supervised_user/android/favicon_fetcher_unittest.cc",
      "../browser/supervised_user/android/supervised_user_web_content_handler_impl_unittest.cc",
      "../browser/sync/glue/synced_tab_delegate_android_unittest.cc",
      "../browser/touch_to_fill/autofill/android/touch_to_fill_delegate_android_impl_unittest.cc",
      "../browser/touch_to_fill/autofill/android/touch_to_fill_payment_method_controller_unittest.cc",
      "../browser/touch_to_fill/autofill/android/touch_to_fill_payment_method_quality_metrics_unittest.cc",
      "../browser/touch_to_fill/password_manager/touch_to_fill_controller_autofill_delegate_unittest.cc",
      "../browser/touch_to_fill/password_manager/touch_to_fill_controller_webauthn_delegate_unittest.cc",
      "../browser/translate/android/translate_bridge_unittest.cc",
      "../browser/translate/translate_manager_render_view_host_android_unittest.cc",
      "../browser/ui/android/autofill/autofill_cvc_save_message_delegate_unittest.cc",
      "../browser/ui/android/autofill/autofill_save_card_delegate_android_unittest.cc",
      "../browser/ui/android/autofill/autofill_save_iban_delegate_unittest.cc",
      "../browser/ui/android/autofill/autofill_vcn_enroll_bottom_sheet_bridge_unittest.cc",
      "../browser/ui/android/device_dialog/usb_chooser_dialog_android_unittest.cc",
      "../browser/ui/android/fast_checkout/ui_view_android_utils_unittest.cc",
      "../browser/ui/android/hats/survey_client_android_unittest.cc",
      "../browser/ui/android/plus_addresses/plus_address_creation_controller_android_unittest.cc",
      "../browser/ui/android/tab_model/tab_model_list_unittest.cc",
      "../browser/ui/android/toolbar/adaptive_toolbar_bridge_unittest.cc",
      "../browser/ui/android/toolbar/location_bar_model_android_unittest.cc",
      "../browser/ui/autofill/autofill_keyboard_accessory_controller_impl_unittest.cc",
      "../browser/ui/fast_checkout/fast_checkout_controller_impl_unittest.cc",
      "../browser/ui/safety_hub/password_status_check_result_android_unittest.cc",
      "../browser/wallet/android/boarding_pass_detector_unittest.cc",
      "../browser/webauthn/android/cable_module_android_unittest.cc",
      "../browser/webauthn/android/cable_registration_state_unittest.cc",
    ]

    deps += [
      ":test_support_java",
      ":test_support_jni_headers",
      "//chrome:chrome_android_core",
      "//chrome/android:chrome_apk_paks",
      "//chrome/android:chrome_java",
      "//chrome/android:delegate_public_impl_java",
      "//chrome/android/modules/dev_ui/provider:native",
      "//chrome/browser:delta_file_proto",
      "//chrome/browser:fast_checkout_funnels_proto",
      "//chrome/browser:profile_token",
      "//chrome/browser:usage_stats_proto",
      "//chrome/browser/android/auxiliary_search/proto",
      "//chrome/browser/android/httpclient:unittests",
      "//chrome/browser/android/webapk:webapk_sources",
      "//chrome/browser/android/webapk/test:webapk_test_support",
      "//chrome/browser/commerce/merchant_viewer:merchant_viewer_data_manager",
      "//chrome/browser/facilitated_payments:unit_tests",
      "//chrome/browser/facilitated_payments/ui/android:unit_tests",
      "//chrome/browser/flags:flags_android",
      "//chrome/browser/keyboard_accessory/android",
      "//chrome/browser/keyboard_accessory/android:unit_test",
      "//chrome/browser/keyboard_accessory/test_utils/android",
      "//chrome/browser/long_screenshots:services",
      "//chrome/browser/notifications",
      "//chrome/browser/optimization_guide/android:native_j_unittests_jni_headers",
      "//chrome/browser/optimization_guide/android:native_java_unittests",
      "//chrome/browser/password_check/android:unit_tests",
      "//chrome/browser/password_manager/android:unit_tests",
      "//chrome/browser/password_manager/android:utils",
      "//chrome/browser/password_manager/android/access_loss:test_support",
      "//chrome/browser/password_manager/android/access_loss:unit_tests",
      "//chrome/browser/readaloud/android:native",
      "//chrome/browser/reading_list/android:reading_list",
      "//chrome/browser/reading_list/android:unit_tests",
      "//chrome/browser/safety_hub/android:unit_tests",
      "//chrome/browser/share",
      "//chrome/browser/thumbnail:unit_tests",
      "//chrome/browser/touch_to_fill/autofill/android:public",
      "//chrome/browser/touch_to_fill/password_manager/no_passkeys/android:public",
      "//chrome/browser/touch_to_fill/password_manager/no_passkeys/android:unit_tests",
      "//chrome/browser/touch_to_fill/password_manager/password_generation/android:unit_tests",
      "//chrome/browser/translate/android:unit_tests",
      "//chrome/browser/ui/android/hats/test:test_support",
      "//chrome/browser/ui/autofill/payments:test_support",
      "//chrome/browser/ui/tabs:tab_enums",
      "//chrome/common/wallet:mojo_bindings",
      "//chrome/services/media_gallery_util:unit_tests",
      "//components/back_forward_cache",
      "//components/bookmarks/common/android:android",
      "//components/browser_ui/device_lock/android",
      "//components/browser_ui/device_lock/android:test_support",
      "//components/crash/content/browser",
      "//components/device_reauth",
      "//components/device_reauth:test_support",
      "//components/download/internal/common:internal_java",
      "//components/enterprise",
      "//components/enterprise:test_support",
      "//components/favicon/core/test:test_support",
      "//components/feed/core/shared_prefs:feed_shared_prefs",
      "//components/feed/mojom:mojo_bindings",
      "//components/gcm_driver/instance_id/android:instance_id_driver_java",
      "//components/gcm_driver/instance_id/android:instance_id_driver_test_support_java",
      "//components/infobars/android",
      "//components/location/android:test_support",
      "//components/media_router/browser:test_support",
      "//components/messages/android:test_support",
      "//components/module_installer/android:module_installer_java",
      "//components/navigation_interception:navigation_interception",
      "//components/offline_pages/core/request_header",
      "//components/offline_pages/task",
      "//components/page_image_service:page_image_service",
      "//components/password_manager/content/browser:test_support",
      "//components/plus_addresses/settings:test_support",
      "//components/pref_registry",
      "//components/services/unzip:in_process",
      "//components/signin/core/browser",
      "//components/signin/public/android:signin_java_test_support",
      "//components/supervised_user/core/browser/proto",
      "//components/supervised_user/core/common",
      "//components/translate/content/android:android",
      "//components/ukm:test_support",
      "//components/webapk:proto",
      "//components/webapps/browser",
      "//components/webauthn/android",
      "//components/webauthn/android:test_support",
      "//content/public/android:content_java",
      "//gin:v8_snapshot_assets",
      "//ui/accessibility",
      "//ui/android",
      "//ui/events/devices:test_support",
    ]

    if (enable_chrome_android_internal) {
      data_deps += [ "//clank/build/bot/filters:unit_tests_filters" ]
    }

    if (dfmify_dev_ui) {
      sources += [
        "//chrome/browser/dev_ui/android/dev_ui_loader_throttle_unittest.cc",
      ]

      # If DevUI DFM is on, include Java classes and native resource split so
      # that DevUI page tests would work.
      deps += [
        "//chrome/android/features/dev_ui:java",
        "//chrome/android/modules/dev_ui/provider:java",
      ]
    }
  } else {
    # !is_android
    sources += [
      "../browser/apps/intent_helper/intent_chip_display_prefs_unittest.cc",
      "../browser/autocomplete/tab_matcher_desktop_unittest.cc",
      "../browser/autofill/ui/autofill_image_fetcher_impl_unittest.cc",
      "../browser/autofill_prediction_improvements/chrome_autofill_prediction_improvements_client_unittest.cc",
      "../browser/browser_commands_unittest.cc",
      "../browser/browsing_data/chrome_browsing_data_lifetime_manager_unittest.cc",
      "../browser/cart/cart_discount_fetcher_unittest.cc",
      "../browser/cart/cart_discount_link_fetcher_unittest.cc",
      "../browser/cart/cart_handler_unittest.cc",
      "../browser/cart/cart_service_unittest.cc",
      "../browser/cart/fetch_discount_worker_unittest.cc",
      "../browser/commerce/coupons/coupon_service_unittest.cc",
      "../browser/component_updater/soda_component_installer_unittest.cc",
      "../browser/component_updater/soda_language_pack_component_installer_unittest.cc",
      "../browser/component_updater/translate_kit_component_installer_unittest.cc",
      "../browser/component_updater/zxcvbn_data_component_installer_unittest.cc",
      "../browser/content_settings/generated_cookie_prefs_unittest.cc",
      "../browser/content_settings/generated_notification_pref_unittest.cc",
      "../browser/data_sharing/desktop/data_sharing_conversion_utils_unittest.cc",
      "../browser/device_identity/device_oauth2_token_service_unittest.cc",
      "../browser/device_notifications/device_connection_tracker_unittest.cc",
      "../browser/device_notifications/device_connection_tracker_unittest.h",
      "../browser/device_notifications/device_system_tray_icon_unittest.cc",
      "../browser/device_notifications/device_system_tray_icon_unittest.h",
      "../browser/device_notifications/device_test_utils.cc",
      "../browser/device_notifications/device_test_utils.h",
      "../browser/devtools/aida_client_unittest.cc",
      "../browser/devtools/device/android_device_manager_unittest.cc",
      "../browser/devtools/devtools_file_helper_unittest.cc",
      "../browser/devtools/devtools_file_system_indexer_unittest.cc",
      "../browser/devtools/devtools_file_watcher_unittest.cc",
      "../browser/devtools/devtools_settings_unittest.cc",
      "../browser/devtools/devtools_ui_bindings_unittest.cc",
      "../browser/devtools/protocol/cast_handler_unittest.cc",
      "../browser/devtools/serialize_host_descriptions_unittest.cc",
      "../browser/diagnostics/diagnostics_controller_unittest.cc",
      "../browser/diagnostics/diagnostics_model_unittest.cc",
      "../browser/download/bubble/download_bubble_accessible_alerts_map_unittest.cc",
      "../browser/download/bubble/download_bubble_prefs_unittest.cc",
      "../browser/download/bubble/download_bubble_ui_controller_unittest.cc",
      "../browser/download/bubble/download_bubble_update_service_unittest.cc",
      "../browser/download/bubble/download_bubble_utils_unittest.cc",
      "../browser/download/bubble/download_display_controller_unittest.cc",
      "../browser/download/download_commands_unittest.cc",
      "../browser/download/download_dir_policy_handler_unittest.cc",
      "../browser/download/download_shelf_context_menu_unittest.cc",
      "../browser/download/download_shelf_unittest.cc",
      "../browser/download/download_warning_desktop_hats_utils_unittest.cc",
      "../browser/enterprise/reporting/extension_info_unittest.cc",
      "../browser/enterprise/reporting/extension_request/extension_request_notification_unittest.cc",
      "../browser/enterprise/reporting/extension_request/extension_request_observer_factory_unittest.cc",
      "../browser/enterprise/reporting/extension_request/extension_request_observer_unittest.cc",
      "../browser/enterprise/reporting/extension_request/extension_request_report_generator_unittest.cc",
      "../browser/enterprise/reporting/real_time_report_generator_unittest.cc",
      "../browser/enterprise/signals/client_certificate_fetcher_unittest.cc",
      "../browser/first_run/first_run_unittest.cc",
      "../browser/font_family_cache_unittest.cc",
      "../browser/hid/chrome_hid_delegate_unittest.cc",
      "../browser/hid/hid_chooser_context_unittest.cc",
      "../browser/hid/hid_connection_tracker_unittest.cc",
      "../browser/hid/hid_policy_allowed_devices_unittest.cc",
      "../browser/hid/hid_test_utils.cc",
      "../browser/hid/hid_test_utils.h",
      "../browser/importer/firefox_profile_lock_unittest.cc",
      "../browser/importer/profile_writer_unittest.cc",
      "../browser/lifetime/application_lifetime_unittest.cc",
      "../browser/lookalikes/lookalike_url_navigation_throttle_unittest.cc",
      "../browser/media/unified_autoplay_config_unittest.cc",
      "../browser/media/webrtc/current_tab_desktop_media_list_unittest.cc",
      "../browser/media/webrtc/desktop_capture_access_handler_unittest.cc",
      "../browser/media/webrtc/desktop_media_picker_controller_unittest.cc",
      "../browser/media/webrtc/display_media_access_handler_unittest.cc",
      "../browser/media/webrtc/media_capture_devices_dispatcher_unittest.cc",
      "../browser/media/webrtc/media_stream_capture_indicator_unittest.cc",
      "../browser/media/webrtc/media_stream_focus_delegate_unittest.cc",
      "../browser/media/webrtc/tab_capture_access_handler_unittest.cc",
      "../browser/media/webrtc/tab_desktop_media_list_unittest.cc",
      "../browser/media/webrtc/webrtc_event_log_manager_common_unittest.cc",
      "../browser/media/webrtc/webrtc_event_log_manager_unittest.cc",
      "../browser/media/webrtc/webrtc_event_log_manager_unittest_helpers.cc",
      "../browser/media/webrtc/webrtc_event_log_manager_unittest_helpers.h",
      "../browser/media/webrtc/webrtc_event_log_uploader_impl_unittest.cc",
      "../browser/media/webrtc/webrtc_log_uploader_unittest.cc",
      "../browser/media/webrtc/webrtc_logging_controller_unittest.cc",
      "../browser/media/webrtc/webrtc_rtp_dump_handler_unittest.cc",
      "../browser/media/webrtc/webrtc_rtp_dump_writer_unittest.cc",
      "../browser/media_galleries/fileapi/native_media_file_util_unittest.cc",
      "../browser/media_galleries/gallery_watch_manager_unittest.cc",
      "../browser/media_galleries/media_file_system_registry_unittest.cc",
      "../browser/media_galleries/media_galleries_dialog_controller_mock.cc",
      "../browser/media_galleries/media_galleries_dialog_controller_mock.h",
      "../browser/media_galleries/media_galleries_dialog_controller_test_util.cc",
      "../browser/media_galleries/media_galleries_dialog_controller_test_util.h",
      "../browser/media_galleries/media_galleries_permission_controller_unittest.cc",
      "../browser/media_galleries/media_galleries_permissions_unittest.cc",
      "../browser/media_galleries/media_galleries_preferences_unittest.cc",
      "../browser/memory/enterprise_memory_limit_evaluator_unittest.cc",
      "../browser/metrics/desktop_session_duration/desktop_session_duration_tracker_unittest.cc",
      "../browser/metrics/desktop_session_duration/touch_mode_stats_tracker_unittest.cc",
      "../browser/metrics/power/power_metrics_reporter_unittest.cc",
      "../browser/metrics/power/power_metrics_unittest.cc",
      "../browser/metrics/power/process_monitor_unittest.cc",
      "../browser/metrics/tab_stats/tab_stats_data_store_unittest.cc",
      "../browser/metrics/tab_stats/tab_stats_tracker_unittest.cc",
      "../browser/metrics/usage_scenario/chrome_responsiveness_calculator_delegate_unittest.cc",
      "../browser/metrics/usage_scenario/system_event_provider_unittest.cc",
      "../browser/metrics/usage_scenario/tab_usage_scenario_tracker_unittest.cc",
      "../browser/metrics/usage_scenario/usage_scenario_data_store_unittest.cc",
      "../browser/metrics/usage_scenario/usage_scenario_unittest.cc",
      "../browser/new_tab_page/one_google_bar/one_google_bar_loader_impl_unittest.cc",
      "../browser/new_tab_page/one_google_bar/one_google_bar_service_unittest.cc",
      "../browser/new_tab_page/promos/promo_service_unittest.cc",
      "../browser/notifications/muted_notification_handler_unittest.cc",
      "../browser/notifications/screen_capture_notification_blocker_unittest.cc",
      "../browser/password_manager/generated_password_leak_detection_pref_unittest.cc",
      "../browser/platform_util_unittest.cc",
      "../browser/policy/policy_path_parser_unittest.cc",
      "../browser/policy/serial_allow_usb_devices_for_urls_policy_handler_unittest.cc",
      "../browser/policy/webhid_device_policy_handler_unittest.cc",
      "../browser/private_network_access/private_network_device_chooser_controller_unittest.cc",
      "../browser/private_network_access/private_network_device_permission_context_unittest.cc",
      "../browser/profile_resetter/profile_resetter_unittest.cc",
      "../browser/profile_resetter/reset_report_uploader_unittest.cc",
      "../browser/profiles/guest_profile_creation_logger_unittest.cc",
      "../browser/profiles/profile_avatar_icon_util_unittest.cc",
      "../browser/profiles/profile_destroyer_unittest.cc",
      "../browser/renderer_context_menu/render_view_context_menu_unittest.cc",
      "../browser/resource_coordinator/decision_details_unittest.cc",
      "../browser/resource_coordinator/discard_metrics_lifecycle_unit_observer_unittest.cc",
      "../browser/resource_coordinator/lifecycle_unit_base_unittest.cc",
      "../browser/resource_coordinator/lifecycle_unit_unittest.cc",
      "../browser/resource_coordinator/session_restore_policy_unittest.cc",
      "../browser/resource_coordinator/tab_lifecycle_unit_source_unittest.cc",
      "../browser/resource_coordinator/tab_lifecycle_unit_unittest.cc",
      "../browser/resource_coordinator/tab_manager_unittest.cc",
      "../browser/resource_coordinator/tab_memory_metrics_reporter_unittest.cc",
      "../browser/resource_coordinator/test_lifecycle_unit.cc",
      "../browser/resource_coordinator/test_lifecycle_unit.h",
      "../browser/resource_coordinator/usage_clock_unittest.cc",
      "../browser/resources_integrity_unittest.cc",
      "../browser/safe_browsing/generated_safe_browsing_pref_unittest.cc",
      "../browser/search/background/ntp_background_service_unittest.cc",
      "../browser/search/background/ntp_custom_background_service_unittest.cc",
      "../browser/search/background/wallpaper_search/wallpaper_search_background_manager_unittest.cc",
      "../browser/search/instant_service_unittest.cc",
      "../browser/search/instant_unittest_base.cc",
      "../browser/search/instant_unittest_base.h",
      "../browser/search/most_visited_iframe_source_unittest.cc",
      "../browser/search/search_engine_base_url_tracker_unittest.cc",
      "../browser/search/search_unittest.cc",
      "../browser/send_tab_to_self/desktop_notification_handler_unittest.cc",
      "../browser/send_tab_to_self/send_tab_to_self_client_service_unittest.cc",
      "../browser/send_tab_to_self/send_tab_to_self_util_unittest.cc",
      "../browser/serial/serial_blocklist_unittest.cc",
      "../browser/serial/serial_chooser_context_unittest.cc",
      "../browser/serial/serial_policy_allowed_ports_unittest.cc",
      "../browser/sessions/restore_on_startup_policy_handler_unittest.cc",
      "../browser/sessions/tab_restore_service_unittest.cc",
      "../browser/sharing/shared_clipboard/remote_copy_message_handler_unittest.cc",
      "../browser/sharing/shared_clipboard/shared_clipboard_message_handler_desktop_unittest.cc",
      "../browser/sharing/shared_clipboard/shared_clipboard_test_base.cc",
      "../browser/sharing/shared_clipboard/shared_clipboard_test_base.h",
      "../browser/sharing/sms/sms_remote_fetcher_unittest.cc",
      "../browser/signin/signin_promo_unittest.cc",
      "../browser/speech/extension_api/extension_manifests_tts_unittest.cc",
      "../browser/speech/speech_recognition_service_factory_unittest.cc",
      "../browser/support_tool/screenshot_data_collector_unittest.cc",
      "../browser/support_tool/support_tool_handler_unittest.cc",
      "../browser/support_tool/system_log_source_data_collector_adaptor_unittest.cc",
      "../browser/sync/prefs/chrome_syncable_prefs_database_unittest.cc",
      "../browser/sync/sessions/browser_list_router_helper_unittest.cc",
      "../browser/sync/sessions/sync_sessions_router_tab_helper_unittest.cc",
      "../browser/sync/sync_ui_util_unittest.cc",  # Sync setup uses native ui.
      "../browser/tab_contents/form_interaction_tab_helper_unittest.cc",
      "../browser/task_manager/providers/browser_process_task_unittest.cc",
      "../browser/task_manager/providers/child_process_task_unittest.cc",
      "../browser/task_manager/providers/fallback_task_provider_unittest.cc",
      "../browser/task_manager/providers/spare_render_process_host_task_unittest.cc",
      "../browser/task_manager/sampling/task_group_unittest.cc",
      "../browser/task_manager/sampling/task_manager_impl_unittest.cc",
      "../browser/task_manager/task_manager_observer_unittest.cc",
      "../browser/task_manager/test_task_manager.cc",
      "../browser/task_manager/test_task_manager.h",
      "../browser/themes/browser_theme_pack_unittest.cc",
      "../browser/themes/theme_properties_unittest.cc",
      "../browser/themes/theme_service_test_utils.cc",
      "../browser/themes/theme_service_test_utils.h",
      "../browser/themes/theme_service_unittest.cc",
      "../browser/themes/theme_syncable_service_unittest.cc",
      "../browser/translate/translate_manager_render_view_host_unittest.cc",
      "../browser/ui/autofill/add_new_address_bubble_controller_unittest.cc",
      "../browser/ui/autofill/address_bubbles_controller_unittest.cc",
      "../browser/ui/autofill/address_editor_controller_unittest.cc",
      "../browser/ui/autofill/autofill_field_promo_controller_impl_unittest.cc",
      "../browser/ui/autofill/delete_address_profile_dialog_controller_impl_unittest.cc",
      "../browser/ui/autofill/edit_address_profile_dialog_controller_impl_unittest.cc",
      "../browser/ui/autofill/save_address_bubble_controller_unittest.cc",
      "../browser/ui/autofill/update_address_bubble_controller_unittest.cc",
      "../browser/ui/bookmarks/bookmark_context_menu_controller_unittest.cc",
      "../browser/ui/bookmarks/bookmark_drag_drop_unittest.cc",
      "../browser/ui/bookmarks/bookmark_editor_unittest.cc",
      "../browser/ui/bookmarks/bookmark_stats_tab_helper_unittest.cc",
      "../browser/ui/bookmarks/bookmark_ui_utils_desktop_unittest.cc",
      "../browser/ui/bookmarks/bookmark_unittest.cc",
      "../browser/ui/bookmarks/recently_used_folders_combo_model_unittest.cc",
      "../browser/ui/breadcrumb_manager_browser_agent_unittest.cc",
      "../browser/ui/browser_actions_unittest.cc",
      "../browser/ui/browser_close_unittest.cc",
      "../browser/ui/browser_command_controller_unittest.cc",
      "../browser/ui/browser_finder_unittest.cc",
      "../browser/ui/browser_instant_controller_unittest.cc",
      "../browser/ui/browser_list_unittest.cc",
      "../browser/ui/browser_navigator_unittest.cc",
      "../browser/ui/browser_unittest.cc",
      "../browser/ui/browser_window_state_unittest.cc",
      "../browser/ui/color/chrome_color_provider_utils_unittest.cc",
      "../browser/ui/color/material_new_tab_page_color_mixer_unittest.cc",
      "../browser/ui/color/new_tab_page_color_mixer_unittest.cc",
      "../browser/ui/commerce/commerce_ui_tab_helper_unittest.cc",
      "../browser/ui/commerce/discounts_page_action_controller_unittest.cc",
      "../browser/ui/commerce/price_tracking_page_action_controller_unittest.cc",
      "../browser/ui/commerce/product_specifications_page_action_controller_unittest.cc",
      "../browser/ui/content_settings/content_setting_bubble_model_unittest.cc",
      "../browser/ui/content_settings/content_setting_image_model_unittest.cc",
      "../browser/ui/exclusive_access/exclusive_access_bubble_unittest.cc",
      "../browser/ui/exclusive_access/fullscreen_controller_state_unittest.cc",
      "../browser/ui/extensions/controlled_home_bubble_delegate_unittest.cc",
      "../browser/ui/extensions/extension_action_view_controller_unittest.cc",
      "../browser/ui/extensions/extension_installed_bubble_model_unittest.cc",
      "../browser/ui/extensions/extension_installed_waiter_unittest.cc",
      "../browser/ui/extensions/extension_settings_overridden_dialog_unittest.cc",
      "../browser/ui/extensions/extensions_overrides/simple_overrides_unittest.cc",
      "../browser/ui/extensions/settings_api_bubble_helpers_unittest.cc",
      "../browser/ui/extensions/settings_overridden_params_providers_unittest.cc",
      "../browser/ui/global_error/global_error_service_unittest.cc",
      "../browser/ui/global_media_controls/cast_device_list_host_unittest.cc",
      "../browser/ui/global_media_controls/cast_media_notification_item_unittest.cc",
      "../browser/ui/global_media_controls/cast_media_notification_producer_unittest.cc",
      "../browser/ui/global_media_controls/cast_media_session_controller_unittest.cc",
      "../browser/ui/global_media_controls/media_notification_device_provider_impl_unittest.cc",
      "../browser/ui/global_media_controls/media_notification_service_unittest.cc",
      "../browser/ui/global_media_controls/media_toolbar_button_controller_unittest.cc",
      "../browser/ui/global_media_controls/presentation_request_notification_item_unittest.cc",
      "../browser/ui/global_media_controls/presentation_request_notification_producer_unittest.cc",
      "../browser/ui/global_media_controls/supplemental_device_picker_item_unittest.cc",
      "../browser/ui/global_media_controls/supplemental_device_picker_producer_unittest.cc",
      "../browser/ui/hats/hats_helper_unittest.cc",
      "../browser/ui/hats/trust_safety_sentiment_service_factory_unittest.cc",
      "../browser/ui/hats/trust_safety_sentiment_service_unittest.cc",
      "../browser/ui/hid/hid_chooser_controller_unittest.cc",
      "../browser/ui/intent_picker_tab_helper_unittest.cc",
      "../browser/ui/media_router/cast_modes_with_media_sources_unittest.cc",
      "../browser/ui/media_router/media_router_ui_helper_unittest.cc",
      "../browser/ui/media_router/media_router_ui_service_factory_unittest.cc",
      "../browser/ui/media_router/query_result_manager_unittest.cc",
      "../browser/ui/omnibox/chrome_omnibox_navigation_observer_unittest.cc",
      "../browser/ui/omnibox/clipboard_utils_unittest.cc",
      "../browser/ui/omnibox/omnibox_pedal_implementations_unittest.cc",
      "../browser/ui/omnibox/omnibox_pedals_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/add_username_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/auto_sign_in_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/common_saved_account_manager_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/default_store_changed_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/generation_confirmation_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/manage_passwords_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/move_to_account_store_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/post_save_compromised_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/save_unsynced_credentials_locally_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/save_update_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/shared_passwords_notifications_bubble_controller_unittest.cc",
      "../browser/ui/passwords/credential_leak_dialog_controller_impl_unittest.cc",
      "../browser/ui/passwords/credential_manager_dialog_controller_impl_unittest.cc",
      "../browser/ui/passwords/manage_passwords_ui_controller_unittest.cc",
      "../browser/ui/passwords/password_manager_navigation_throttle_unittest.cc",
      "../browser/ui/passwords/well_known_change_password_navigation_throttle_unittest.cc",
      "../browser/ui/performance_controls/performance_controls_hats_service_unittest.cc",
      "../browser/ui/performance_controls/performance_controls_metrics_unittest.cc",
      "../browser/ui/performance_controls/tab_resource_usage_tab_helper_unittest.cc",
      "../browser/ui/qrcode_generator/qrcode_generator_bubble_controller_unittest.cc",
      "../browser/ui/recently_audible_helper_unittest.cc",
      "../browser/ui/safety_hub/abusive_notification_permissions_manager_unittest.cc",
      "../browser/ui/safety_hub/extensions_result_unittest.cc",
      "../browser/ui/safety_hub/mock_safe_browsing_database_manager.cc",
      "../browser/ui/safety_hub/mock_safe_browsing_database_manager.h",
      "../browser/ui/safety_hub/password_status_check_result_unittest.cc",
      "../browser/ui/safety_hub/password_status_check_service_unittest.cc",
      "../browser/ui/safety_hub/safety_hub_hats_service_unittest.cc",
      "../browser/ui/safety_hub/unused_site_permissions_service_unittest.cc",
      "../browser/ui/search/ntp_user_data_logger_unittest.cc",
      "../browser/ui/search/search_ipc_router_policy_unittest.cc",
      "../browser/ui/search/search_ipc_router_unittest.cc",
      "../browser/ui/serial/serial_chooser_controller_unittest.cc",
      "../browser/ui/singleton_tabs_unittest.cc",
      "../browser/ui/startup/launch_mode_recorder_unittest.cc",
      "../browser/ui/tab_contents/chrome_web_contents_menu_helper_unittest.cc",
      "../browser/ui/tab_contents/core_tab_helper_unittest.cc",
      "../browser/ui/tab_contents/tab_contents_iterator_unittest.cc",
      "../browser/ui/tab_sharing/tab_sharing_infobar_delegate_unittest.cc",
      "../browser/ui/tabs/existing_base_sub_menu_model_unittest.cc",
      "../browser/ui/tabs/existing_tab_group_sub_menu_model_unittest.cc",
      "../browser/ui/tabs/existing_window_sub_menu_model_unittest.cc",
      "../browser/ui/tabs/organization/tab_organization_service_unittest.cc",
      "../browser/ui/tabs/organization/tab_organization_unittest.cc",
      "../browser/ui/tabs/organization/trigger_observer_unittest.cc",
      "../browser/ui/tabs/organization/trigger_policies_unittest.cc",
      "../browser/ui/tabs/organization/trigger_unittest.cc",
      "../browser/ui/tabs/pinned_tab_codec_unittest.cc",
      "../browser/ui/tabs/pinned_tab_service_unittest.cc",
      "../browser/ui/tabs/recent_tabs_builder_test_helper.cc",
      "../browser/ui/tabs/recent_tabs_builder_test_helper.h",
      "../browser/ui/tabs/recent_tabs_sub_menu_model_unittest.cc",
      "../browser/ui/tabs/saved_tab_groups/saved_tab_group_keyed_service_unittest.cc",
      "../browser/ui/tabs/saved_tab_groups/tab_group_sync_service_proxy_unittest.cc",
      "../browser/ui/tabs/supports_handles_unittest.cc",
      "../browser/ui/tabs/tab_collection_storage_unittest.cc",
      "../browser/ui/tabs/tab_collection_unittest.cc",
      "../browser/ui/tabs/tab_menu_model_unittest.cc",
      "../browser/ui/tabs/tab_strip_model_stats_recorder_unittest.cc",
      "../browser/ui/tabs/tab_strip_model_unittest.cc",
      "../browser/ui/tabs/test_tab_strip_model_delegate.cc",
      "../browser/ui/tabs/test_tab_strip_model_delegate.h",
      "../browser/ui/thumbnails/thumbnail_capture_driver_unittest.cc",
      "../browser/ui/thumbnails/thumbnail_image_unittest.cc",
      "../browser/ui/thumbnails/thumbnail_scheduler_impl_unittest.cc",
      "../browser/ui/toolbar/app_menu_icon_controller_unittest.cc",
      "../browser/ui/toolbar/app_menu_model_unittest.cc",
      "../browser/ui/toolbar/back_forward_menu_model_unittest.cc",
      "../browser/ui/toolbar/cast/cast_contextual_menu_unittest.cc",
      "../browser/ui/toolbar/cast/cast_toolbar_button_controller_unittest.cc",
      "../browser/ui/toolbar/cast/mock_cast_toolbar_button_controller.cc",
      "../browser/ui/toolbar/cast/mock_cast_toolbar_button_controller.h",
      "../browser/ui/toolbar/chrome_labs/chrome_labs_model_unittest.cc",
      "../browser/ui/toolbar/chrome_location_bar_model_delegate_unittest.cc",
      "../browser/ui/toolbar/location_bar_model_unittest.cc",
      "../browser/ui/toolbar/toolbar_actions_model_unittest.cc",
      "../browser/ui/url_identity_unittest.cc",
      "../browser/ui/views/autofill/add_new_address_bubble_view_unittest.cc",
      "../browser/ui/views/autofill/address_editor_view_unittest.cc",
      "../browser/ui/views/autofill/autofill_field_promo_view_impl_unittest.cc",
      "../browser/ui/views/autofill/edit_address_profile_view_unittest.cc",
      "../browser/ui/views/autofill/save_address_profile_view_unittest.cc",
      "../browser/ui/views/autofill/update_address_profile_view_unittest.cc",
      "../browser/ui/views/exclusive_access_bubble_views_unittest.cc",
      "../browser/ui/views/file_system_access/file_system_access_restore_permission_bubble_view_unittest.cc",
      "../browser/ui/views/passwords/manage_passwords_view_unittest.cc",
      "../browser/ui/views/passwords/move_to_account_store_bubble_view_unittest.cc",
      "../browser/ui/views/passwords/password_bubble_view_test_base.cc",
      "../browser/ui/views/passwords/password_bubble_view_test_base.h",
      "../browser/ui/views/passwords/password_save_unsynced_credentials_locally_view_unittest.cc",
      "../browser/ui/views/passwords/password_save_update_view_unittest.cc",
      "../browser/ui/views/passwords/post_save_compromised_bubble_view_unittest.cc",
      "../browser/ui/views/passwords/shared_passwords_notification_view_unittest.cc",
      "../browser/ui/views/side_panel/companion/companion_utils_unittest.cc",
      "../browser/ui/views/side_panel/companion/exps_registration_success_observer_unittest.cc",
      "../browser/ui/views/side_panel/side_panel_entry_key_unittest.cc",
      "../browser/ui/views/webauthn/passkey_deleted_confirmation_view_unittest.cc",
      "../browser/ui/views/webauthn/passkey_not_accepted_bubble_view_unittest.cc",
      "../browser/ui/views/webauthn/passkey_saved_confirmation_view_unittest.cc",
      "../browser/ui/views/webauthn/passkey_updated_confirmation_view_unittest.cc",
      "../browser/ui/views/webauthn/ring_progress_bar_unittest.cc",
      "../browser/ui/views/webid/account_selection_bubble_view_unittest.cc",
      "../browser/ui/views/webid/account_selection_view_test_base.cc",
      "../browser/ui/views/webid/account_selection_view_test_base.h",
      "../browser/ui/views/webid/fake_delegate.cc",
      "../browser/ui/views/webid/fake_delegate.h",
      "../browser/ui/views/webid/fedcm_account_selection_view_desktop_unittest.cc",
      "../browser/ui/views/webid/fedcm_modal_dialog_view_unittest.cc",
      "../browser/ui/webauthn/passkey_deleted_confirmation_controller_unittest.cc",
      "../browser/ui/webauthn/passkey_not_accepted_bubble_controller_unittest.cc",
      "../browser/ui/webauthn/passkey_saved_confirmation_controller_unittest.cc",
      "../browser/ui/webauthn/passkey_updated_confirmation_controller_unittest.cc",
      "../browser/ui/webauthn/sheet_models_unittest.cc",
      "../browser/ui/webid/identity_dialog_controller_unittest.cc",
      "../browser/ui/webui/about/about_ui_unittest.cc",
      "../browser/ui/webui/access_code_cast/access_code_cast_handler_unittest.cc",
      "../browser/ui/webui/browser_command/browser_command_handler_unittest.cc",
      "../browser/ui/webui/commerce/shopping_list_context_menu_controller_unittest.cc",
      "../browser/ui/webui/components/components_handler_unittest.cc",
      "../browser/ui/webui/constrained_web_dialog_ui_unittest.cc",
      "../browser/ui/webui/cr_components/customize_color_scheme_mode/customize_color_scheme_mode_handler_unittest.cc",
      "../browser/ui/webui/cr_components/history_embeddings/history_embeddings_handler_unittest.cc",
      "../browser/ui/webui/cr_components/theme_color_picker/theme_color_picker_handler_unittest.cc",
      "../browser/ui/webui/data_sharing/data_sharing_page_handler_unittest.cc",
      "../browser/ui/webui/data_sharing_internals/data_sharing_internals_page_handler_impl_unittest.cc",
      "../browser/ui/webui/devtools/devtools_ui_data_source_unittest.cc",
      "../browser/ui/webui/discards/graph_dump_impl_unittest.cc",
      "../browser/ui/webui/downloads/downloads_dom_handler_unittest.cc",
      "../browser/ui/webui/downloads/downloads_list_tracker_unittest.cc",
      "../browser/ui/webui/downloads/mock_downloads_page.cc",
      "../browser/ui/webui/downloads/mock_downloads_page.h",
      "../browser/ui/webui/favicon_source_unittest.cc",
      "../browser/ui/webui/feedback/feedback_ui_unittest.cc",
      "../browser/ui/webui/flags/flags_ui_handler_unittest.cc",
      "../browser/ui/webui/history/browsing_history_handler_unittest.cc",
      "../browser/ui/webui/history/foreign_session_handler_unittest.cc",
      "../browser/ui/webui/managed_ui_handler_unittest.cc",
      "../browser/ui/webui/metrics_reporter/metrics_reporter_unittest.cc",
      "../browser/ui/webui/metrics_reporter/mock_metrics_reporter.cc",
      "../browser/ui/webui/metrics_reporter/mock_metrics_reporter.h",
      "../browser/ui/webui/new_tab_page/new_tab_page_handler_unittest.cc",
      "../browser/ui/webui/password_manager/promo_cards_handler_unittest.cc",
      "../browser/ui/webui/password_manager/sync_handler_unittest.cc",
      "../browser/ui/webui/privacy_sandbox/privacy_sandbox_dialog_handler_unittest.cc",
      "../browser/ui/webui/sanitized_image_source_unittest.cc",
      "../browser/ui/webui/search_engine_choice/icon_utils_unittest.cc",
      "../browser/ui/webui/searchbox/realbox_handler_unittest.cc",
      "../browser/ui/webui/segmentation_internals/segmentation_internals_page_handler_impl_unittest.cc",
      "../browser/ui/webui/settings/downloads_handler_unittest.cc",
      "../browser/ui/webui/settings/hats_handler_unittest.cc",
      "../browser/ui/webui/settings/metrics_reporting_handler_unittest.cc",
      "../browser/ui/webui/settings/on_startup_handler_unittest.cc",
      "../browser/ui/webui/settings/people_handler_unittest.cc",
      "../browser/ui/webui/settings/performance_handler_unittest.cc",
      "../browser/ui/webui/settings/privacy_sandbox_handler_unittest.cc",
      "../browser/ui/webui/settings/profile_info_handler_unittest.cc",
      "../browser/ui/webui/settings/recent_site_settings_helper_unittest.cc",
      "../browser/ui/webui/settings/reset_settings_handler_unittest.cc",
      "../browser/ui/webui/settings/safety_check_handler_unittest.cc",
      "../browser/ui/webui/settings/safety_hub_handler_unittest.cc",
      "../browser/ui/webui/settings/search_engines_handler_unittest.cc",
      "../browser/ui/webui/settings/settings_clear_browsing_data_handler_unittest.cc",
      "../browser/ui/webui/settings/settings_manage_profile_handler_unittest.cc",
      "../browser/ui/webui/settings/settings_media_devices_selection_handler_unittest.cc",
      "../browser/ui/webui/settings/settings_security_key_handler_unittest.cc",
      "../browser/ui/webui/settings/settings_utils_unittest.cc",
      "../browser/ui/webui/settings/site_settings_handler_unittest.cc",
      "../browser/ui/webui/settings/site_settings_helper_unittest.cc",
      "../browser/ui/webui/side_panel/bookmarks/bookmarks_page_handler_unittest.cc",
      "../browser/ui/webui/side_panel/customize_chrome/customize_chrome_page_handler_unittest.cc",
      "../browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar_handler_unittest.cc",
      "../browser/ui/webui/side_panel/customize_chrome/wallpaper_search/wallpaper_search_handler_unittest.cc",
      "../browser/ui/webui/side_panel/read_anything/read_anything_untrusted_page_handler_unittest.cc",
      "../browser/ui/webui/side_panel/reading_list/reading_list_page_handler_unittest.cc",
      "../browser/ui/webui/signin/login_ui_service_unittest.cc",
      "../browser/ui/webui/signin/profile_picker_handler_unittest.cc",
      "../browser/ui/webui/signin/signin_url_utils_unittest.cc",
      "../browser/ui/webui/signin/sync_confirmation_handler_unittest.cc",
      "../browser/ui/webui/signin/sync_confirmation_ui_unittest.cc",
      "../browser/ui/webui/support_tool/support_tool_ui_utils_unittest.cc",
      "../browser/ui/webui/tab_search/tab_search_page_handler_unittest.cc",
      "../browser/ui/webui/theme_source_unittest.cc",
      "../browser/ui/webui/top_chrome/per_profile_webui_tracker_unittest.cc",
      "../browser/ui/webui/top_chrome/preload_context_unittest.cc",
      "../browser/ui/webui/top_chrome/profile_preload_candidate_selector_unittest.cc",
      "../browser/ui/webui/top_chrome/top_chrome_webui_config_unittest.cc",
      "../browser/ui/webui/top_chrome/webui_contents_preload_manager_unittest.cc",
      "../browser/ui/webui/top_chrome/webui_contents_wrapper_unittest.cc",
      "../browser/ui/webui/web_dialog_web_contents_delegate_unittest.cc",
      "../browser/ui/webui/webui_allowlist_provider_unittest.cc",
      "../browser/ui/window_sizer/window_sizer_common_unittest.cc",
      "../browser/ui/window_sizer/window_sizer_common_unittest.h",
      "../browser/ui/window_sizer/window_sizer_unittest.cc",
      "../browser/upgrade_detector/build_state_unittest.cc",
      "../browser/upgrade_detector/mock_build_state_observer.cc",
      "../browser/upgrade_detector/mock_build_state_observer.h",
      "../browser/upgrade_detector/upgrade_detector_unittest.cc",
      "../browser/usb/chrome_usb_delegate_unittest.cc",
      "../browser/usb/usb_blocklist_unittest.cc",
      "../browser/usb/usb_chooser_context_mock_device_observer.cc",
      "../browser/usb/usb_chooser_context_mock_device_observer.h",
      "../browser/usb/usb_chooser_context_unittest.cc",
      "../browser/usb/usb_chooser_controller_unittest.cc",
      "../browser/usb/usb_connection_tracker_unittest.cc",
      "../browser/usb/usb_policy_allowed_devices_unittest.cc",
      "../browser/usb/usb_test_utils.cc",
      "../browser/usb/usb_test_utils.h",
      "../browser/usb/web_usb_detector_unittest.cc",
      "../browser/visited_url_ranking/desktop_tab_model_url_visit_data_fetcher_unittest.cc",
      "../browser/webauthn/authenticator_request_dialog_model_unittest.cc",
      "../browser/webauthn/authenticator_request_scheduler_unittest.cc",
      "../browser/webauthn/cablev2_devices_unittest.cc",
      "../browser/webauthn/chrome_authenticator_request_delegate_unittest.cc",
      "../browser/webauthn/enclave_manager_unittest.cc",
      "../common/importer/mock_importer_bridge.cc",
      "../common/importer/mock_importer_bridge.h",
      "../renderer/accessibility/read_aloud_traversal_utils_unittest.cc",
      "../renderer/accessibility/read_anything_node_utils_unittest.cc",
      "../renderer/media/webrtc_logging_agent_impl_unittest.cc",
      "../renderer/searchbox/searchbox_unittest.cc",
      "../utility/importer/bookmark_html_reader_unittest.cc",
      "../utility/importer/bookmarks_file_importer_unittest.cc",
      "interaction/interaction_test_util_browser_unittest.cc",
      "interaction/webcontents_interaction_test_util_unittest.cc",
    ]

    if (!is_chromeos_lacros) {
      sources += [ "../browser/ui/webui/app_management/app_management_page_handler_unittest.cc" ]
    }

    if (is_chrome_branded) {
      sources += [
        "../browser/ui/webui/password_manager/promo_card_unittest.cc",
        "../browser/ui/webui/password_manager/promo_cards/move_passwords_promo_unittest.cc",
      ]
    }

    if (is_mac || is_win) {
      sources += [ "../browser/ui/webui/password_manager/promo_cards/screenlock_reauth_promo_unittest.cc" ]
      deps += [ "//components/device_reauth:test_support" ]
    }

    if (is_mac) {
      sources +=
          [ "../browser/webauthn/local_credential_management_mac_unittest.mm" ]
    }

    if (is_win) {
      sources +=
          [ "../browser/webauthn/local_credential_management_win_unittest.cc" ]
    }

    if (is_linux || is_mac || is_win) {
      sources += [
        "../browser/supervised_user/linux_mac_windows/supervised_user_extensions_metrics_delegate_impl_unittest.cc",
        "../browser/ui/webui/settings/accessibility_main_handler_unittest.cc",
      ]
    }

    sources += [
      # Badging isn't supported on Android.
      "../browser/badging/badge_manager_unittest.cc",
    ]

    sources += [
      # Device API isn't supported on Android.
      "../browser/device_api/device_service_unittest.cc",
      "../browser/device_api/managed_configuration_service_unittest.cc",
    ]

    sources += [
      # Bookmark export/import are handled via the BookmarkColumns
      # ContentProvider.
      "../browser/bookmarks/bookmark_html_writer_unittest.cc",
    ]

    sources += [
      # GCMDriverAndroid is not yet implemented.
      "../browser/gcm/gcm_profile_service_unittest.cc",
    ]

    sources += [
      # Media remoting is not supported on Android for now.
      "../browser/media/cast_remoting_connector_unittest.cc",
    ]

    sources += [
      # The site data database isn't supported on Android.
      "../browser/performance_manager/persistence/site_data/site_data_cache_facade_unittest.cc",
      "../browser/performance_manager/persistence/site_data/unittest_utils.cc",
      "../browser/performance_manager/persistence/site_data/unittest_utils.h",
    ]

    sources += [
      # Urgent discarding from performance_manager, high-efficiency mode, and
      # the High-PMF discard policy aren't supported on Android.
      "../browser/performance_manager/policies/memory_saver_mode_policy_unittest.cc",
      "../browser/performance_manager/policies/page_discarding_helper_unittest.cc",
      "../browser/performance_manager/policies/urgent_page_discarding_policy_unittest.cc",
      "../browser/performance_manager/user_tuning/battery_saver_mode_manager_unittest.cc",
      "../browser/performance_manager/user_tuning/cpu_health_tracker_unittest.cc",
      "../browser/performance_manager/user_tuning/performance_detection_manager_unittest.cc",
      "../browser/performance_manager/user_tuning/profile_discard_opt_out_list_helper_unittest.cc",
      "../browser/performance_manager/user_tuning/user_performance_tuning_manager_unittest.cc",
      "../browser/performance_manager/user_tuning/user_performance_tuning_notifier_unittest.cc",
    ]

    sources += [
      # Background tab loading from performance_manager isn't supported on Android.
      "../browser/performance_manager/policies/background_tab_loading_policy_helpers_unittest.cc",
      "../browser/performance_manager/policies/background_tab_loading_policy_unittest.cc",
    ]

    sources += [
      # The importer code is not used on Android.
      "../common/importer/firefox_importer_utils_unittest.cc",
    ]

    sources += [
      # Android uses different way of showing feedback page
      "../browser/feedback/show_feedback_page_unittest.cc",
      "../browser/feedback/system_logs/log_sources/chrome_internal_log_source_unittest.cc",
      "../browser/feedback/system_logs/log_sources/crash_ids_source_unittest.cc",
      "../browser/feedback/system_logs/log_sources/family_info_log_source_unittest.cc",
      "../browser/feedback/system_logs/log_sources/performance_log_source_unittest.cc",
      "../browser/feedback/system_logs/log_sources/related_website_sets_source_unittest.cc",
    ]

    sources += [
      # NTP is in native code on Android.
      "../browser/new_tab_page/chrome_colors/chrome_colors_service_unittest.cc",
      "../browser/new_tab_page/feature_promo_helper/new_tab_page_feature_promo_helper_unittest.cc",
      "../browser/new_tab_page/modules/file_suggestion/drive_service_unittest.cc",
      "../browser/new_tab_page/modules/new_tab_page_modules_unittest.cc",
      "../browser/new_tab_page/modules/safe_browsing/safe_browsing_handler_unittest.cc",
      "../browser/new_tab_page/modules/test_support.cc",
      "../browser/new_tab_page/modules/test_support.h",
      "../browser/new_tab_page/modules/v2/calendar/google_calendar_page_handler_unittest.cc",
      "../browser/new_tab_page/modules/v2/most_relevant_tab_resumption/most_relevant_tab_resumption_page_handler_unittest.cc",
      "../browser/search/ntp_features_unittest.cc",
    ]

    sources += [
      # Android uses a different way of showing browser windows.
      "../browser/optimization_guide/optimization_guide_tab_url_provider_unittest.cc",
    ]

    if (!is_mac) {
      data_deps += [ "//chrome:packed_resources" ]
    }
    if (is_posix) {
      sources += [ "../browser/process_singleton_posix_unittest.cc" ]
    }

    if (is_linux) {
      deps += [ "//ui/linux:linux_ui_factory" ]
    }
    if (use_ozone) {
      deps += [ "//ui/ozone" ]
    }

    public_deps += [
      "//chrome/browser/ui/views/side_panel",
      "//chrome/browser/ui/views/toolbar",
    ]

    # Non-android deps for "unit_tests" target.
    deps += [
      "../browser/screen_ai:screen_ai_install_state",
      "//chrome:packed_resources_integrity_header",
      "//chrome/browser/apps:icon_standardizer",
      "//chrome/browser/apps/app_service",
      "//chrome/browser/apps/app_service:app_registry_cache_waiter",
      "//chrome/browser/apps/app_service:test_support",
      "//chrome/browser/apps/app_service:unit_tests",
      "//chrome/browser/apps/app_service/app_icon",
      "//chrome/browser/apps/app_service/app_icon:util",
      "//chrome/browser/apps/link_capturing",
      "//chrome/browser/apps/link_capturing:features",
      "//chrome/browser/apps/link_capturing:test_support",
      "//chrome/browser/apps/link_capturing:unit_tests",
      "//chrome/browser/companion:unit_tests",
      "//chrome/browser/companion/core",
      "//chrome/browser/companion/core/mojom:mojo_bindings",
      "//chrome/browser/companion/core/proto",
      "//chrome/browser/companion/visual_query:visual_query",
      "//chrome/browser/enterprise/connectors/analysis:features",
      "//chrome/browser/image_editor:image_editor_component_util",
      "//chrome/browser/image_fetcher",
      "//chrome/browser/lens/core/mojom:mojo_bindings",
      "//chrome/browser/media/router:test_support",
      "//chrome/browser/media/router/discovery:discovery",
      "//chrome/browser/media/router/discovery/access_code:access_code_sink_service",
      "//chrome/browser/media/webrtc:test_support",
      "//chrome/browser/new_tab_page/chrome_colors",
      "//chrome/browser/new_tab_page/modules/v2/calendar:mojo_bindings",
      "//chrome/browser/new_tab_page/modules/v2/most_relevant_tab_resumption:mojo_bindings",
      "//chrome/browser/resource_coordinator:tab_manager_features",
      "//chrome/browser/resources:component_extension_resources_grit",
      "//chrome/browser/resources/new_tab_page_instant:resources_grit",
      "//chrome/browser/search/background",
      "//chrome/browser/search/background:constants",
      "//chrome/browser/support_tool:support_tool_proto",
      "//chrome/browser/task_manager",
      "//chrome/browser/themes",
      "//chrome/browser/ui/actions:unit_tests",
      "//chrome/browser/ui/apps",
      "//chrome/browser/ui/blocked_content",
      "//chrome/browser/ui/color:color_headers",
      "//chrome/browser/ui/color:mixers",
      "//chrome/browser/ui/cookie_controls:unit_tests",
      "//chrome/browser/ui/exclusive_access",
      "//chrome/browser/ui/lens:unit_tests",
      "//chrome/browser/ui/omnibox",
      "//chrome/browser/ui/toasts:unit_tests",
      "//chrome/browser/ui/toasts/api:unit_tests",
      "//chrome/browser/ui/views/bubble",
      "//chrome/browser/ui/webui/cr_components/theme_color_picker",
      "//chrome/browser/ui/webui/discards:mojo_bindings",
      "//chrome/browser/ui/webui/downloads:mojo_bindings",
      "//chrome/browser/ui/webui/new_tab_page:mojo_bindings",
      "//chrome/browser/ui/webui/searchbox",
      "//chrome/browser/ui/webui/side_panel/customize_chrome:mojo_bindings",
      "//chrome/browser/ui/webui/top_chrome",
      "//chrome/browser/ui/webui/top_chrome:test_support",
      "//chrome/browser/ui/zoom",
      "//chrome/browser/ui/zoom:unit_tests",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//chrome/browser/webauthn:test_support",
      "//chrome/browser/webauthn/proto",
      "//chrome/common/accessibility:mojo_bindings",
      "//chrome/services/on_device_translation/public/cpp",
      "//chrome/services/speech:unit_tests",
      "//components/app_constants",
      "//components/color",
      "//components/commerce/core:account_checker_test_support",
      "//components/commerce/core:cart_db_content_proto",
      "//components/commerce/core:commerce_constants",
      "//components/commerce/core:coupon_db_content_proto",
      "//components/commerce/core:shopping_service_test_support",
      "//components/commerce/core/webui:webui",
      "//components/endpoint_fetcher:endpoint_fetcher",
      "//components/endpoint_fetcher:test_support",
      "//components/enterprise",
      "//components/enterprise:test_support",
      "//components/feature_engagement/test:test_support",
      "//components/fullscreen_control",
      "//components/global_media_controls:test_support",
      "//components/global_media_controls/public/mojom:device_service",
      "//components/lens:buildflags",
      "//components/lens:lens_mojo",
      "//components/manta",
      "//components/media_effects:media_effects",
      "//components/media_effects/test:test_support",
      "//components/media_message_center:test_support",
      "//components/media_router/common:test_support",
      "//components/optimization_guide/core",
      "//components/optimization_guide/proto:optimization_guide_proto",
      "//components/permissions:test_support",
      "//components/policy/core/browser",
      "//components/policy/core/common:common_constants",
      "//components/power_bookmarks/core",
      "//components/power_bookmarks/core:features",
      "//components/prefs",
      "//components/safe_browsing/core/browser:safe_browsing_metrics_collector",
      "//components/safe_browsing/core/common:safe_browsing_policy_handler",
      "//components/safety_check:test_support",
      "//components/send_tab_to_self:test_support",
      "//components/services/app_service",
      "//components/services/app_service/public/cpp:test_support",
      "//components/services/app_service/public/cpp:unit_tests",
      "//components/session_proto_db:session_proto_db",
      "//components/signin/public/base:signin_buildflags",
      "//components/soda:constants",
      "//components/supervised_user/core/browser",
      "//components/sync:test_support",
      "//components/user_annotations",
      "//components/user_annotations:test_support",
      "//components/user_education/common",
      "//components/user_education/test",
      "//components/user_notes:features",
      "//components/user_notes/browser",
      "//components/user_notes/interfaces",
      "//components/webapps/browser",
      "//services/device/public/cpp/bluetooth",
      "//services/metrics/public/cpp:ukm_builders",
      "//services/network:test_support",
      "//services/screen_ai:test_support",
      "//services/video_effects/test:test_support",
      "//third_party/crashpad/crashpad/util",
      "//third_party/libaddressinput",
      "//third_party/lzma_sdk/google:unit_tests",
      "//third_party/omnibox_proto",
      "//third_party/zxcvbn-cpp",
      "//ui/base/idle:test_support",
      "//ui/color",
      "//ui/color:color_headers",
      "//ui/color:test_support",
      "//ui/native_theme:test_support",
      "//ui/web_dialogs:web_dialogs_unittests",
      "//ui/webui/resources/cr_components/history_embeddings:mojo_bindings",
      "//ui/webui/resources/js/browser_command:mojo_bindings",
    ]

    data += [ "//ash/components/arc/test/data/icons/" ]

    if (include_js2gtest_tests && is_chromeos_ash) {
      data += js2gtest_js_libraries
      deps +=
          [ "//chrome/browser/resources/chromeos/accessibility:unit_tests_js" ]
    }
  }

  if (!is_android && !is_chromeos) {
    sources += [
      "../browser/device_notifications/device_status_icon_unittest.cc",
      "../browser/device_notifications/device_status_icon_unittest.h",
      "../browser/hid/hid_status_icon_unittest.cc",
      "../browser/usb/usb_status_icon_unittest.cc",
    ]

    deps += [ "//chrome/browser/shortcuts:unit_tests" ]
  }

  if (is_chromeos) {
    sources += [
      "../browser/certificate_provider/certificate_provider_service_unittest.cc",
      "../browser/device_notifications/device_pinned_notification_unittest.cc",
      "../browser/device_notifications/device_pinned_notification_unittest.h",
      "../browser/download/notification/download_item_notification_unittest.cc",
      "../browser/extensions/api/document_scan/document_scan_api_handler_unittest.cc",
      "../browser/extensions/api/document_scan/document_scan_api_unittest.cc",
      "../browser/extensions/api/document_scan/document_scan_type_converters_unittest.cc",
      "../browser/extensions/api/document_scan/fake_document_scan_ash.cc",
      "../browser/extensions/api/document_scan/fake_document_scan_ash.h",
      "../browser/hid/hid_pinned_notification_unittest.cc",
      "../browser/media/platform_verification_chromeos_unittest.cc",
      "../browser/net/network_annotation_monitor_unittest.cc",
      "../browser/performance_manager/policies/oom_score_policy_chromeos_unittest.cc",
      "../browser/performance_manager/policies/report_page_processes_policy_unittest.cc",
      "../browser/policy/annotations/annotation_control_unittest.cc",
      "../browser/policy/annotations/blocklist_handler_unittest.cc",
      "../browser/policy/system_features_disable_list_policy_handler_unittest.cc",
      "../browser/renderer_context_menu/read_write_card_observer_unittest.cc",
      "../browser/speech/tts_crosapi_util_unittest.cc",
      "../browser/supervised_user/chromeos/mock_large_icon_service.cc",
      "../browser/supervised_user/chromeos/mock_large_icon_service.h",
      "../browser/supervised_user/chromeos/supervised_user_favicon_request_handler_unittest.cc",
      "../browser/supervised_user/chromeos/supervised_user_web_content_handler_impl_unittest.cc",
      "../browser/ui/webui/certificate_provisioning_ui_handler_unittest.cc",
      "../browser/usb/usb_pinned_notification_unittest.cc",
    ]

    deps += [
      "//chrome/browser/chromeos",
      "//chrome/browser/chromeos/reporting",
      "//chrome/browser/smart_card:unit_tests",
      "//chrome/browser/ui/chromeos/read_write_cards",
      "//chromeos/components/disks:prefs",
      "//chromeos/dbus/power",
      "//chromeos/dbus/regmon",
      "//components/arc/common",
      "//components/arc/common:arc_intent_helper_constants",
      "//components/arc/common:arc_test_support",
      "//ui/chromeos",

      # Unit tests from subdirectories.
      "//chrome/browser/chromeos:unit_tests",
    ]
  }

  if (is_chromeos_ash) {
    sources -= [
      "../browser/policy/cloud/user_policy_signin_service_unittest.cc",
      "../browser/policy/cloud/user_policy_signin_service_util_unittest.cc",
      "../browser/profiles/gaia_info_update_service_unittest.cc",
      "../browser/ui/webui/settings/settings_manage_profile_handler_unittest.cc",
      "../browser/ui/webui/signin/profile_picker_handler_unittest.cc",

      # Chrome OS uses window_sizer_chromeos_unittest.cc
      "../browser/ui/window_sizer/window_sizer_unittest.cc",
    ]
    sources += [
      "../browser/browser_process_platform_part_ash_unittest.cc",
      "../browser/component_updater/cros_component_installer_chromeos_unittest.cc",
      "../browser/component_updater/metadata_table_chromeos_unittest.cc",
      "../browser/device_identity/chromeos/device_oauth2_token_store_chromeos_unittest.cc",
      "../browser/enterprise/connectors/analysis/file_transfer_analysis_delegate_unittest.cc",
      "../browser/enterprise/connectors/analysis/source_destination_matcher_ash_unittest.cc",
      "../browser/enterprise/connectors/device_trust/ash/ash_attestation_policy_observer_unittest.cc",
      "../browser/enterprise/connectors/device_trust/attestation/ash/ash_attestation_cleanup_manager_unittest.cc",
      "../browser/enterprise/connectors/device_trust/attestation/ash/ash_attestation_service_impl_unittest.cc",
      "../browser/enterprise/connectors/device_trust/signals/ash/ash_signals_filterer_unittest.cc",
      "../browser/enterprise/reporting/android_app_info_generator_unittest.cc",
      "../browser/extensions/api/terminal/startup_status_unittest.cc",
      "../browser/lifetime/application_lifetime_chromeos_unittest.cc",
      "../browser/media/webrtc/chrome_screen_enumerator_ash_unittest.cc",
      "../browser/media/webrtc/desktop_media_list_ash_unittest.cc",
      "../browser/metrics/per_user_state_manager_chromeos_unittest.cc",
      "../browser/metrics/perf/metric_collector_unittest.cc",
      "../browser/metrics/perf/metric_provider_unittest.cc",
      "../browser/metrics/perf/perf_events_collector_unittest.cc",
      "../browser/metrics/perf/perf_output_unittest.cc",
      "../browser/metrics/perf/process_type_collector_unittest.cc",
      "../browser/metrics/perf/profile_provider_chromeos_unittest.cc",
      "../browser/metrics/perf/windowed_incognito_observer_unittest.cc",
      "../browser/metrics/structured/ash_event_storage_unittest.cc",
      "../browser/metrics/structured/cros_events_processor_unittest.cc",
      "../browser/metrics/structured/key_data_provider_ash_unittest.cc",
      "../browser/nearby_sharing/bluetooth_advertising_interval_client_unittest.cc",
      "../browser/nearby_sharing/fast_initiation/fast_initiation_advertiser_unittest.cc",
      "../browser/nearby_sharing/fast_initiation/fast_initiation_scanner_feature_usage_metrics_unittest.cc",
      "../browser/nearby_sharing/fast_initiation/fast_initiation_scanner_unittest.cc",
      "../browser/nearby_sharing/file_attachment_unittest.cc",
      "../browser/nearby_sharing/firewall_hole/nearby_connections_firewall_hole_factory_unittest.cc",
      "../browser/nearby_sharing/incoming_frames_reader_unittest.cc",
      "../browser/nearby_sharing/instantmessaging/fake_token_fetcher.cc",
      "../browser/nearby_sharing/instantmessaging/fake_token_fetcher.h",
      "../browser/nearby_sharing/instantmessaging/receive_messages_express_unittest.cc",
      "../browser/nearby_sharing/instantmessaging/send_message_express_unittest.cc",
      "../browser/nearby_sharing/instantmessaging/stream_parser_unittest.cc",
      "../browser/nearby_sharing/mdns/nearby_connections_mdns_manager_unittest.cc",
      "../browser/nearby_sharing/mock_nearby_sharing_service.cc",
      "../browser/nearby_sharing/mock_nearby_sharing_service.h",
      "../browser/nearby_sharing/nearby_confirmation_manager_unittest.cc",
      "../browser/nearby_sharing/nearby_notification_manager_unittest.cc",
      "../browser/nearby_sharing/nearby_per_session_discovery_manager_unittest.cc",
      "../browser/nearby_sharing/nearby_receive_manager_unittest.cc",
      "../browser/nearby_sharing/nearby_share_delegate_impl_unittest.cc",
      "../browser/nearby_sharing/nearby_share_feature_usage_metrics_unittest.cc",
      "../browser/nearby_sharing/nearby_share_profile_info_provider_impl_unittest.cc",
      "../browser/nearby_sharing/nearby_share_settings_unittest.cc",
      "../browser/nearby_sharing/nearby_share_transfer_profiler_unittest.cc",
      "../browser/nearby_sharing/nearby_sharing_service_impl_unittest.cc",
      "../browser/nearby_sharing/network_traversal_ice_config_fetcher_unittest.cc",
      "../browser/nearby_sharing/paired_key_verification_runner_unittest.cc",
      "../browser/nearby_sharing/payload_tracker_unittest.cc",
      "../browser/nearby_sharing/sharesheet/nearby_share_action_unittest.cc",
      "../browser/nearby_sharing/tachyon_ice_config_fetcher_unittest.cc",
      "../browser/nearby_sharing/tcp_socket/nearby_connections_tcp_socket_factory_unittest.cc",
      "../browser/nearby_sharing/text_attachment_unittest.cc",
      "../browser/nearby_sharing/webrtc_request_builder_unittest.cc",
      "../browser/nearby_sharing/webrtc_signaling_messenger_unittest.cc",
      "../browser/nearby_sharing/wifi_credentials_attachment_unittest.cc",
      "../browser/nearby_sharing/wifi_network_configuration/fake_wifi_network_configuration_handler.cc",
      "../browser/nearby_sharing/wifi_network_configuration/fake_wifi_network_configuration_handler.h",
      "../browser/nearby_sharing/wifi_network_configuration/wifi_network_configuration_handler_unittest.cc",
      "../browser/notifications/chrome_ash_message_center_client_unittest.cc",
      "../browser/notifications/notification_platform_bridge_chromeos_unittest.cc",
      "../browser/notifications/web_page_notifier_controller_unittest.cc",
      "../browser/performance_manager/mechanisms/working_set_trimmer_chromeos_unittest.cc",
      "../browser/performance_manager/policies/working_set_trimmer_policy_arcvm_unittest.cc",
      "../browser/performance_manager/policies/working_set_trimmer_policy_chromeos_unittest.cc",
      "../browser/push_notification/push_notification_service_desktop_impl_unittest.cc",
      "../browser/push_notification/server_client/push_notification_desktop_api_call_flow_impl_unittest.cc",
      "../browser/push_notification/server_client/push_notification_server_client_desktop_impl_unittest.cc",
      "../browser/sharesheet/share_action/share_action_unittest.cc",
      "../browser/speech/cros_speech_recognition_service_factory_unittest.cc",
      "../browser/speech/tts_chromeos_unittest.cc",
      "../browser/speech/tts_controller_delegate_impl_unittest.cc",
      "../browser/support_tool/ash/chrome_user_logs_data_collector_unittest.cc",
      "../browser/support_tool/ash/network_health_data_collector_unittest.cc",
      "../browser/support_tool/ash/network_routes_data_collector_unittest.cc",
      "../browser/support_tool/ash/shill_data_collector_unittest.cc",
      "../browser/support_tool/ash/system_logs_data_collector_unittest.cc",
      "../browser/support_tool/ash/system_state_data_collector_unittest.cc",
      "../browser/support_tool/ash/ui_hierarchy_data_collector_unittest.cc",
      "../browser/task_manager/providers/crosapi/crosapi_task_provider_ash_unittest.cc",
      "../browser/ui/chromeos/magic_boost/magic_boost_card_controller_unittest.cc",
      "../browser/ui/chromeos/magic_boost/magic_boost_opt_in_card_unittest.cc",
      "../browser/ui/chromeos/read_write_cards/read_write_cards_manager_impl_unittest.cc",
      "../browser/ui/chromeos/read_write_cards/read_write_cards_ui_controller_unittest.cc",
      "../browser/ui/quick_answers/quick_answers_controller_unittest.cc",
      "../browser/ui/quick_answers/quick_answers_state_ash_unittest.cc",
      "../browser/ui/quick_answers/quick_answers_ui_controller_unittest.cc",
      "../browser/ui/quick_answers/ui/quick_answers_view_unittest.cc",
      "../browser/ui/views/editor_menu/editor_menu_view_unittest.cc",
      "../browser/ui/views/editor_menu/utils/pre_target_handler_unittest.cc",
      "../browser/ui/views/editor_menu/utils/utils_unittest.cc",
      "../browser/ui/views/mahi/mahi_condensed_menu_view_unittest.cc",
      "../browser/ui/views/mahi/mahi_menu_controller_unittest.cc",
      "../browser/ui/views/mahi/mahi_menu_view_unittest.cc",
      "../browser/ui/webui/help/version_updater_chromeos_unittest.cc",
      "../browser/ui/webui/signin/ash/user_cloud_signin_restriction_policy_fetcher_unittest.cc",
      "../browser/ui/window_sizer/window_sizer_chromeos_unittest.cc",
      "../browser/upgrade_detector/installed_version_updater_chromeos_unittest.cc",
      "../browser/upgrade_detector/upgrade_detector_chromeos_unittest.cc",
      "../common/chrome_constants_ash_unittest.cc",
      "../renderer/chromeos_delayed_callback_group_unittest.cc",
      "base/chromeos/ash_browser_test_starter_unittest.cc",
    ]

    deps += [
      "//ash:test_support",
      "//ash/app_list:test_support",
      "//ash/app_list/model:app_list_model",
      "//ash/assistant/model",
      "//ash/assistant/util",
      "//ash/components/arc",
      "//ash/components/arc:arc_test_support",
      "//ash/public/cpp:test_support",
      "//ash/public/cpp/assistant/test_support",
      "//ash/public/cpp/resources:ash_public_unscaled_resources",
      "//ash/resources/vector_icons",
      "//ash/strings",
      "//ash/webui/annotator:test_support",
      "//ash/webui/annotator/public/mojom:annotator_mojo_bindings",
      "//ash/webui/camera_app_ui",
      "//ash/webui/mall:app_id",
      "//ash/webui/personalization_app/mojom",
      "//ash/webui/projector_app:test_support",
      "//ash/webui/projector_app/public/cpp",
      "//ash/webui/projector_app/public/mojom:projector_mojo_bindings",
      "//ash/webui/scanning",
      "//ash/webui/settings/public/constants:mojom",
      "//chrome/browser/accessibility:test_support",
      "//chrome/browser/accessibility/media_app/test:test_support",
      "//chrome/browser/apps/almanac_api_client:unit_tests",
      "//chrome/browser/apps/app_discovery_service:unit_tests",
      "//chrome/browser/apps/app_preload_service:unit_tests",
      "//chrome/browser/apps/app_service/promise_apps/proto",
      "//chrome/browser/ash",
      "//chrome/browser/ash:unit_tests",
      "//chrome/browser/ash/app_list:unit_tests",
      "//chrome/browser/ash/app_list/app_service",
      "//chrome/browser/ash/app_list/arc:test_support",
      "//chrome/browser/ash/app_list/arc:unit_tests",
      "//chrome/browser/ash/app_list/internal_app",
      "//chrome/browser/ash/app_list/search/ranking:proto",
      "//chrome/browser/ash/app_list/search/test:test_support",
      "//chrome/browser/ash/app_list/search/util:proto",
      "//chrome/browser/ash/app_mode/web_app",
      "//chrome/browser/ash/app_restore",
      "//chrome/browser/ash/apps",
      "//chrome/browser/ash/arc",
      "//chrome/browser/ash/arc/boot_phase_monitor",
      "//chrome/browser/ash/arc/fileapi",
      "//chrome/browser/ash/arc/process",
      "//chrome/browser/ash/arc/session",
      "//chrome/browser/ash/arc/test:arc_test_support",
      "//chrome/browser/ash/arc/vmm",
      "//chrome/browser/ash/attestation",
      "//chrome/browser/ash/attestation:test_support",
      "//chrome/browser/ash/crosapi",
      "//chrome/browser/ash/crosapi:test_support",
      "//chrome/browser/ash/crosapi:unit_tests",
      "//chrome/browser/ash/crostini:test_support",
      "//chrome/browser/ash/customization",
      "//chrome/browser/ash/eche_app",
      "//chrome/browser/ash/extensions",
      "//chrome/browser/ash/file_manager",
      "//chrome/browser/ash/file_manager:test_support",
      "//chrome/browser/ash/file_suggest",
      "//chrome/browser/ash/file_suggest:test_support",
      "//chrome/browser/ash/guest_os",
      "//chrome/browser/ash/input_method",
      "//chrome/browser/ash/login/quick_unlock",
      "//chrome/browser/ash/login/smart_lock",
      "//chrome/browser/ash/login/ui:test_support",
      "//chrome/browser/ash/login/users",
      "//chrome/browser/ash/login/users:test_support",
      "//chrome/browser/ash/login/users/avatar",
      "//chrome/browser/ash/magic_boost",
      "//chrome/browser/ash/magic_boost:test_support",
      "//chrome/browser/ash/multidevice_setup",
      "//chrome/browser/ash/ownership",
      "//chrome/browser/ash/policy/core",
      "//chrome/browser/ash/policy/core:test_support",
      "//chrome/browser/ash/policy/dlp",
      "//chrome/browser/ash/policy/enrollment",
      "//chrome/browser/ash/policy/remote_commands/crd:test_support",
      "//chrome/browser/ash/policy/reporting/metrics_reporting",
      "//chrome/browser/ash/policy/skyvault",
      "//chrome/browser/ash/policy/status_collector",
      "//chrome/browser/ash/policy/uploading",
      "//chrome/browser/ash/printing:test_support",
      "//chrome/browser/ash/release_notes",
      "//chrome/browser/ash/settings",
      "//chrome/browser/ash/settings:test_support",
      "//chrome/browser/ash/smb_client:test_support",
      "//chrome/browser/ash/system_logs",
      "//chrome/browser/ash/system_web_apps/apps",
      "//chrome/browser/ash/system_web_apps/apps/camera_app",
      "//chrome/browser/ash/system_web_apps/apps/help_app",
      "//chrome/browser/ash/system_web_apps/apps/media_app",
      "//chrome/browser/ash/system_web_apps/test_support",
      "//chrome/browser/ash/wallpaper_handlers:test_support",
      "//chrome/browser/chromeos",
      "//chrome/browser/chromeos/launcher_search:search_util",
      "//chrome/browser/enterprise/connectors/device_trust/attestation/ash",
      "//chrome/browser/metrics/structured:features",
      "//chrome/browser/nearby_sharing:share_target",
      "//chrome/browser/nearby_sharing/certificates",
      "//chrome/browser/nearby_sharing/certificates:test_support",
      "//chrome/browser/nearby_sharing/certificates:unit_tests",
      "//chrome/browser/nearby_sharing/client:unit_tests",
      "//chrome/browser/nearby_sharing/common",
      "//chrome/browser/nearby_sharing/common:unit_tests",
      "//chrome/browser/nearby_sharing/contacts",
      "//chrome/browser/nearby_sharing/contacts:test_support",
      "//chrome/browser/nearby_sharing/contacts:unit_tests",
      "//chrome/browser/nearby_sharing/instantmessaging/proto",
      "//chrome/browser/nearby_sharing/local_device_data",
      "//chrome/browser/nearby_sharing/local_device_data:test_support",
      "//chrome/browser/nearby_sharing/local_device_data:unit_tests",
      "//chrome/browser/nearby_sharing/proto:tachyon_proto",
      "//chrome/browser/policy:onc",
      "//chrome/browser/policy:unit_tests",
      "//chrome/browser/push_notification",
      "//chrome/browser/push_notification:test_support",
      "//chrome/browser/push_notification/protos:proto",
      "//chrome/browser/screen_ai:unit_tests",
      "//chrome/browser/screen_ai/public:test_support",
      "//chrome/browser/task_manager:impl",
      "//chrome/browser/ui/ash",
      "//chrome/browser/ui/ash:test_support",
      "//chrome/browser/ui/ash:unit_tests",
      "//chrome/browser/ui/ash/assistant",
      "//chrome/browser/ui/ash/holding_space",
      "//chrome/browser/ui/ash/holding_space:test_support",
      "//chrome/browser/ui/ash/multi_user",
      "//chrome/browser/ui/ash/session:test_support",
      "//chrome/browser/ui/ash/shelf",
      "//chrome/browser/ui/ash/system",
      "//chrome/browser/ui/ash/wallpaper",
      "//chrome/browser/ui/ash/wallpaper:test_support",
      "//chrome/browser/ui/chromeos/magic_boost",
      "//chrome/browser/ui/chromeos/magic_boost:magic_boost_constants",
      "//chrome/browser/ui/chromeos/magic_boost:test_support",
      "//chrome/browser/ui/chromeos/read_write_cards",
      "//chrome/browser/ui/chromeos/read_write_cards:read_write_cards_manager",
      "//chrome/browser/ui/quick_answers",
      "//chrome/browser/ui/quick_answers/test:mock_quick_answers_client",
      "//chrome/browser/ui/quick_answers/ui:result_view",
      "//chrome/browser/ui/quick_answers/ui:retry_view",
      "//chrome/browser/ui/views/crostini",
      "//chrome/browser/ui/views/crostini:unit_tests",
      "//chrome/browser/ui/views/editor_menu",
      "//chrome/browser/ui/views/editor_menu:utils",
      "//chrome/browser/ui/views/editor_menu:views",
      "//chrome/browser/ui/views/mahi",
      "//chrome/browser/ui/webui/ash:unit_tests",
      "//chrome/browser/ui/webui/ash/add_supervision",
      "//chrome/browser/ui/webui/ash/enterprise_reporting:mojo_bindings",
      "//chrome/browser/ui/webui/ash/login",
      "//chrome/browser/ui/webui/ash/settings",
      "//chrome/browser/ui/webui/ash/smb_shares",
      "//chrome/browser/ui/webui/nearby_share:mojom",
      "//chrome/services/pdf:pdf_progressive_searchifier_test",
      "//chrome/services/pdf:pdf_searchifier_test",
      "//chrome/services/pdf:pdf_thumbnailer_test",
      "//chrome/services/sharing:unit_tests",
      "//chrome/services/sharing/nearby:unit_tests",
      "//chrome/services/sharing/nearby/decoder",
      "//chrome/services/sharing/nearby/decoder:unit_tests",
      "//chrome/services/sharing/nearby/platform:unit_tests",
      "//chrome/services/sharing/nearby/quick_start_decoder:unit_tests",
      "//chrome/services/sharing/public/cpp",
      "//chrome/services/sharing/public/cpp:unit_tests",
      "//chromeos/ash/components/assistant:buildflags",
      "//chromeos/ash/components/audio",
      "//chromeos/ash/components/browser_context_helper",
      "//chromeos/ash/components/carrier_lock",
      "//chromeos/ash/components/cryptohome",
      "//chromeos/ash/components/dbus",
      "//chromeos/ash/components/dbus/attestation",
      "//chromeos/ash/components/dbus/cicerone",
      "//chromeos/ash/components/dbus/concierge",
      "//chromeos/ash/components/dbus/cros_disks",
      "//chromeos/ash/components/dbus/debug_daemon",
      "//chromeos/ash/components/dbus/federated",
      "//chromeos/ash/components/dbus/hermes",
      "//chromeos/ash/components/dbus/image_loader",
      "//chromeos/ash/components/dbus/seneschal",
      "//chromeos/ash/components/dbus/shill",
      "//chromeos/ash/components/dbus/spaced",
      "//chromeos/ash/components/dbus/update_engine",
      "//chromeos/ash/components/dbus/update_engine:proto",
      "//chromeos/ash/components/disks",
      "//chromeos/ash/components/disks:test_support",
      "//chromeos/ash/components/feature_usage",
      "//chromeos/ash/components/login/auth:test_support",
      "//chromeos/ash/components/login/login_state:test_support",
      "//chromeos/ash/components/login/session",
      "//chromeos/ash/components/multidevice:test_support",
      "//chromeos/ash/components/nearby/common/connections_manager:test_support",
      "//chromeos/ash/components/nearby/common/scheduling:test_support",
      "//chromeos/ash/components/proximity_auth",
      "//chromeos/ash/components/proximity_auth:test_support",
      "//chromeos/ash/components/scalable_iph:constants",
      "//chromeos/ash/components/standalone_browser:standalone_browser",
      "//chromeos/ash/components/standalone_browser:test_support",
      "//chromeos/ash/components/string_matching",
      "//chromeos/ash/components/sync_wifi",
      "//chromeos/ash/components/system",
      "//chromeos/ash/services/assistant/public/cpp",
      "//chromeos/ash/services/device_sync/public/cpp:test_support",
      "//chromeos/ash/services/federated/public/cpp:test_support",
      "//chromeos/ash/services/multidevice_setup/public/cpp:test_support",
      "//chromeos/ash/services/nearby/public/cpp:tcp_server_socket_port",
      "//chromeos/ash/services/nearby/public/cpp:test_support",
      "//chromeos/ash/services/nearby/public/mojom",
      "//chromeos/ash/services/network_config",
      "//chromeos/ash/services/network_config:in_process_instance",
      "//chromeos/ash/services/secure_channel/public/cpp/client:test_support",
      "//chromeos/components/editor_menu/public/cpp",
      "//chromeos/components/kiosk:kiosk",
      "//chromeos/components/magic_boost/public/cpp:cpp",
      "//chromeos/components/magic_boost/test:fake_magic_boost_state",
      "//chromeos/components/onc",
      "//chromeos/components/quick_answers:quick_answers",
      "//chromeos/components/quick_answers/public/cpp:constants",
      "//chromeos/components/quick_answers/public/cpp:cpp",
      "//chromeos/components/quick_answers/public/cpp:prefs",
      "//chromeos/constants",
      "//chromeos/dbus/permission_broker",
      "//chromeos/dbus/u2f",
      "//chromeos/ime:gencode",
      "//chromeos/services/assistant/public/shared",
      "//chromeos/strings",
      "//chromeos/ui/base",
      "//chromeos/ui/frame",
      "//chromeos/ui/wm",
      "//components/app_constants",
      "//components/app_restore:unit_tests",
      "//components/arc:arc_test_support",
      "//components/arc/common",
      "//components/cross_device/nearby:nearby",
      "//components/metrics/structured:structured_events",
      "//components/metrics/structured:structured_metrics_features",
      "//components/metrics/structured:test_support",
      "//components/metrics/structured/lib",
      "//components/omnibox/browser:vector_icons",
      "//components/push_notification:test_support",
      "//components/services/app_service",
      "//components/session_manager/core",
      "//components/soda:soda",
      "//components/webapk:proto",
      "//mojo/public/cpp/test_support:test_utils",
      "//third_party/nearby:rpc_resources_proto",
      "//third_party/nearby:wire_format_proto",
      "//ui/base/ime/ash",
      "//ui/chromeos/strings",
      "//ui/file_manager:resources_grit",
      "//ui/webui/resources/cr_components/app_management:unit_tests",
      "//ui/wm/public",
    ]

    data_deps += [ "//testing/buildbot/filters:chromeos_filters" ]

    if (target_cpu == "x64") {
      sources += [ "../browser/performance_manager/policies/userspace_swap_policy_chromeos_unittest.cc" ]

      deps += [
        "//chromeos/ash/components/memory/userspace_swap",
        "//chromeos/ash/components/memory/userspace_swap:mojom",
      ]
    }
  }

  if (is_chromeos_lacros) {
    sources += [
      "../browser/lacros/account_manager/account_manager_util_unittest.cc",
      "../browser/lacros/account_manager/account_profile_mapper_unittest.cc",
      "../browser/lacros/account_manager/get_account_information_helper_unittest.cc",
      "../browser/lacros/account_manager/profile_account_manager_unittest.cc",
      "../browser/lacros/account_manager/signin_helper_lacros_unittest.cc",
      "../browser/lacros/app_mode/web_kiosk_installer_lacros_unittest.cc",
      "../browser/lacros/cert/client_cert_store_lacros_unittest.cc",
      "../browser/lacros/clipboard_history_lacros_unittest.cc",
      "../browser/lacros/device_settings_lacros_unittest.cc",
      "../browser/lacros/force_installed_tracker_lacros_unittest.cc",
      "../browser/lacros/fullscreen_controller_client_lacros_unittest.cc",
      "../browser/lacros/guest_os/vm_sk_forwarding_native_message_host_unittest.cc",
      "../browser/lacros/lacros_memory_pressure_evaluator_unittest.cc",
      "../browser/lacros/lacros_url_handling_unittest.cc",
      "../browser/lacros/metrics_reporting_observer_unittest.cc",
      "../browser/lacros/net/network_settings_translation_unittest.cc",
      "../browser/lacros/prefs_ash_observer_unittest.cc",
      "../browser/lacros/remote_apps/remote_apps_proxy_lacros_unittest.cc",
      "../browser/lacros/suggestion_service_lacros_unittest.cc",
      "../browser/lacros/sync/crosapi_session_sync_favicon_delegate_unittest.cc",
      "../browser/lacros/sync/crosapi_session_sync_notifier_unittest.cc",
      "../browser/lacros/sync/sync_explicit_passphrase_client_lacros_unittest.cc",
      "../browser/lacros/sync/sync_user_settings_client_lacros_unittest.cc",
      "../browser/lacros/trusted_vault/crosapi_trusted_vault_client_unittest.cc",
      "../browser/media/webrtc/chrome_screen_enumerator_lacros_unittest.cc",
      "../browser/metrics/lacros_metrics_provider_unittest.cc",
      "../browser/notifications/notification_platform_bridge_lacros_unittest.cc",
      "../browser/policy/restricted_mgs_policy_provider_lacros_unittest.cc",
      "../browser/signin/signin_ui_delegate_impl_lacros_unittest.cc",
      "../browser/ui/media_router/cast_notification_controller_lacros_unittest.cc",
      "../browser/upgrade_detector/get_installed_version_lacros_unittest.cc",
      "../common/chrome_paths_lacros_unittest.cc",
    ]

    deps += [
      "//chrome/browser/policy:onc",
      "//chrome/browser/policy:unit_tests",
      "//chrome/browser/web_applications/app_service:test_support",
      "//chromeos/components/onc:onc",
      "//chromeos/crosapi/mojom",
      "//chromeos/dbus/dlp:dlp",
      "//chromeos/lacros:test_support",
      "//chromeos/startup",
      "//chromeos/ui/base",
      "//chromeos/ui/wm",
      "//components/account_manager_core",
      "//components/account_manager_core:test_support",
      "//components/enterprise/data_controls/core/browser:dlp_policy_event_proto",
      "//components/reporting/metrics:metrics_data_collection",
      "//components/reporting/metrics/fakes:test_support",
    ]
  }

  if (is_linux || is_chromeos) {
    deps += [ "//chrome/browser/error_reporting:unit_test" ]
  }

  if (use_ozone) {
    deps += [ "//ui/events/devices:test_support" ]
  }

  if (enable_click_to_call && !is_android) {
    sources += [
      "../browser/sharing/click_to_call/click_to_call_context_menu_observer_unittest.cc",
      "../browser/sharing/click_to_call/click_to_call_ui_controller_unittest.cc",
      "../browser/sharing/click_to_call/click_to_call_utils_unittest.cc",
    ]
  }

  if (enable_background_contents) {
    sources +=
        [ "../browser/background/background_contents_service_unittest.cc" ]
  }
  if (enable_background_mode) {
    sources += [
      "../browser/background/background_application_list_model_unittest.cc",
      "../browser/background/background_mode_manager_unittest.cc",
      "../browser/background/background_mode_optimizer_unittest.cc",
    ]
  }

  if (enable_spellcheck) {
    sources +=
        [ "../browser/spellchecker/spellcheck_custom_dictionary_unittest.cc" ]

    if (is_chromeos || is_linux || is_win) {
      sources += [ "../browser/spellchecker/spellcheck_language_policy_handlers_unittest.cc" ]
    }

    if (is_mac) {
      sources += [
        "../browser/spellchecker/spell_check_host_chrome_impl_mac_unittest.cc",
      ]
    } else {
      sources += [
        # This tests the function GetSpellCheckLanguages which is not used on
        # Mac.
        "../browser/spellchecker/spellcheck_service_unittest.cc",

        # This tests Chrome's spellchecker which Mac doesn't use.
        "../tools/convert_dict/aff_reader_unittest.cc",
        "../tools/convert_dict/convert_dict_unittest.cc",
      ]
    }

    data += [
      "data/convert_dict/affix-flags.aff",
      "data/convert_dict/empty.aff",
      "data/convert_dict/indexed-affix.aff",
      "data/convert_dict/leading-comment.aff",
      "data/convert_dict/other-commands.aff",
      "data/convert_dict/prefix-suffix.aff",
      "data/convert_dict/rep.aff",
    ]

    if (use_renderer_spellchecker) {
      sources +=
          [ "../browser/spellchecker/spell_check_host_chrome_impl_unittest.cc" ]
    }

    if (enable_spelling_service) {
      sources +=
          [ "../browser/spellchecker/spelling_service_client_unittest.cc" ]
    }

    if (use_browser_spellchecker && enable_spelling_service) {
      sources += [ "../browser/spellchecker/spelling_request_unittest.cc" ]
    }
  }

  # TODO(crbug.com/1229899): Clean up and move this to a separate target.
  if (enable_extensions) {
    sources += [
      "../../apps/saved_files_service_unittest.cc",
      "../../tools/json_schema_compiler/test/features_generation_unittest.cc",
      "../browser/autocomplete/keyword_extensions_delegate_impl_unittest.cc",
      "../browser/browsing_data/counters/hosted_apps_counter_unittest.cc",
      "../browser/controlled_frame/controlled_frame_menu_icon_loader_unittest.cc",
      "../browser/extensions/activity_log/activity_database_unittest.cc",
      "../browser/extensions/activity_log/activity_log_enabled_unittest.cc",
      "../browser/extensions/activity_log/activity_log_policy_unittest.cc",
      "../browser/extensions/activity_log/activity_log_unittest.cc",
      "../browser/extensions/activity_log/counting_policy_unittest.cc",
      "../browser/extensions/activity_log/database_string_table_unittest.cc",
      "../browser/extensions/activity_log/fullstream_ui_policy_unittest.cc",
      "../browser/extensions/api/activity_log_private/activity_log_private_api_unittest.cc",
      "../browser/extensions/api/bookmark_manager_private/bookmark_manager_private_api_unittest.cc",
      "../browser/extensions/api/bookmarks/bookmark_api_helpers_unittest.cc",
      "../browser/extensions/api/bookmarks/bookmarks_api_unittest.cc",
      "../browser/extensions/api/browsing_data/browsing_data_unittest.cc",
      "../browser/extensions/api/chrome_extensions_api_client_unittest.cc",
      "../browser/extensions/api/cookies/cookies_helpers_unittest.cc",
      "../browser/extensions/api/cookies/cookies_unittest.cc",
      "../browser/extensions/api/declarative/rules_registry_service_unittest.cc",
      "../browser/extensions/api/declarative/rules_registry_with_cache_unittest.cc",
      "../browser/extensions/api/declarative_content/chrome_content_rules_registry_unittest.cc",
      "../browser/extensions/api/declarative_content/content_action_unittest.cc",
      "../browser/extensions/api/declarative_content/content_condition_unittest.cc",
      "../browser/extensions/api/declarative_content/declarative_content_condition_tracker_test.cc",
      "../browser/extensions/api/declarative_content/declarative_content_condition_tracker_test.h",
      "../browser/extensions/api/declarative_content/declarative_content_css_condition_tracker_unittest.cc",
      "../browser/extensions/api/declarative_content/declarative_content_is_bookmarked_condition_tracker_unittest.cc",
      "../browser/extensions/api/declarative_content/declarative_content_page_url_condition_tracker_unittest.cc",
      "../browser/extensions/api/declarative_net_request/action_tracker_unittest.cc",
      "../browser/extensions/api/declarative_net_request/declarative_net_request_unittest.cc",
      "../browser/extensions/api/declarative_net_request/dnr_test_base.cc",
      "../browser/extensions/api/declarative_net_request/dnr_test_base.h",
      "../browser/extensions/api/declarative_net_request/ruleset_manager_unittest.cc",
      "../browser/extensions/api/declarative_webrequest/webrequest_action_unittest.cc",
      "../browser/extensions/api/declarative_webrequest/webrequest_rules_registry_unittest.cc",
      "../browser/extensions/api/developer_private/developer_private_api_unittest.cc",
      "../browser/extensions/api/developer_private/extension_info_generator_unittest.cc",
      "../browser/extensions/api/device_permissions_manager_unittest.cc",
      "../browser/extensions/api/downloads/downloads_api_unittest.cc",
      "../browser/extensions/api/enterprise_hardware_platform/enterprise_hardware_platform_api_unittest.cc",
      "../browser/extensions/api/enterprise_reporting_private/enterprise_reporting_private_unittest.cc",
      "../browser/extensions/api/extension_action/extension_action_api_unittest.cc",
      "../browser/extensions/api/file_system/file_system_api_unittest.cc",
      "../browser/extensions/api/gcm/extension_gcm_app_handler_unittest.cc",
      "../browser/extensions/api/identity/extension_token_key_unittest.cc",
      "../browser/extensions/api/identity/gaia_remote_consent_flow_unittest.cc",
      "../browser/extensions/api/identity/identity_api_unittest.cc",
      "../browser/extensions/api/identity/identity_mint_queue_unittest.cc",
      "../browser/extensions/api/identity/identity_token_cache_unittest.cc",
      "../browser/extensions/api/image_writer_private/destroy_partitions_operation_unittest.cc",
      "../browser/extensions/api/image_writer_private/extractor_unittest.cc",
      "../browser/extensions/api/image_writer_private/image_writer_private_api_unittest.cc",
      "../browser/extensions/api/image_writer_private/operation_manager_unittest.cc",
      "../browser/extensions/api/image_writer_private/operation_unittest.cc",
      "../browser/extensions/api/image_writer_private/test_utils.cc",
      "../browser/extensions/api/image_writer_private/test_utils.h",
      "../browser/extensions/api/image_writer_private/write_from_file_operation_unittest.cc",
      "../browser/extensions/api/image_writer_private/write_from_url_operation_unittest.cc",
      "../browser/extensions/api/language_settings_private/language_settings_private_api_unittest.cc",
      "../browser/extensions/api/language_settings_private/language_settings_private_delegate_unittest.cc",
      "../browser/extensions/api/management/management_api_unittest.cc",
      "../browser/extensions/api/notifications/extension_notification_handler_unittest.cc",
      "../browser/extensions/api/omnibox/omnibox_unittest.cc",
      "../browser/extensions/api/omnibox/suggestion_parser_unittest.cc",
      "../browser/extensions/api/page_capture/page_capture_api_unittest.cc",
      "../browser/extensions/api/passwords_private/password_access_auth_timeout_handler_unittest.cc",
      "../browser/extensions/api/passwords_private/password_check_delegate_unittest.cc",
      "../browser/extensions/api/passwords_private/passwords_private_delegate_impl_unittest.cc",
      "../browser/extensions/api/passwords_private/passwords_private_utils_unittest.cc",
      "../browser/extensions/api/permissions/permissions_api_unittest.cc",
      "../browser/extensions/api/preference/preference_api_prefs_unittest.cc",
      "../browser/extensions/api/proxy/proxy_api_helpers_unittest.cc",
      "../browser/extensions/api/reading_list/reading_list_api_unittest.cc",
      "../browser/extensions/api/runtime/chrome_runtime_api_delegate_unittest.cc",
      "../browser/extensions/api/safe_browsing_private/safe_browsing_private_api_unittest.cc",
      "../browser/extensions/api/safe_browsing_private/safe_browsing_util_unittest.cc",
      "../browser/extensions/api/search/search_api_unittest.cc",
      "../browser/extensions/api/settings_private/generated_pref_test_base.cc",
      "../browser/extensions/api/settings_private/generated_pref_test_base.h",
      "../browser/extensions/api/settings_private/settings_private_event_router_unittest.cc",
      "../browser/extensions/api/socket/socket_api_unittest.cc",
      "../browser/extensions/api/socket/tcp_socket_unittest.cc",
      "../browser/extensions/api/socket/tls_socket_unittest.cc",
      "../browser/extensions/api/socket/udp_socket_unittest.cc",
      "../browser/extensions/api/sockets_tcp_server/sockets_tcp_server_api_unittest.cc",
      "../browser/extensions/api/storage/managed_value_store_cache_unittest.cc",
      "../browser/extensions/api/storage/policy_value_store_unittest.cc",
      "../browser/extensions/api/storage/settings_sync_unittest.cc",
      "../browser/extensions/api/storage/storage_session_unittest.cc",
      "../browser/extensions/api/streams_private/streams_private_manifest_unittest.cc",
      "../browser/extensions/api/tab_groups/tab_groups_api_unittest.cc",
      "../browser/extensions/api/tabs/tabs_api_unittest.cc",
      "../browser/extensions/api/tabs/windows_util_unittest.cc",
      "../browser/extensions/api/web_navigation/frame_navigation_state_unittest.cc",
      "../browser/extensions/api/web_request/web_request_api_unittest.cc",
      "../browser/extensions/api/web_request/web_request_event_details_unittest.cc",
      "../browser/extensions/api/web_request/web_request_permissions_unittest.cc",
      "../browser/extensions/api/webstore_private/extension_install_status_unittest.cc",
      "../browser/extensions/api/webstore_private/webstore_private_unittest.cc",
      "../browser/extensions/blocklist_check_unittest.cc",
      "../browser/extensions/blocklist_extension_prefs_unittest.cc",
      "../browser/extensions/blocklist_state_fetcher_unittest.cc",
      "../browser/extensions/blocklist_states_interaction_unittest.cc",
      "../browser/extensions/chrome_app_icon_unittest.cc",
      "../browser/extensions/chrome_app_sorting_unittest.cc",
      "../browser/extensions/chrome_component_extension_resource_manager_unittest.cc",
      "../browser/extensions/chrome_content_verifier_unittest.cc",
      "../browser/extensions/chrome_extension_function_unittest.cc",
      "../browser/extensions/component_loader_unittest.cc",
      "../browser/extensions/context_menu_matcher_unittest.cc",
      "../browser/extensions/convert_user_script_unittest.cc",
      "../browser/extensions/corrupted_extension_reinstaller_unittest.cc",
      "../browser/extensions/cws_info_service_unittest.cc",
      "../browser/extensions/error_console/error_console_unittest.cc",
      "../browser/extensions/event_router_forwarder_unittest.cc",
      "../browser/extensions/extension_action_icon_factory_unittest.cc",
      "../browser/extensions/extension_action_runner_unittest.cc",
      "../browser/extensions/extension_allowlist_unittest.cc",
      "../browser/extensions/extension_context_menu_model_unittest.cc",
      "../browser/extensions/extension_error_controller_unittest.cc",
      "../browser/extensions/extension_error_ui_default_unittest.cc",
      "../browser/extensions/extension_garbage_collector_unittest.cc",
      "../browser/extensions/extension_install_prompt_unittest.cc",
      "../browser/extensions/extension_management_unittest.cc",
      "../browser/extensions/extension_migrator_unittest.cc",
      "../browser/extensions/extension_navigation_throttle_unittest.cc",
      "../browser/extensions/extension_prefs_unittest.cc",
      "../browser/extensions/extension_prefs_unittest.h",
      "../browser/extensions/extension_protocols_unittest.cc",
      "../browser/extensions/extension_safety_check_utils_unittest.cc",
      "../browser/extensions/extension_service_sync_unittest.cc",
      "../browser/extensions/extension_service_unittest.cc",
      "../browser/extensions/extension_special_storage_policy_unittest.cc",
      "../browser/extensions/extension_sync_data_unittest.cc",
      "../browser/extensions/extension_tab_util_unittest.cc",
      "../browser/extensions/extension_telemetry_service_verdict_handler_unittest.cc",
      "../browser/extensions/extension_test_message_listener_unittest.cc",
      "../browser/extensions/extension_user_script_loader_unittest.cc",
      "../browser/extensions/extension_util_unittest.cc",
      "../browser/extensions/extension_web_ui_unittest.cc",
      "../browser/extensions/external_policy_loader_unittest.cc",
      "../browser/extensions/external_provider_impl_unittest.cc",
      "../browser/extensions/favicon/favicon_util_unittest.cc",
      "../browser/extensions/forced_extensions/force_installed_metrics_unittest.cc",
      "../browser/extensions/forced_extensions/force_installed_test_base.cc",
      "../browser/extensions/forced_extensions/force_installed_test_base.h",
      "../browser/extensions/forced_extensions/force_installed_tracker_unittest.cc",
      "../browser/extensions/install_tracker_unittest.cc",
      "../browser/extensions/install_verifier_unittest.cc",
      "../browser/extensions/installed_loader_unittest.cc",
      "../browser/extensions/manifest_v2_experiment_manager_unittest.cc",
      "../browser/extensions/menu_manager_unittest.cc",
      "../browser/extensions/mv2_deprecation_impact_checker_unittest.cc",
      "../browser/extensions/omaha_attributes_handler_unittest.cc",
      "../browser/extensions/pack_extension_unittest.cc",
      "../browser/extensions/permission_message_combinations_unittest.cc",
      "../browser/extensions/permission_messages_unittest.cc",
      "../browser/extensions/permissions/active_tab_unittest.cc",
      "../browser/extensions/permissions/permissions_helpers_unittest.cc",
      "../browser/extensions/permissions/permissions_manager_unittest.cc",
      "../browser/extensions/permissions/permissions_updater_unittest.cc",
      "../browser/extensions/permissions/scripting_permissions_modifier_unittest.cc",
      "../browser/extensions/permissions/site_access_requests_helper_unittest.cc",
      "../browser/extensions/permissions/site_permissions_helper_unittest.cc",
      "../browser/extensions/permissions_based_management_policy_provider_unittest.cc",
      "../browser/extensions/policy_handlers_unittest.cc",
      "../browser/extensions/preinstalled_apps_unittest.cc",
      "../browser/extensions/profile_util_unittest.cc",
      "../browser/extensions/safe_browsing_verdict_handler_unittest.cc",
      "../browser/extensions/shared_module_service_unittest.cc",
      "../browser/extensions/standard_management_policy_provider_unittest.cc",
      "../browser/extensions/tab_helper_unittest.cc",
      "../browser/extensions/unpacked_installer_unittest.cc",
      "../browser/extensions/update_install_gate_unittest.cc",
      "../browser/extensions/updater/extension_update_client_command_line_config_policy_unittest.cc",
      "../browser/extensions/updater/extension_updater_switches_unittest.cc",
      "../browser/extensions/updater/extension_updater_unittest.cc",
      "../browser/extensions/user_script_listener_unittest.cc",
      "../browser/extensions/user_script_world_configuration_manager_unittest.cc",
      "../browser/extensions/warning_badge_service_unittest.cc",
      "../browser/extensions/webstore_installer_unittest.cc",
      "../browser/extensions/zipfile_installer_unittest.cc",
      "../browser/media/cast_mirroring_service_host_unittest.cc",
      "../browser/metrics/extensions_metrics_provider_unittest.cc",
      "../browser/policy/chrome_extension_policy_migrator_unittest.cc",
      "../browser/renderer_context_menu/context_menu_content_type_unittest.cc",
      "../browser/safe_browsing/test_extension_event_observer.cc",
      "../browser/safe_browsing/test_extension_event_observer.h",
      "../browser/supervised_user/extension_icon_loader_unittest.cc",
      "../browser/supervised_user/supervised_user_extension_unittest.cc",
      "../browser/supervised_user/supervised_user_extensions_manager_unittest.cc",
      "../browser/supervised_user/supervised_user_url_filter_extensions_unittest.cc",
      "../browser/sync/glue/extensions_activity_monitor_unittest.cc",
      "../browser/sync_file_system/drive_backend/callback_helper_unittest.cc",
      "../browser/sync_file_system/drive_backend/callback_tracker_unittest.cc",
      "../browser/sync_file_system/drive_backend/conflict_resolver_unittest.cc",
      "../browser/sync_file_system/drive_backend/drive_backend_sync_unittest.cc",
      "../browser/sync_file_system/drive_backend/drive_backend_test_util.cc",
      "../browser/sync_file_system/drive_backend/drive_backend_test_util.h",
      "../browser/sync_file_system/drive_backend/fake_drive_service_helper.cc",
      "../browser/sync_file_system/drive_backend/fake_drive_service_helper.h",
      "../browser/sync_file_system/drive_backend/fake_drive_uploader.cc",
      "../browser/sync_file_system/drive_backend/fake_drive_uploader.h",
      "../browser/sync_file_system/drive_backend/fake_sync_worker.cc",
      "../browser/sync_file_system/drive_backend/fake_sync_worker.h",
      "../browser/sync_file_system/drive_backend/leveldb_wrapper_unittest.cc",
      "../browser/sync_file_system/drive_backend/list_changes_task_unittest.cc",
      "../browser/sync_file_system/drive_backend/local_to_remote_syncer_unittest.cc",
      "../browser/sync_file_system/drive_backend/metadata_database_index_on_disk_unittest.cc",
      "../browser/sync_file_system/drive_backend/metadata_database_index_unittest.cc",
      "../browser/sync_file_system/drive_backend/metadata_database_unittest.cc",
      "../browser/sync_file_system/drive_backend/metadata_db_migration_util_unittest.cc",
      "../browser/sync_file_system/drive_backend/register_app_task_unittest.cc",
      "../browser/sync_file_system/drive_backend/remote_to_local_syncer_unittest.cc",
      "../browser/sync_file_system/drive_backend/sync_engine_initializer_unittest.cc",
      "../browser/sync_file_system/drive_backend/sync_engine_unittest.cc",
      "../browser/sync_file_system/drive_backend/sync_task_manager_unittest.cc",
      "../browser/sync_file_system/drive_backend/sync_worker_unittest.cc",
      "../browser/sync_file_system/drive_backend/task_dependency_manager_unittest.cc",
      "../browser/sync_file_system/fake_remote_change_processor.cc",
      "../browser/sync_file_system/fake_remote_change_processor.h",
      "../browser/sync_file_system/file_change_unittest.cc",
      "../browser/sync_file_system/local/canned_syncable_file_system.cc",
      "../browser/sync_file_system/local/canned_syncable_file_system.h",
      "../browser/sync_file_system/local/local_file_change_tracker_unittest.cc",
      "../browser/sync_file_system/local/local_file_sync_context_unittest.cc",
      "../browser/sync_file_system/local/local_file_sync_service_unittest.cc",
      "../browser/sync_file_system/local/local_file_sync_status_unittest.cc",
      "../browser/sync_file_system/local/mock_sync_status_observer.cc",
      "../browser/sync_file_system/local/mock_sync_status_observer.h",
      "../browser/sync_file_system/local/syncable_file_operation_runner_unittest.cc",
      "../browser/sync_file_system/local/syncable_file_system_unittest.cc",
      "../browser/sync_file_system/logger_unittest.cc",
      "../browser/sync_file_system/mock_remote_change_processor.cc",
      "../browser/sync_file_system/mock_remote_change_processor.h",
      "../browser/sync_file_system/subtree_set_unittest.cc",
      "../browser/sync_file_system/sync_file_system_service_unittest.cc",
      "../browser/sync_file_system/sync_file_system_test_util.cc",
      "../browser/sync_file_system/sync_file_system_test_util.h",
      "../browser/sync_file_system/sync_process_runner_unittest.cc",
      "../browser/sync_file_system/syncable_file_system_util_unittest.cc",
      "../browser/ui/webui/extensions/extensions_internals_unittest.cc",
      "../common/apps/platform_apps/media_galleries_permission_unittest.cc",
      "../common/extensions/api/common_extension_api_unittest.cc",
      "../common/extensions/api/extension_action/browser_action_manifest_unittest.cc",
      "../common/extensions/api/speech/tts_engine_manifest_handler_unittest.cc",
      "../common/extensions/api/storage/storage_schema_manifest_handler_unittest.cc",
      "../common/extensions/api/url_handlers/url_handlers_parser_unittest.cc",
      "../common/extensions/chrome_extensions_client_unittest.cc",
      "../common/extensions/chrome_manifest_url_handlers_unittest.cc",
      "../common/extensions/extension_unittest.cc",
      "../common/extensions/manifest_handlers/automation_unittest.cc",
      "../common/extensions/manifest_handlers/content_scripts_manifest_unittest.cc",
      "../common/extensions/manifest_handlers/exclude_matches_manifest_unittest.cc",
      "../common/extensions/manifest_handlers/natively_connectable_handler_unittest.cc",
      "../common/extensions/manifest_handlers/settings_overrides_handler_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_background_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_chromepermission_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_contentsecuritypolicy_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_default_extent_path_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_devtools_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_experimental_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_icons_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_initvalue_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_kiosk_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_launch_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_manifest_version_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_name_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_offline_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_old_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_options_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_override_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_platformapp_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_portsinpermissions_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_sample_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_side_panel_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_ui_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_validapp_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_web_accessible_resources_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_web_unittest.cc",
      "../common/extensions/manifest_tests/extension_manifests_webview_accessible_resources_unittest.cc",
      "../common/extensions/manifest_tests/permissions_parser_unittest.cc",
      "../common/extensions/manifest_unittest.cc",
      "../common/extensions/permissions/chrome_api_permissions_unittest.cc",
      "../common/extensions/permissions/chrome_permission_message_provider_unittest.cc",
      "../common/extensions/permissions/chrome_permission_message_rules_unittest.cc",
      "../common/extensions/permissions/permission_set_unittest.cc",
      "../common/extensions/permissions/permissions_data_unittest.cc",
      "../common/extensions/permissions/settings_override_permission_unittest.cc",
      "../common/extensions/sync_type_unittest.cc",
      "../renderer/extensions/api/extension_hooks_delegate_unittest.cc",
      "../renderer/extensions/api/identity_hooks_delegate_unittest.cc",
      "../renderer/extensions/api/tabs_hooks_delegate_unittest.cc",
      "../renderer/extensions/chrome_native_extension_bindings_system_unittest.cc",
      "../renderer/extensions/custom_types_unittest.cc",
      "../renderer/extensions/renderer_permissions_policy_delegate_unittest.cc",
    ]

    if (use_aura) {
      sources += [ "../browser/extensions/extension_install_prompt_show_params_unittest.cc" ]
    }

    if (enterprise_data_controls) {
      sources += [
        "../../components/enterprise/data_controls/core/browser/data_controls_policy_handler_unittest.cc",
        "../browser/enterprise/data_controls/dlp_reporting_manager_unittest.cc",
      ]
      deps += [
        "//chrome/browser/enterprise/data_controls",
        "//chrome/browser/enterprise/data_controls:test_support",
        "//components/enterprise/data_controls/content/browser:unit_tests",
        "//components/enterprise/data_controls/core/browser",
      ]
    }

    if (enterprise_local_content_analysis) {
      sources += [
        "../browser/enterprise/connectors/analysis/content_analysis_sdk_manager_unittest.cc",
        "../browser/enterprise/connectors/analysis/local_binary_upload_service_unittest.cc",
        "../browser/enterprise/data_protection/print_utils_unittest.cc",
        "../browser/policy/local_sync_policy_handler_unittest.cc",
        "../common/extensions/api/system_indicator/system_indicator_handler_unittest.cc",
      ]

      deps += [ "../browser/enterprise/connectors/test:test_support" ]
    }

    if (is_chromeos_lacros || is_chromeos_ash) {
      sources += [ "//chrome/browser/chromeos/extensions/wm/wm_desks_private_events_unittest.cc" ]
      deps += [ "//chrome/browser/chromeos/extensions/wm" ]
    }

    allow_circular_includes_from = [
      "//chrome/browser/web_applications:web_applications_unit_tests",
      "//chrome/browser/web_applications/extensions:unit_tests",
    ]

    deps += [
      "//chrome/browser/extensions:cws_item_service_proto",
      "//chrome/browser/extensions:test_support",
      "//chrome/browser/extensions/api/cookies:helpers",
      "//chrome/browser/ui/web_applications:unit_tests",
      "//chrome/browser/web_applications:unit_tests",
      "//chrome/browser/web_applications:web_applications_unit_tests",
      "//chrome/browser/web_applications/extensions:unit_tests",
      "//chrome/common/apps/platform_apps",
      "//chrome/common/extensions:extension_features_unittest",
      "//chrome/common/extensions/api",
      "//chrome/renderer/extensions",
      "//chrome/utility/image_writer:unit_tests",
      "//components/enterprise:test_support",
      "//components/password_manager/core/browser/features:password_features",
      "//components/password_manager/core/browser/sharing",
      "//components/password_manager/core/browser/sharing:test_support",
      "//components/safe_browsing:buildflags",
      "//components/services/storage/privileged/mojom",
      "//components/services/unzip:in_process",
      "//components/value_store",
      "//components/value_store:test_support",
      "//extensions:extensions_resources",
      "//extensions/browser:test_support",
      "//extensions/browser/api/storage:settings_observer",
      "//extensions/browser/updater",
      "//extensions/buildflags",
      "//extensions/common",
      "//extensions/common:mojom",
      "//extensions/common:test_support",
      "//extensions/renderer",
      "//extensions/renderer:unit_test_support",
      "//extensions/strings",
      "//google_apis",
      "//google_apis/common",
      "//google_apis/drive",
      "//media/cast:test_support",

      # This will add all of the unit tests for the schema compiler to this
      # target.
      "//third_party/blink/common/privacy_budget:test_support",
      "//tools/json_schema_compiler/test:unit_tests",
    ]

    if (enable_service_discovery) {
      sources += [ "../browser/extensions/api/mdns/mdns_api_unittest.cc" ]
    }

    if (is_mac) {
      sources += [
        "../browser/apps/app_shim/app_shim_host_mac_unittest.cc",
        "../browser/apps/app_shim/app_shim_manager_mac_unittest.cc",
        "../browser/apps/app_shim/web_app_shim_manager_delegate_mac_unittest.cc",
      ]
    }

    if (is_win) {
      sources += [
        "../browser/extensions/external_registry_loader_win_unittest.cc",
        "../browser/media_galleries/win/mtp_device_delegate_impl_win_unittest.cc",
        "../browser/media_galleries/win/mtp_device_object_enumerator_unittest.cc",
      ]
    }

    if (is_chromeos && use_cups) {
      sources += [
        "../browser/extensions/api/printing/printing_api_handler_unittest.cc",
        "../browser/extensions/api/printing/printing_api_utils_unittest.cc",
      ]
      deps += [ "//chromeos/printing" ]
    }

    if (is_chromeos) {
      deps += [
        "//chrome/browser/ui/chromeos",
        "//chromeos/dbus/missive",
      ]
    }

    if (is_chromeos_ash) {
      sources += [
        "../browser/extensions/api/enterprise_device_attributes/enterprise_device_attributes_api_ash_unittest.cc",
        "../browser/extensions/api/enterprise_kiosk_input/enterprise_kiosk_input_unittest.cc",
        "../browser/extensions/api/file_system/consent_provider_unittest.cc",
        "../browser/extensions/api/image_writer_private/removable_storage_provider_chromeos_unittest.cc",
        "../browser/extensions/api/quick_unlock_private/quick_unlock_private_api_unittest.cc",
        "../browser/extensions/extension_garbage_collector_chromeos_unittest.cc",
        "../browser/extensions/external_pref_loader_unittest.cc",
        "../browser/extensions/external_provider_impl_chromeos_unittest.cc",
        "../browser/extensions/system_display/display_info_provider_chromeos_unittest.cc",
        "../browser/media_galleries/chromeos/mtp_device_object_enumerator_unittest.cc",
        "../browser/policy/restricted_mgs_policy_provider_ash_unittest.cc",
        "../common/chromeos/extensions/chromeos_system_extension_info_unittest.cc",
        "../common/chromeos/extensions/manifest_tests/extension_manifests_chromeos_system_extension_unittest.cc",
        "../renderer/extensions/api/accessibility_private_hooks_delegate_unittest.cc",
      ]

      deps += [
        "//chrome/browser/ui/webui/ash/parent_access:mojo_bindings",
        "//chrome/common/chromeos/extensions",
        "//chromeos/ash/components/dbus/image_burner",
        "//chromeos/components/mgs:test_support",
        "//content/public/browser",
        "//net",
        "//net:test_support",
      ]
    } else {
      sources += [ "../browser/extensions/api/messaging/native_messaging_host_manifest_unittest.cc" ]

      deps += [ "//components/enterprise:test_support" ]
    }

    # The Chrome OS implementation of Native Messaging does not use the source
    # files corresponding to these tests.
    if (!is_chromeos) {
      sources += [
        "../browser/extensions/api/messaging/native_message_process_host_unittest.cc",
        "../browser/extensions/api/messaging/native_messaging_launch_from_native_unittest.cc",
        "../browser/extensions/api/messaging/native_messaging_policy_handler_unittest.cc",
      ]
    }

    if (safe_browsing_mode == 1) {
      sources += [ "../browser/extensions/blocklist_unittest.cc" ]
    }
  }

  if (is_win || is_mac || is_linux) {
    sources += [
      "../browser/sharing_hub/sharing_hub_model_unittest.cc",
      "../browser/ui/views/sharing_hub/preview_view_unittest.cc",
      "../browser/ui/views/sharing_hub/sharing_hub_bubble_view_impl_unittest.cc",
    ]
  }

  if (use_aura) {
    sources += [ "../browser/ui/overscroll_pref_manager_unittest.cc" ]

    deps += [
      "//ui/aura:test_support",
      "//ui/views:test_support",
      "//ui/wm",
    ]
  }

  if (is_linux || is_chromeos_lacros) {
    sources += [ "../browser/ui/global_media_controls/media_notification_device_monitor_unittest.cc" ]
  }

  if (is_linux) {
    sources += [
      "../browser/notifications/notification_platform_bridge_linux_unittest.cc",
      "../browser/shell_integration_linux_unittest.cc",
      "../browser/upgrade_detector/directory_monitor_unittest.cc",
      "../browser/upgrade_detector/get_installed_version_linux_unittest.cc",
    ]

    deps += [
      "../browser/enterprise/connectors/device_trust/key_management/installer/management_service:unit_tests",
      "//components/dbus/thread_linux",
    ]

    if (use_ozone) {
      deps += [ "//ui/ozone" ]
    }
  }

  if (is_linux && use_dbus) {
    sources += [
      "../browser/dbus_memory_pressure_evaluator_linux_unittest.cc",
      "../browser/ui/views/dark_mode_manager_linux_unittest.cc",
    ]
    deps += [
      "//dbus:test_support",
      "//ui/linux:test_support",
    ]
  }

  if (is_android || is_chromeos_ash || is_win) {
    sources += [ "../browser/media/protected_media_identifier_permission_context_unittest.cc" ]
  }

  if (!is_android && !is_chromeos_ash) {
    sources += [
      "../browser/lifetime/switch_utils_unittest.cc",
      "../browser/profiles/profile_list_desktop_unittest.cc",
      "../browser/profiles/profile_statistics_unittest.cc",
      "../browser/ui/profiles/profile_colors_util_unittest.cc",
    ]
  }

  if (!is_android) {
    sources += [
      "../browser/ui/startup/startup_browser_creator_impl_unittest.cc",
      "../browser/ui/startup/startup_browser_creator_unittest.cc",
      "../browser/ui/startup/startup_tab_provider_unittest.cc",
    ]
  }

  if (!is_android && !is_ios) {
    sources += [
      "../browser/policy/cloud/cloud_policy_invalidator_unittest.cc",
      "../browser/policy/cloud/cloud_policy_invalidator_with_listener_unittest.cc",
      "../browser/policy/cloud/fm_registration_token_uploader_unittest.cc",
      "../browser/policy/developer_tools_policy_handler_unittest.cc",
      "../browser/profiles/guest_mode_policy_handler_unittest.cc",
    ]

    deps += [ "//components/webauthn/core/browser:test_support" ]
  }

  if (use_gio) {
    configs += [ "//build/linux:gio_config" ]
  }

  if (enable_service_discovery) {
    sources += [
      "../browser/devtools/device/cast_device_provider_unittest.cc",
      "../browser/local_discovery/service_discovery_device_lister_unittest.cc",
    ]

    if (is_mac) {
      sources += [
        "../browser/local_discovery/service_discovery_client_mac_unittest.mm",
        "../browser/local_discovery/service_discovery_client_mac_util_unittest.mm",
      ]
    } else {
      sources += [
        "../browser/local_discovery/local_domain_resolver_unittest.cc",
        "../browser/local_discovery/service_discovery_client_unittest.cc",
      ]
    }
  }

  if (safe_browsing_mode > 0) {
    sources += [
      "../browser/safe_browsing/chrome_password_protection_service_unittest.cc",
      "../browser/safe_browsing/chrome_ui_manager_delegate_unittest.cc",
      "../browser/safe_browsing/chrome_user_population_helper_unittest.cc",
      "../browser/safe_browsing/threat_details_unittest.cc",
    ]

    deps += [
      "//components/safe_browsing/content/browser:safe_browsing_blocking_page",
      "//components/safe_browsing/content/common:file_type_policies",
      "//components/safe_browsing/content/common:file_type_policies_test_support",
      "//components/safe_browsing/core/browser:token_fetcher",
    ]
  }

  if (safe_browsing_mode == 1) {
    # TODO(sgurun): enable tests for safe_browsing==2.
    sources += [
      "../browser/safe_browsing/advanced_protection_status_manager_factory_unittest.cc",
      "../browser/safe_browsing/advanced_protection_status_manager_unittest.cc",
      "../browser/safe_browsing/chrome_client_side_detection_host_delegate_unittest.cc",
      "../browser/safe_browsing/chrome_enterprise_url_lookup_service_factory_unittest.cc",
      "../browser/safe_browsing/chrome_enterprise_url_lookup_service_unittest.cc",
      "../browser/safe_browsing/chrome_password_reuse_detection_manager_client_unittest.cc",
      "../browser/safe_browsing/chrome_ping_manager_factory_unittest.cc",
      "../browser/safe_browsing/client_side_detection_host_unittest.cc",
      "../browser/safe_browsing/client_side_detection_service_factory_unittest.cc",
      "../browser/safe_browsing/client_side_detection_service_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/binary_fcm_service_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/cloud_binary_upload_service_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/connector_data_pipe_getter_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/deep_scanning_utils_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/file_analysis_request_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/file_opening_job_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/multipart_uploader_unittest.cc",
      "../browser/safe_browsing/cloud_content_scanning/resumable_uploader_unittest.cc",
      "../browser/safe_browsing/download_protection/download_feedback_service_unittest.cc",
      "../browser/safe_browsing/download_protection/download_feedback_unittest.cc",
      "../browser/safe_browsing/download_protection/download_protection_service_unittest.cc",
      "../browser/safe_browsing/download_protection/download_protection_unittest_util.cc",
      "../browser/safe_browsing/download_protection/download_protection_unittest_util.h",
      "../browser/safe_browsing/download_protection/download_protection_util_unittest.cc",
      "../browser/safe_browsing/download_protection/download_request_maker_unittest.cc",
      "../browser/safe_browsing/download_protection/file_analyzer_unittest.cc",
      "../browser/safe_browsing/download_protection/path_sanitizer_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/cookies_get_all_signal_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/cookies_get_all_signal_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/cookies_get_signal_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/cookies_get_signal_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/declarative_net_request_action_signal_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/declarative_net_request_action_signal_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/declarative_net_request_signal_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/extension_js_callstacks_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/extension_telemetry_config_manager_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/extension_telemetry_file_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/extension_telemetry_persister_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/extension_telemetry_service_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/extension_telemetry_uploader_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/potential_password_theft_signal_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/remote_host_contacted_signal_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/remote_host_contacted_signal_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/tabs_api_signal_processor_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/tabs_api_signal_unittest.cc",
      "../browser/safe_browsing/extension_telemetry/tabs_execute_script_signal_processor_unittest.cc",
      "../browser/safe_browsing/hash_realtime_service_factory_unittest.cc",
      "../browser/safe_browsing/incident_reporting/binary_integrity_incident_unittest.cc",
      "../browser/safe_browsing/incident_reporting/delayed_callback_runner_unittest.cc",
      "../browser/safe_browsing/incident_reporting/download_metadata_manager_unittest.cc",
      "../browser/safe_browsing/incident_reporting/extension_data_collection_unittest.cc",
      "../browser/safe_browsing/incident_reporting/incident_report_uploader_impl_unittest.cc",
      "../browser/safe_browsing/incident_reporting/incident_reporting_service_unittest.cc",
      "../browser/safe_browsing/incident_reporting/last_download_finder_unittest.cc",
      "../browser/safe_browsing/incident_reporting/mock_incident_receiver.cc",
      "../browser/safe_browsing/incident_reporting/mock_incident_receiver.h",
      "../browser/safe_browsing/incident_reporting/platform_state_store_unittest.cc",
      "../browser/safe_browsing/incident_reporting/preference_validation_delegate_unittest.cc",
      "../browser/safe_browsing/incident_reporting/state_store_unittest.cc",
      "../browser/safe_browsing/incident_reporting/tracked_preference_incident_unittest.cc",
      "../browser/safe_browsing/ohttp_key_service_factory_unittest.cc",
      "../browser/safe_browsing/phishy_interaction_tracker_unittest.cc",
      "../browser/safe_browsing/safe_browsing_service_unittest.cc",
      "../browser/safe_browsing/tailored_security/chrome_tailored_security_service_unittest.cc",
      "../browser/safe_browsing/tailored_security/tailored_security_url_observer_unittest.cc",
      "../browser/safe_browsing/verdict_cache_manager_factory_unittest.cc",
      "../common/safe_browsing/binary_feature_extractor_unittest.cc",
      "../common/safe_browsing/download_type_util_unittest.cc",
      "../common/safe_browsing/ipc_protobuf_message_test_messages.h",
      "../common/safe_browsing/ipc_protobuf_message_unittest.cc",
    ]
    deps += [ "../common/safe_browsing:archive_analyzer_results" ]
    if (is_mac) {
      sources += [
        "../browser/safe_browsing/incident_reporting/binary_integrity_analyzer_mac_unittest.cc",
        "../browser/safe_browsing/signature_evaluator_mac_unittest.cc",
        "../common/safe_browsing/binary_feature_extractor_mac_unittest.cc",
        "../common/safe_browsing/disk_image_type_sniffer_mac_unittest.cc",
        "../common/safe_browsing/mach_o_image_reader_mac_unittest.cc",
        "../utility/safe_browsing/mac/dmg_analyzer_unittest.cc",
        "../utility/safe_browsing/mac/dmg_test_utils.cc",
        "../utility/safe_browsing/mac/dmg_test_utils.h",
        "../utility/safe_browsing/mac/hfs_unittest.cc",
        "../utility/safe_browsing/mac/read_stream_unittest.cc",
        "../utility/safe_browsing/mac/udif_unittest.cc",
      ]
    }
    if (is_win) {
      sources += [
        "../browser/safe_browsing/incident_reporting/binary_integrity_analyzer_win_unittest.cc",
        "../browser/safe_browsing/incident_reporting/environment_data_collection_win_unittest.cc",
        "../browser/safe_browsing/incident_reporting/module_integrity_unittest_util_win.cc",
        "../browser/safe_browsing/incident_reporting/module_integrity_unittest_util_win.h",
        "../browser/safe_browsing/incident_reporting/module_integrity_verifier_win_unittest.cc",
        "../browser/safe_browsing/incident_reporting/platform_state_store_win_unittest.cc",
        "../common/safe_browsing/binary_feature_extractor_win_unittest.cc",
      ]
    }
    deps += [
      ":test_proto",
      "../common/safe_browsing:mock_binary_feature_extractor",
      "//chrome/common/safe_browsing:binary_feature_extractor",
      "//chrome/common/safe_browsing:download_type_util",
      "//chrome/services/file_util/public/cpp:unit_tests",
      "//components/file_access:test_support",
      "//components/safe_browsing/content/browser:safe_browsing_service",
      "//components/safe_browsing/core/browser:token_fetcher_testing_helper",
      "//components/safe_browsing/core/common/hashprefix_realtime:hash_realtime_utils",
      "//ipc:protobuf_support",
    ]
  } else if (safe_browsing_mode == 2 && is_android) {
    sources += [
      "../browser/component_updater/real_time_url_checks_allowlist_component_installer_unittest.cc",
      "../browser/safe_browsing/android/password_reuse_controller_android_unittest.cc",
      "../browser/safe_browsing/tailored_security/chrome_tailored_security_service_android_unittest.cc",
      "../browser/safe_browsing/tailored_security/consented_message_android_unittest.cc",
      "../browser/safe_browsing/telemetry/android/android_telemetry_service_unittest.cc",
    ]

    deps += [
      "//components/safe_browsing/android:real_time_url_checks_allowlist",
      "//components/safe_browsing/android:safe_browsing_api_handler",
      "//components/safe_browsing/android:safe_browsing_api_handler_util",
    ]
  }

  if (enterprise_cloud_content_analysis || is_android) {
    # Use this scope to migrate files/deps from
    # `enterprise_cloud_content_analysis` conditions that now need to compile
    # on Android.
    sources += [
      "../browser/enterprise/connectors/analysis/analysis_service_settings_unittest.cc",
      "../browser/enterprise/connectors/common_unittest.cc",
      "../browser/enterprise/connectors/connectors_manager_unittest.cc",
      "../browser/enterprise/connectors/connectors_service_unittest.cc",
    ]
    deps += [ "//components/enterprise/connectors/core" ]
  }

  if (enterprise_cloud_content_analysis) {
    sources += [
      "../browser/enterprise/connectors/analysis/content_analysis_delegate_unittest.cc",
      "../browser/enterprise/connectors/analysis/content_analysis_downloads_delegate_unittest.cc",
      "../browser/enterprise/connectors/analysis/files_request_handler_unittest.cc",
      "../browser/enterprise/connectors/analysis/page_print_analysis_request_unittest.cc",
      "../browser/enterprise/connectors/reporting/crash_reporting_context_unittest.cc",
      "../browser/enterprise/connectors/reporting/extension_install_event_router_unittest.cc",
      "../browser/enterprise/connectors/reporting/extension_telemetry_event_router_unittest.cc",
      "../browser/enterprise/connectors/reporting/realtime_reporting_client_unittest.cc",
      "../browser/extensions/api/safe_browsing_private/safe_browsing_private_event_router_unittest.cc",
      "../browser/interstitials/enterprise_util_unittest.cc",
      "../browser/safe_browsing/download_protection/deep_scanning_request_unittest.cc",
      "../browser/ui/tab_contents/chrome_web_contents_view_handle_drop_unittest.cc",
      "../browser/ui/webui/management/management_ui_handler_unittest.cc",
    ]
    deps += [
      "../browser/enterprise/connectors/test:test_support",
      "//components/enterprise/connectors/core:unit_tests",
    ]
    if (is_chromeos) {
      deps += [ "//chromeos/components/mgs" ]
    }
    if (is_chromeos_ash) {
      deps += [ "//chrome/browser/ash/net" ]
    }
  }

  if (is_linux || is_chromeos_ash || is_mac || is_win) {
    sources += [
      "../browser/enterprise/connectors/device_trust/device_trust_connector_service_factory_unittest.cc",
      "../browser/enterprise/connectors/device_trust/device_trust_connector_service_unittest.cc",
      "../browser/enterprise/connectors/device_trust/device_trust_service_unittest.cc",
      "../browser/enterprise/connectors/device_trust/navigation_throttle_unittest.cc",
      "../browser/enterprise/connectors/device_trust/signals/signals_filterer_unittest.cc",
      "../browser/enterprise/connectors/device_trust/signals/signals_service_impl_unittest.cc",
      "../browser/enterprise/signals/user_delegate_impl_unittest.cc",
      "../browser/performance_manager/user_tuning/memory_saver_policy_handler_unittest.cc",
    ]

    deps += [
      "../browser/enterprise/connectors/device_trust:features",
      "../browser/enterprise/connectors/device_trust:test_support",
      "../browser/enterprise/connectors/device_trust/attestation/common",
      "../browser/enterprise/connectors/device_trust/attestation/common:test_support",
      "../browser/enterprise/connectors/device_trust/common",
      "../browser/enterprise/connectors/device_trust/common:unit_tests",
      "../browser/enterprise/connectors/device_trust/signals:test_support",
      "../browser/enterprise/connectors/device_trust/signals/decorators/common",
      "../browser/enterprise/connectors/device_trust/signals/decorators/common:test_support",
      "../browser/enterprise/connectors/device_trust/signals/decorators/common:unit_tests",
      "//components/device_signals/core/browser",
      "//components/device_signals/core/browser:test_support",
      "//components/device_signals/core/common",
      "//components/device_signals/core/common:features",
      "//components/device_signals/core/common:unit_tests",
      "//components/enterprise/device_trust",
      "//services/data_decoder/public/cpp:test_support",
    ]
  }

  if (is_linux || is_mac || is_win || is_android) {
    sources += [
      "../browser/enterprise/idle/action_runner_unittest.cc",
      "../browser/enterprise/idle/action_unittest.cc",
    ]
    deps += [ "//components/enterprise/idle" ]
  }

  if (is_linux || is_mac || is_win) {
    sources += [
      "../browser/accessibility/soda_installer_impl_unittest.cc",
      "../browser/browser_switcher/alternative_browser_driver_unittest.cc",
      "../browser/browser_switcher/browser_switcher_navigation_throttle_unittest.cc",
      "../browser/browser_switcher/browser_switcher_prefs_unittest.cc",
      "../browser/browser_switcher/browser_switcher_sitelist_unittest.cc",
      "../browser/browser_switcher/ieem_sitelist_parser_unittest.cc",
      "../browser/browser_switcher/mock_alternative_browser_driver.cc",
      "../browser/browser_switcher/mock_alternative_browser_driver.h",
      "../browser/enterprise/connectors/device_trust/attestation/browser/browser_attestation_service_unittest.cc",
      "../browser/enterprise/connectors/device_trust/attestation/browser/device_attester_unittest.cc",
      "../browser/enterprise/connectors/device_trust/attestation/browser/profile_attester_unittest.cc",
      "../browser/enterprise/connectors/device_trust/browser/signing_key_policy_observer.cc",
      "../browser/enterprise/core/dependency_factory_impl_unittest.cc",
      "../browser/enterprise/profile_management/oidc_auth_response_capture_navigation_throttle_unittest.cc",
      "../browser/enterprise/profile_management/profile_management_navigation_throttle_unittest.cc",
      "../browser/enterprise/profile_management/saml_response_parser_unittest.cc",
      "../browser/enterprise/remote_commands/rotate_attestation_credential_job_unittest.cc",
      "../browser/enterprise/signin/managed_profile_creator_unittest.cc",
      "../browser/enterprise/signin/oidc_authentication_signin_interceptor_unittest.cc",
      "../browser/enterprise/signin/oidc_managed_profile_creation_delegate_unittest.cc",
      "../browser/enterprise/signin/profile_token_web_signin_interceptor_unittest.cc",
      "../browser/enterprise/signin/token_managed_profile_creation_delegate_unittest.cc",
      "../browser/enterprise/signin/user_policy_oidc_signin_service_unittest.cc",
      "../browser/net/disk_cache_dir_policy_handler_unittest.cc",
      "../browser/ui/webui/whats_new/whats_new_handler_unittest.cc",
      "../browser/ui/webui/whats_new/whats_new_registrar_unittest.cc",
      "../browser/ui/webui/whats_new/whats_new_storage_service_impl_unittest.cc",
      "../browser/ui/webui/whats_new/whats_new_util_unittest.cc",
    ]

    deps += [
      "../browser/enterprise/connectors/device_trust/key_management/browser",
      "../browser/enterprise/connectors/device_trust/key_management/browser:test_support",
      "../browser/enterprise/connectors/device_trust/key_management/browser:unit_tests",
      "../browser/enterprise/connectors/device_trust/key_management/browser/commands:unit_tests",
      "../browser/enterprise/connectors/device_trust/key_management/core",
      "../browser/enterprise/connectors/device_trust/key_management/core:unit_tests",
      "../browser/enterprise/connectors/device_trust/key_management/core/network:unit_tests",
      "../browser/enterprise/connectors/device_trust/key_management/core/persistence",
      "../browser/enterprise/connectors/device_trust/key_management/core/persistence:test_support",
      "../browser/enterprise/connectors/device_trust/key_management/core/persistence:unit_tests",
      "../browser/enterprise/connectors/device_trust/key_management/installer:unit_tests",
      "../browser/enterprise/connectors/device_trust/signals/decorators/browser:unit_tests",
      "../browser/ui/webui/whats_new:mojo_bindings",
      "//components/user_education/webui:webui",
    ]
  }

  if (is_mac) {
    deps += [ "../browser/enterprise/connectors/device_trust/key_management/core/mac:unit_tests" ]
  }

  if (is_win || is_mac || is_linux) {
    deps += [
      "../browser/enterprise/connectors/test:test_support",
      "../services/system_signals:unit_tests",
    ]
  }

  if (enable_pdf) {
    sources += [
      "../browser/extensions/api/pdf_viewer_private/pdf_viewer_private_api_unittest.cc",
      "../browser/pdf/pdf_viewer_stream_manager_unittest.cc",
      "../common/pdf_util_unittest.cc",
    ]
    deps += [
      "//base",
      "//chrome/browser/extensions/api/pdf_viewer_private",
      "//chrome/browser/pdf",
      "//chrome/browser/pdf:pdf_test_utils",
      "//extensions/browser",
      "//net",
      "//pdf:content_restriction",
      "//pdf:features",
      "//services/network/public/mojom:url_loader_base",
      "//url",
    ]
  }

  if (enable_plugins) {
    sources += [
      "../browser/plugins/chrome_plugin_service_filter_unittest.cc",
      "../browser/plugins/plugin_info_host_impl_unittest.cc",
      "../browser/plugins/plugin_prefs_unittest.cc",
    ]
  }

  if (enable_ppapi) {
    sources += [ "../common/pepper_permission_util_unittest.cc" ]
  }

  if (enable_printing) {
    sources += [
      "../browser/policy/printing_restrictions_policy_handler_unittest.cc",
      "../browser/printing/print_job_unittest.cc",
    ]

    deps += [
      "//chrome/common/printing",
      "//chrome/common/printing:unit_tests",
      "//components/printing/common:mojo_interfaces",
      "//printing",
      "//printing:test_support",
      "//printing/backend",
      "//printing/mojom",
    ]

    if (enable_print_preview) {
      sources += [
        "../browser/printing/print_preview_dialog_controller_unittest.cc",
        "../browser/printing/print_preview_sticky_settings_unittest.cc",
        "../browser/printing/print_preview_test.cc",
        "../browser/printing/print_preview_test.h",
        "../browser/printing/print_view_manager_unittest.cc",
        "../browser/ui/webui/print_preview/extension_printer_handler_unittest.cc",
        "../browser/ui/webui/print_preview/fake_print_render_frame.cc",
        "../browser/ui/webui/print_preview/fake_print_render_frame.h",
        "../browser/ui/webui/print_preview/parse_data_path_unittest.cc",
        "../browser/ui/webui/print_preview/pdf_printer_handler_unittest.cc",
        "../browser/ui/webui/print_preview/print_preview_handler_unittest.cc",
        "../browser/ui/webui/print_preview/print_preview_ui_unittest.cc",
        "../browser/ui/webui/print_preview/print_preview_ui_untrusted_unittest.cc",
        "../browser/ui/webui/print_preview/print_preview_utils_unittest.cc",
      ]

      if (is_win) {
        sources += [ "../browser/ui/webui/print_preview/pdf_printer_handler_win_unittest.cc" ]
      }

      if (is_posix) {
        sources += [ "../browser/ui/webui/print_preview/pdf_printer_handler_posix_unittest.cc" ]
      }

      if (is_chromeos) {
        sources += [
          "../browser/ui/webui/print_preview/local_printer_handler_chromeos_unittest.cc",
          "../browser/ui/webui/print_preview/print_preview_handler_chromeos_unittest.cc",
        ]
      } else {
        sources += [ "../browser/ui/webui/print_preview/local_printer_handler_default_unittest.cc" ]
      }
    } else {
      sources += [ "../browser/printing/print_view_manager_basic_unittest.cc" ]
    }

    if (enable_oop_printing) {
      sources +=
          [ "../browser/printing/print_backend_service_manager_unittest.cc" ]
    }
  }

  if (enable_session_service) {
    sources += [
      "../browser/sessions/app_session_service_unittest.cc",
      "../browser/sessions/exit_type_service_unittest.cc",
      "../browser/sessions/session_data_service_unittest.cc",
      "../browser/sessions/session_restore_observer_unittest.cc",
      "../browser/sessions/session_restore_stats_collector_unittest.cc",
      "../browser/sessions/session_service_log_unittest.cc",
      "../browser/sessions/session_service_unittest.cc",
      "../browser/sessions/tab_loader_unittest.cc",
    ]
    if (is_chromeos) {
      deps += [ "//chromeos/components/kiosk:test_support" ]
    }
  }

  if (is_chromeos && use_cups) {
    deps += [ "//chrome/browser/chromeos/printing:test_support" ]
  }

  if ((is_linux || is_chromeos) && use_aura) {
    deps += [ "//ui/aura:test_support" ]
    if (use_dbus) {
      deps += [ "//dbus:test_support" ]
    }
  }
  if (is_chrome_branded && (is_linux || is_chromeos) && current_cpu == "x86") {
    ldflags = [ "-Wl,--strip-debug" ]
  }
  if (is_win || is_mac) {
    sources += [
      "../browser/component_updater/updater_state_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/biometric_authentication_confirmation_bubble_controller_unittest.cc",
      "../browser/ui/passwords/bubble_controllers/biometric_authentication_for_filling_bubble_controller_unittest.cc",
    ]

    deps += [ "//chrome/common/notifications:unit_tests" ]
  }
  if (enable_rlz) {
    sources += [
      "../browser/rlz/chrome_rlz_tracker_delegate_unittest.cc",
      "../browser/rlz/chrome_rlz_tracker_web_contents_observer_unittest.cc",
    ]
    deps += [
      "//components/rlz:test_support",
      "//rlz:test_support",
    ]
  }
  if (!is_android && !is_chromeos) {
    sources += [
      "../browser/policy/cbcm_invalidations_initializer_unittest.cc",
      "../browser/policy/chrome_browser_cloud_management_register_watcher_unittest.cc",
      "../browser/policy/file_selection_dialogs_policy_handler_unittest.cc",
      "../browser/themes/theme_color_policy_handler_unittest.cc",
    ]
  }
  if (!is_android && !is_chromeos_ash) {
    sources += [
      "../browser/device_identity/device_oauth2_token_store_desktop_unittest.cc",
      "../browser/media/webrtc/native_desktop_media_list_unittest.cc",
      "../browser/policy/client_data_delegate_desktop_unittest.cc",
      "../browser/profiles/profile_activity_metrics_recorder_unittest.cc",
      "../browser/signin/force_signin_verifier_unittest.cc",
      "../browser/signin/signin_manager_unittest.cc",
      "../browser/signin/signin_ui_util_unittest.cc",
      "../browser/signin/signin_util_unittest.cc",
      "../browser/ui/profiles/profile_customization_synced_theme_waiter_unittest.cc",
      "../browser/ui/views/download/bubble/download_bubble_contents_view_unittest.cc",
      "../browser/ui/views/download/bubble/download_bubble_row_list_view_unittest.cc",
      "../browser/ui/views/download/bubble/download_bubble_row_view_unittest.cc",
      "../browser/ui/views/download/bubble/download_bubble_security_view_unittest.cc",
      "../browser/ui/views/download/bubble/download_toolbar_button_view_unittest.cc",
      "../browser/ui/views/sharing/sharing_dialog_view_unittest.cc",
      "../browser/ui/views/sharing/sharing_icon_view_unittest.cc",
      "../browser/ui/webui/signin/signin_error_handler_unittest.cc",
      "../browser/upgrade_detector/installed_version_poller_unittest.cc",
      "../browser/upgrade_detector/upgrade_detector_impl_unittest.cc",
      "../common/channel_info_unittest.cc",
    ]

    if (is_linux || is_win || is_mac) {
      sources += [
        "../browser/ui/views/media_preview/active_devices_media_coordinator_unittest.cc",
        "../browser/ui/views/media_preview/camera_preview/camera_coordinator_unittest.cc",
        "../browser/ui/views/media_preview/camera_preview/video_format_comparison_unittest.cc",
        "../browser/ui/views/media_preview/camera_preview/video_stream_coordinator_unittest.cc",
        "../browser/ui/views/media_preview/media_coordinator_unittest.cc",
        "../browser/ui/views/media_preview/media_preview_feature_unittest.cc",
        "../browser/ui/views/media_preview/media_preview_metrics_unittest.cc",
        "../browser/ui/views/media_preview/media_view_controller_base_unittest.cc",
        "../browser/ui/views/media_preview/mic_preview/audio_stream_coordinator_unittest.cc",
        "../browser/ui/views/media_preview/mic_preview/mic_coordinator_unittest.cc",
        "../browser/ui/views/media_preview/page_info_previews_coordinator_unittest.cc",
        "../browser/ui/views/media_preview/permission_prompt_previews_coordinator_unittest.cc",
        "../browser/ui/views/policy/enterprise_startup_dialog_unittest.cc",
      ]

      deps += [
        "//components/media_effects/test:test_support",
        "//services/audio/public/cpp:test_support",
        "//services/video_capture/public/cpp:mocks",
      ]
    }

    deps += [ "//components/enterprise:test_support" ]
  }

  if (toolkit_views) {
    deps += [
      "//chrome/browser/enterprise/watermark:watermark_view_lib",
      "//chrome/browser/ui:test_support",
      "//chrome/browser/ui/actions:actions",
      "//chrome/browser/ui/actions:actions_headers",
      "//chrome/browser/ui/tabs:tab_enums",
      "//chrome/browser/ui/views",
      "//components/app_constants",
      "//components/commerce/core:pref_names",
      "//components/commerce/core:shopping_service_test_support",
      "//components/constrained_window",
      "//components/global_media_controls",
      "//components/media_message_center",
      "//components/media_router/browser:test_support",
      "//components/media_router/common:test_support",
      "//components/omnibox/browser:vector_icons",
      "//components/safe_browsing/core/browser/realtime:test_support",
      "//components/safe_browsing/core/browser/realtime:url_lookup_service_base",
      "//components/saved_tab_groups:test_support",
      "//components/user_education/views",
      "//components/user_education/views:test_support",
      "//components/user_notes/model:unit_tests",
      "//components/web_modal:test_support",
      "//components/web_package",
      "//content/test:test_support",
      "//ui/base/dragdrop:types",
      "//ui/views",
      "//ui/views:test_support",
      "//ui/web_dialogs:test_support",
    ]

    if (!is_mac && enable_extensions) {
      deps += [ "//apps/ui/views" ]
    }

    sources += [
      "../../ui/views/controls/webview/web_dialog_view_unittest.cc",
      "../../ui/views/controls/webview/webview_unittest.cc",
      "../browser/enterprise/data_protection/data_protection_navigation_observer_unittest.cc",
      "../browser/enterprise/data_protection/data_protection_page_user_data_unittest.cc",
      "../browser/enterprise/watermark/watermark_view_unittest.cc",
      "../browser/ui/commerce/mock_commerce_ui_tab_helper.cc",
      "../browser/ui/commerce/mock_commerce_ui_tab_helper.h",
      "../browser/ui/media_router/media_route_starter_unittest.cc",
      "../browser/ui/media_router/media_router_ui_unittest.cc",
      "../browser/ui/views/accelerator_table_unittest.cc",
      "../browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc",
      "../browser/ui/views/apps/app_info_dialog/app_info_permissions_panel_unittest.cc",
      "../browser/ui/views/autofill/popup/custom_cursor_suppressor_unittest.cc",
      "../browser/ui/views/autofill/popup/lazy_loading_image_view_unittest.cc",
      "../browser/ui/views/autofill/popup/mock_accessibility_selection_delegate.cc",
      "../browser/ui/views/autofill/popup/mock_accessibility_selection_delegate.h",
      "../browser/ui/views/autofill/popup/mock_selection_delegate.cc",
      "../browser/ui/views/autofill/popup/mock_selection_delegate.h",
      "../browser/ui/views/autofill/popup/password_favicon_loader_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_cell_utils_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_row_content_view_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_row_factory_utils_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_row_view_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_row_with_button_view_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_search_bar_view_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_separator_view_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_title_view_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_view_utils_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_view_views_unittest.cc",
      "../browser/ui/views/autofill/popup/popup_warning_view_unittest.cc",
      "../browser/ui/views/bookmarks/bookmark_bar_view_test_helper.h",
      "../browser/ui/views/bookmarks/bookmark_bar_view_unittest.cc",
      "../browser/ui/views/bookmarks/bookmark_bubble_view_unittest.cc",
      "../browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc",
      "../browser/ui/views/bookmarks/bookmark_editor_view_unittest.cc",
      "../browser/ui/views/bookmarks/bookmark_menu_delegate_unittest.cc",
      "../browser/ui/views/bookmarks/saved_tab_groups/saved_tab_group_bar_unittest.cc",
      "../browser/ui/views/bubble/webui_bubble_dialog_view_unittest.cc",
      "../browser/ui/views/bubble/webui_bubble_manager_unittest.cc",
      "../browser/ui/views/commerce/price_tracking_bubble_dialog_view_unittest.cc",
      "../browser/ui/views/commerce/price_tracking_email_dialog_view_unittest.cc",
      "../browser/ui/views/commerce/price_tracking_icon_view_integration_test.cc",
      "../browser/ui/views/commerce/price_tracking_view_unittest.cc",
      "../browser/ui/views/commerce/product_specifications_button_unittest.cc",
      "../browser/ui/views/commerce/product_specifications_icon_view_integration_test.cc",
      "../browser/ui/views/confirm_bubble_views_unittest.cc",
      "../browser/ui/views/content_setting_bubble_contents_unittest.cc",
      "../browser/ui/views/content_setting_site_row_view_unittest.cc",
      "../browser/ui/views/desktop_capture/desktop_media_pane_view_unittest.cc",
      "../browser/ui/views/desktop_capture/desktop_media_picker_views_unittest.cc",
      "../browser/ui/views/desktop_capture/desktop_media_tab_list_unittest.cc",
      "../browser/ui/views/device_chooser_content_view_unittest.cc",
      "../browser/ui/views/download/download_in_progress_dialog_view_unittest.cc",
      "../browser/ui/views/download/download_item_view_unittest.cc",
      "../browser/ui/views/extensions/chooser_dialog_view_unittest.cc",
      "../browser/ui/views/extensions/expandable_container_view_unittest.cc",
      "../browser/ui/views/extensions/extensions_menu_item_unittest.cc",
      "../browser/ui/views/extensions/extensions_menu_main_page_view_unittest.cc",
      "../browser/ui/views/extensions/extensions_menu_site_permissions_page_view_unittest.cc",
      "../browser/ui/views/extensions/extensions_menu_view_unittest.cc",
      "../browser/ui/views/extensions/extensions_toolbar_button_unittest.cc",
      "../browser/ui/views/extensions/extensions_toolbar_container_unittest.cc",
      "../browser/ui/views/extensions/extensions_toolbar_unittest.cc",
      "../browser/ui/views/extensions/extensions_toolbar_unittest.h",
      "../browser/ui/views/extensions/media_galleries_dialog_views_unittest.cc",
      "../browser/ui/views/extensions/settings_overridden_dialog_unittest.cc",
      "../browser/ui/views/frame/browser_frame_bounds_change_animation_unittest.cc",
      "../browser/ui/views/frame/browser_non_client_frame_view_unittest.cc",
      "../browser/ui/views/frame/browser_view_layout_unittest.cc",
      "../browser/ui/views/frame/browser_view_unittest.cc",
      "../browser/ui/views/frame/tab_strip_region_view_unittest.cc",
      "../browser/ui/views/frame/web_contents_close_handler_unittest.cc",
      "../browser/ui/views/global_media_controls/cast_device_footer_view_unittest.cc",
      "../browser/ui/views/global_media_controls/cast_device_selector_view_unittest.cc",
      "../browser/ui/views/global_media_controls/media_item_ui_device_selector_view_unittest.cc",
      "../browser/ui/views/global_media_controls/media_item_ui_footer_view_unittest.cc",
      "../browser/ui/views/global_media_controls/media_item_ui_legacy_cast_footer_view_unittest.cc",
      "../browser/ui/views/global_media_controls/media_toolbar_button_contextual_menu_unittest.cc",
      "../browser/ui/views/hats/hats_next_web_dialog_unittest.cc",
      "../browser/ui/views/hover_button_unittest.cc",
      "../browser/ui/views/infobars/infobar_view_unittest.cc",
      "../browser/ui/views/intent_picker_bubble_view_unittest.cc",
      "../browser/ui/views/layout_provider_unittest.cc",
      "../browser/ui/views/location_bar/cookie_controls/cookie_controls_bubble_unittest.cc",
      "../browser/ui/views/location_bar/cookie_controls/cookie_controls_content_view_unittest.cc",
      "../browser/ui/views/location_bar/cookie_controls/cookie_controls_icon_view_unittest.cc",
      "../browser/ui/views/location_bar/icon_label_bubble_view_unittest.cc",
      "../browser/ui/views/location_bar/location_icon_view_unittest.cc",
      "../browser/ui/views/media_router/cast_dialog_access_code_cast_button_unittest.cc",
      "../browser/ui/views/media_router/cast_dialog_coordinator_unittest.cc",
      "../browser/ui/views/media_router/cast_dialog_metrics_unittest.cc",
      "../browser/ui/views/media_router/cast_dialog_no_sinks_view_unittest.cc",
      "../browser/ui/views/media_router/cast_dialog_sink_button_unittest.cc",
      "../browser/ui/views/media_router/cast_dialog_sink_view_unittest.cc",
      "../browser/ui/views/media_router/cast_dialog_view_unittest.cc",
      "../browser/ui/views/media_router/cast_toolbar_button_unittest.cc",
      "../browser/ui/views/media_router/web_contents_display_observer_view_unittest.cc",
      "../browser/ui/views/omnibox/omnibox_match_cell_view_unittest.cc",
      "../browser/ui/views/omnibox/omnibox_result_view_unittest.cc",
      "../browser/ui/views/omnibox/omnibox_view_views_unittest.cc",
      "../browser/ui/views/overlay/video_overlay_window_views_unittest.cc",
      "../browser/ui/views/page_action/page_action_icon_view_unittest.cc",
      "../browser/ui/views/page_info/page_info_bubble_view_unittest.cc",
      "../browser/ui/views/page_info/page_info_cookies_content_view_unittest.cc",
      "../browser/ui/views/page_info/page_info_permission_content_view_unittest.cc",
      "../browser/ui/views/page_info/safety_tip_page_info_bubble_view_unittest.cc",
      "../browser/ui/views/payments/payment_request_item_list_unittest.cc",
      "../browser/ui/views/payments/validating_textfield_unittest.cc",
      "../browser/ui/views/payments/view_stack_unittest.cc",
      "../browser/ui/views/performance_controls/battery_saver_button_unittest.cc",
      "../browser/ui/views/performance_controls/memory_saver_bubble_view_unittest.cc",
      "../browser/ui/views/performance_controls/memory_saver_chip_view_unittest.cc",
      "../browser/ui/views/performance_controls/tab_list_view_unittest.cc",
      "../browser/ui/views/permissions/chip/multi_image_container_unittest.cc",
      "../browser/ui/views/permissions/chip/permission_chip_unittest.cc",
      "../browser/ui/views/permissions/chip/permission_dashboard_unittest.cc",
      "../browser/ui/views/permissions/permission_prompt_base_view_unittest.cc",
      "../browser/ui/views/permissions/permission_prompt_bubble_one_origin_view_unittest.cc",
      "../browser/ui/views/permissions/permission_prompt_bubble_two_origins_view_unittest.cc",
      "../browser/ui/views/qrcode_generator/qrcode_generator_bubble_unittest.cc",
      "../browser/ui/views/relaunch_notification/relaunch_notification_controller_unittest.cc",
      "../browser/ui/views/relaunch_notification/relaunch_required_timer_internal_unittest.cc",
      "../browser/ui/views/send_tab_to_self/send_tab_to_self_device_picker_bubble_view_unittest.cc",
      "../browser/ui/views/send_tab_to_self/send_tab_to_self_toolbar_bubble_view_unittest.cc",
      "../browser/ui/views/side_panel/read_anything/read_anything_coordinator_unittest.cc",
      "../browser/ui/views/side_panel/side_panel_coordinator_unittest.cc",
      "../browser/ui/views/site_data/page_specific_site_data_dialog_unittest.cc",
      "../browser/ui/views/tab_contents/chrome_web_contents_view_delegate_views_unittest.cc",
      "../browser/ui/views/tabs/color_picker_view_unittest.cc",
      "../browser/ui/views/tabs/compound_tab_container_unittest.cc",
      "../browser/ui/views/tabs/fake_base_tab_strip_controller.cc",
      "../browser/ui/views/tabs/fake_base_tab_strip_controller.h",
      "../browser/ui/views/tabs/fake_tab_slot_controller.cc",
      "../browser/ui/views/tabs/fake_tab_slot_controller.h",
      "../browser/ui/views/tabs/overflow_view_unittest.cc",
      "../browser/ui/views/tabs/tab_container_unittest.cc",
      "../browser/ui/views/tabs/tab_group_views_unittest.cc",
      "../browser/ui/views/tabs/tab_hover_card_bubble_view_unittest.cc",
      "../browser/ui/views/tabs/tab_hover_card_controller_unittest.cc",
      "../browser/ui/views/tabs/tab_organization_button_unittest.cc",
      "../browser/ui/views/tabs/tab_search_container_unittest.cc",
      "../browser/ui/views/tabs/tab_strip_control_button_unittest.cc",
      "../browser/ui/views/tabs/tab_strip_layout_unittest.cc",
      "../browser/ui/views/tabs/tab_strip_scroll_container_unittest.cc",
      "../browser/ui/views/tabs/tab_strip_scroll_session_unittest.cc",
      "../browser/ui/views/tabs/tab_strip_unittest.cc",
      "../browser/ui/views/tabs/tab_unittest.cc",
      "../browser/ui/views/toolbar/chrome_labs/chrome_labs_button_unittest.cc",
      "../browser/ui/views/toolbar/chrome_labs/chrome_labs_unittest.cc",
      "../browser/ui/views/toolbar/pinned_toolbar_actions_container_unittest.cc",
      "../browser/ui/views/toolbar/reload_button_unittest.cc",
      "../browser/ui/views/toolbar/toolbar_action_view_unittest.cc",
      "../browser/ui/views/toolbar/toolbar_actions_bar_bubble_views_unittest.cc",
      "../browser/ui/views/toolbar/toolbar_button_unittest.cc",
      "../browser/ui/views/toolbar/toolbar_controller_unittest.cc",
      "../browser/ui/views/toolbar/toolbar_ink_drop_util_unittest.cc",
      "../browser/ui/views/toolbar/toolbar_view_unittest.cc",
      "../browser/ui/views/translate/partial_translate_bubble_view_unittest.cc",
      "../browser/ui/views/translate/translate_bubble_controller_unittest.cc",
      "../browser/ui/views/translate/translate_bubble_view_unittest.cc",
      "../browser/ui/views/user_education/browser_user_education_service_unittest.cc",
      "../browser/ui/views/user_education/help_bubble_view_timeout_unittest.cc",
      "../browser/ui/views/user_education/recent_session_observer_impl_unittest.cc",
      "../browser/ui/views/user_education/views_tutorial_unittest.cc",
      "../browser/ui/views/web_apps/isolated_web_apps/callback_delayer_unittest.cc",
      "../browser/ui/views/web_apps/isolated_web_apps/isolated_web_app_installer_view_controller_unittest.cc",
      "../browser/ui/views/web_apps/view_visible_in_active_widget_notifier_unittest.cc",
      "../browser/ui/window_name_prompt/window_name_prompt_unittest.cc",
    ]
    if (!is_chrome_for_testing) {
      sources += [ "../browser/ui/views/user_education/browser_feature_promo_controller_unittest.cc" ]
    }
    if (is_linux) {
      sources += [
        "../browser/ui/views/frame/browser_frame_view_layout_linux_native_unittest.cc",
        "../browser/ui/views/frame/browser_frame_view_layout_linux_unittest.cc",
      ]
      deps += [ "//ui/linux:linux_ui" ]
    }
    if (enable_plugins) {
      sources += [ "../browser/ui/views/hung_plugin_tab_helper_unittest.cc" ]
    }
    if (is_win) {
      sources +=
          [ "../browser/ui/views/status_icons/status_tray_win_unittest.cc" ]
    }
    if (is_mac) {
      sources += [
        "../browser/media_galleries/mac/mtp_device_delegate_impl_mac_unittest.mm",
        "../browser/ui/views/accelerator_table_unittest_mac.mm",
        "../browser/ui/views/desktop_capture/desktop_media_permission_pane_view_mac_unittest.mm",
        "../browser/ui/views/desktop_capture/screen_capture_permission_checker_mac_unittest.mm",
        "../browser/ui/views/frame/browser_non_client_frame_view_mac_unittest.mm",
      ]
    }
    if (is_mac || is_linux) {
      sources += [
        "../browser/ui/passwords/bubble_controllers/relaunch_chrome_bubble_controller_unittest.cc",
        "../browser/ui/webui/password_manager/promo_cards/relaunch_chrome_promo_unittest.cc",
      ]
    }
    if (!is_chromeos_ash) {
      sources += [
        "../browser/enterprise/remote_commands/clear_browsing_data_job_unittest.cc",
        "../browser/enterprise/remote_commands/user_remote_commands_factory_unittest.cc",
        "../browser/ui/views/profiles/profile_customization_bubble_sync_controller_unittest.cc",
        "../browser/ui/views/sync/one_click_signin_dialog_view_unittest.cc",
      ]
    }
    if (!is_chromeos) {
      sources += [
        "../browser/ui/views/frame/opaque_browser_frame_view_layout_unittest.cc",
        "../browser/ui/webui/settings/settings_default_browser_handler_unittest.cc",
      ]
    }
    if (is_linux || is_win || is_mac) {
      sources += [
        "../browser/ui/views/enterprise/managed_menu_view_unittest.cc",
        "../browser/ui/views/enterprise/management_toolbar_button_unittest.cc",
        "../browser/ui/views/global_media_controls/media_dialog_view_unittest.cc",
      ]
    }
    if (use_aura) {
      sources += [
        "../browser/ui/views/apps/shaped_app_window_targeter_unittest.cc",
        "../browser/ui/views/bubble/webui_bubble_event_handler_aura_unittest.cc",

        # Get this compiling on Mac - see http://crbug.com/657883.
      ]
      if (use_nss_certs) {
        sources += [
          "../browser/ui/views/crypto_module_password_dialog_view_unittest.cc",
          "../browser/ui/webui/certificates_handler_unittest.cc",
        ]
      }
    }
  }
  if (use_nss_certs) {
    sources += [ "../browser/certificate_manager_model_unittest.cc" ]
    if (is_chromeos) {
      sources += [
        "../browser/net/nss_temp_certs_cache_chromeos_unittest.cc",
        "../browser/ui/views/global_media_controls/media_item_ui_cast_footer_view_unittest.cc",
      ]
      deps += [ "//chromeos/components/kcer" ]
    }
  }
  if (!is_android && use_nss_certs) {
    sources += [ "../common/net/x509_certificate_model_nss_unittest.cc" ]
  }

  if (is_win || is_mac || is_linux || is_chromeos_lacros) {
    sources += [
      "../browser/ui/passwords/account_storage_auth_helper_unittest.cc",
      "../browser/ui/profiles/profile_customization_util_unittest.cc",
      "../browser/ui/profiles/profile_picker_unittest.cc",
      "../browser/ui/webui/signin/managed_user_profile_notice_handler_unittest.cc",
      "../browser/ui/webui/signin/turn_sync_on_helper_unittest.cc",
    ]
  }

  if (enable_widevine_cdm_component && (is_linux || is_chromeos_lacros)) {
    sources +=
        [ "../common/media/component_widevine_cdm_hint_file_linux_unittest.cc" ]
  }

  if (enable_widevine && is_linux) {
    sources += [ "../common/media/cdm_registration_unittest.cc" ]
    data_deps += [ "//third_party/widevine/cdm" ]
  }

  if (enable_lens_desktop_google_branded_features) {
    sources += [
      "../browser/ui/views/lens/lens_region_search_controller_unittest.cc",
      "../browser/ui/views/lens/lens_side_panel_navigation_helper_unittest.cc",
    ]
    deps += [ "//chrome/browser/lens/region_search" ]
  }

  if (is_win || is_linux || is_mac) {
    sources += [
      "../browser/metrics/structured/chrome_event_storage_unittest.cc",
      "../browser/metrics/structured/chrome_structured_metrics_recorder_unittest.cc",
    ]

    deps += [
      "//components/metrics/structured",
      "//components/metrics/structured:structured_events",
      "//components/metrics/structured:structured_metrics_validator",
      "//components/metrics/structured:test_support",
      "//components/metrics/structured/lib",
    ]
  }

  if ((enterprise_data_controls || enterprise_screenshot_protection) &&
      !is_android) {
    sources += [
      "../browser/enterprise/data_protection/data_protection_clipboard_utils_unittest.cc",
      "../browser/enterprise/data_protection/paste_allowed_request_unittest.cc",
    ]
    deps += [ "../browser/enterprise/data_controls:unit_tests" ]
  }

  if (!is_android) {
    sources += [ "../browser/promos/promos_utils_unittest.cc" ]

    deps += [
      "//chrome/browser/promos:utils",
      "//components/segmentation_platform/embedder/default_model",
    ]
  }

  if (is_win || is_mac || is_linux) {
    sources += [
      "../browser/ui/startup/default_browser_prompt/default_browser_prompt_manager_unittest.cc",
      "../browser/ui/startup/default_browser_prompt/default_browser_prompt_unittest.cc",
    ]
  }

  if (is_win || is_mac || is_linux || is_chromeos) {
    sources += [
      "../browser/policy/gen_ai_default_settings_policy_handler_unittest.cc",
    ]
  }
}

static_library("test_support_unit") {
  testonly = true
  sources = [
    "../browser/ui/autofill/autofill_suggestion_controller_test_base.cc",
    "../browser/ui/autofill/autofill_suggestion_controller_test_base.h",
    "../browser/ui/autofill/mock_autofill_popup_view.cc",
    "../browser/ui/autofill/mock_autofill_popup_view.h",
    "base/run_all_unittests.cc",
  ]

  public_deps = [
    ":test_support",
    "//base",
    "//chrome:resources",
    "//chrome:strings",
    "//chrome/browser",
    "//chrome/common",
    "//mojo/core/test:test_support",
  ]

  deps = [
    "//chrome/browser/autofill",
    "//components/autofill/content/browser:test_support",
  ]

  if (is_win) {
    deps += [ "//chrome/install_static/test:test_support" ]
  }

  if (is_chromeos_ash) {
    sources += [
      "../browser/ui/quick_answers/test/chrome_quick_answers_test_base.cc",
      "../browser/ui/quick_answers/test/chrome_quick_answers_test_base.h",
      "base/chrome_ash_test_base.cc",
      "base/chrome_ash_test_base.h",
    ]

    deps += [
      "//ash:test_support",
      "//chrome/browser/ash/login/users:test_support",
      "//chrome/browser/ui/chromeos/read_write_cards",
      "//chrome/browser/ui/quick_answers",
    ]
  }

  if (is_chromeos_lacros) {
    deps += [ "//chromeos/lacros:test_support" ]
  }

  if (is_android) {
    sources += [
      "../browser/ui/autofill/mock_autofill_keyboard_accessory_view.cc",
      "../browser/ui/autofill/mock_autofill_keyboard_accessory_view.h",
      "../browser/ui/autofill/test_autofill_keyboard_accessory_controller_autofill_client.h",
    ]

    deps += [ "//chrome/browser/keyboard_accessory/test_utils/android" ]
  } else {
    sources += [
      "../browser/ui/autofill/test_autofill_popup_controller_autofill_client.h",
    ]
  }

  if (enable_bound_session_credentials) {
    sources += [
      "../browser/signin/bound_session_credentials/fake_bound_session_cookie_refresh_service.cc",
      "../browser/signin/bound_session_credentials/fake_bound_session_cookie_refresh_service.h",
      "../browser/signin/bound_session_credentials/fake_bound_session_refresh_cookie_fetcher.cc",
      "../browser/signin/bound_session_credentials/fake_bound_session_refresh_cookie_fetcher.h",
      "../browser/signin/bound_session_credentials/fake_keyed_unexportable_key_service.cc",
      "../browser/signin/bound_session_credentials/fake_keyed_unexportable_key_service.h",
    ]
    public_deps += [ "//components/unexportable_keys:unexportable_keys" ]
  }
}

if (!is_android) {
  static_library("test_support_ui") {
    defines = []
    testonly = true

    sources = [
      "../browser/interstitials/security_interstitial_idn_test.cc",
      "../browser/interstitials/security_interstitial_idn_test.h",
      "../browser/password_manager/password_manager_test_base.cc",
      "../browser/password_manager/password_manager_test_base.h",
      "../browser/password_manager/passwords_navigation_observer.cc",
      "../browser/password_manager/passwords_navigation_observer.h",
      "../browser/picture_in_picture/document_picture_in_picture_mixin_test_base.cc",
      "../browser/picture_in_picture/document_picture_in_picture_mixin_test_base.h",
      "../browser/ssl/cert_verifier_browser_test.cc",
      "../browser/ssl/cert_verifier_browser_test.h",
      "../browser/ssl/cert_verifier_platform_browser_test.cc",
      "../browser/ssl/cert_verifier_platform_browser_test.h",
      "../browser/ui/exclusive_access/exclusive_access_test.cc",
      "../browser/ui/exclusive_access/exclusive_access_test.h",
      "../browser/ui/search/ntp_test_utils.cc",
      "../browser/ui/search/ntp_test_utils.h",
      "../browser/ui/test/test_browser_closed_waiter.cc",
      "../browser/ui/test/test_browser_closed_waiter.h",
      "../browser/ui/views/autofill/payments/card_unmask_prompt_view_tester_views.cc",
      "../browser/ui/views/autofill/payments/card_unmask_prompt_view_tester_views.h",
      "../browser/ui/views/autofill/payments/offer_notification_bubble_views_test_base.cc",
      "../browser/ui/views/autofill/payments/offer_notification_bubble_views_test_base.h",
      "../browser/ui/views/autofill/popup/popup_view_views_test_api.h",
      "../browser/ui/views/create_application_shortcut_view_test_support.cc",
      "../browser/ui/views/create_application_shortcut_view_test_support.h",
      "../browser/ui/views/side_panel/side_panel_test_utils.cc",
      "../browser/ui/views/side_panel/side_panel_test_utils.h",
      "../browser/ui/views/tabs/tab_hover_card_test_util.cc",
      "../browser/ui/views/tabs/tab_hover_card_test_util.h",
      "../browser/ui/views/web_apps/web_app_integration_test_driver.cc",
      "../browser/ui/views/web_apps/web_app_integration_test_driver.h",
      "../browser/ui/views/web_apps/web_app_link_capturing_test_utils.cc",
      "../browser/ui/views/web_apps/web_app_link_capturing_test_utils.h",
      "../browser/ui/web_applications/test/web_app_navigation_browsertest.cc",
      "../browser/ui/web_applications/test/web_app_navigation_browsertest.h",
      "../browser/ui/webui/signin/login_ui_test_utils.cc",
      "../browser/ui/webui/signin/login_ui_test_utils.h",
      "../browser/web_applications/test/profile_test_helper.cc",
      "../browser/web_applications/test/profile_test_helper.h",
      "../browser/web_applications/test/web_app_icon_test_utils.cc",
      "../browser/web_applications/test/web_app_icon_test_utils.h",
      "base/devtools_agent_coverage_observer.cc",
      "base/devtools_agent_coverage_observer.h",
      "base/devtools_listener.cc",
      "base/devtools_listener.h",
      "base/fake_gaia_mixin.cc",
      "base/fake_gaia_mixin.h",
      "base/in_process_browser_test.cc",
      "base/in_process_browser_test.h",
      "base/interactive_test_utils.cc",
      "base/interactive_test_utils.h",
      "base/interactive_test_utils_views.cc",
      "base/mixin_based_in_process_browser_test.cc",
      "base/mixin_based_in_process_browser_test.h",
      "base/platform_browser_test.h",
      "base/save_desktop_snapshot.cc",
      "base/save_desktop_snapshot.h",
      "base/test_chrome_web_ui_controller_factory.cc",
      "base/test_chrome_web_ui_controller_factory.h",
      "base/ui_test_utils.cc",
      "base/ui_test_utils.h",
      "base/web_ui_mocha_browser_test.cc",
      "base/web_ui_mocha_browser_test.h",
      "base/web_ui_test_data_source.cc",
      "base/web_ui_test_data_source.h",
      "interaction/feature_engagement_initialized_observer.cc",
      "interaction/feature_engagement_initialized_observer.h",
      "interaction/interaction_test_util_browser.cc",
      "interaction/interaction_test_util_browser.h",
      "interaction/interactive_browser_test.cc",
      "interaction/interactive_browser_test.h",
      "interaction/interactive_browser_test_internal.cc",
      "interaction/interactive_browser_test_internal.h",
      "interaction/tracked_element_webcontents.cc",
      "interaction/tracked_element_webcontents.h",
      "interaction/webcontents_interaction_test_util.cc",
      "interaction/webcontents_interaction_test_util.h",
      "permissions/permission_request_manager_test_api.cc",
      "permissions/permission_request_manager_test_api.h",
      "supervised_user/api_mock_setup_mixin.cc",
      "supervised_user/api_mock_setup_mixin.h",
      "supervised_user/child_account_test_utils.cc",
      "supervised_user/child_account_test_utils.h",
      "supervised_user/embedded_test_server_setup_mixin.cc",
      "supervised_user/embedded_test_server_setup_mixin.h",
      "supervised_user/supervision_mixin.cc",
      "supervised_user/supervision_mixin.h",
      "user_education/interactive_feature_promo_test.cc",
      "user_education/interactive_feature_promo_test.h",
      "user_education/interactive_feature_promo_test_common.cc",
      "user_education/interactive_feature_promo_test_common.h",
      "user_education/interactive_feature_promo_test_internal.cc",
      "user_education/interactive_feature_promo_test_internal.h",
    ]

    configs += [ "//build/config:precompiled_headers" ]

    public_deps = [
      "//chrome/browser:test_support_ui",
      "//chrome/browser/ui/exclusive_access",
      "//chrome/browser/ui/views/side_panel",
      "//components/supervised_user/core/browser",
      "//content/public/browser",
      "//content/test:test_support",
      "//google_apis:test_support",
      "//mojo/public/cpp/bindings",
      "//mojo/public/cpp/system",
    ]

    deps = [
      "//build:chromeos_buildflags",
      "//chrome/app:command_ids",
      "//chrome/browser",
      "//chrome/browser:browser_process",
      "//chrome/browser:main_extra_parts",
      "//chrome/browser/apps/app_service",
      "//chrome/browser/apps/app_service:app_registry_cache_waiter",
      "//chrome/browser/apps/app_service/app_icon",
      "//chrome/browser/apps/link_capturing",
      "//chrome/browser/apps/link_capturing:features",
      "//chrome/browser/autofill",
      "//chrome/browser/autofill:test_support",
      "//chrome/browser/devtools",
      "//chrome/browser/profiles:profile",
      "//chrome/browser/search",
      "//chrome/browser/search_engines",
      "//chrome/browser/sync",
      "//chrome/browser/ui",
      "//chrome/browser/ui:browser_element_identifiers",
      "//chrome/browser/ui:browser_navigator_params_headers",
      "//chrome/browser/ui:ui_features",
      "//chrome/browser/ui/autofill/payments:test_support_ui",
      "//chrome/browser/ui/views/toolbar",
      "//chrome/browser/ui/webui",
      "//chrome/browser/web_applications",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//chrome/common",
      "//chrome/common:chrome_features",
      "//chrome/common:constants",
      "//chrome/common:non_code_constants",
      "//chrome/common/profiler",
      "//chrome/renderer",
      "//chrome/test/data/webui:resources",
      "//chrome/test/data/webui/mojo:mojo_bindings",
      "//components/account_id",
      "//components/autofill/content/browser",
      "//components/autofill/content/browser:test_support",
      "//components/bookmarks/browser",
      "//components/captive_portal/content",
      "//components/captive_portal/core:buildflags",
      "//components/commerce/core:feature_list",
      "//components/content_settings/core/browser",
      "//components/custom_handlers:test_support",
      "//components/embedder_support",
      "//components/feature_engagement",
      "//components/feature_engagement/test:test_support",
      "//components/find_in_page",
      "//components/google/core/common",
      "//components/history/core/browser",
      "//components/infobars/content",
      "//components/infobars/core",
      "//components/input",
      "//components/javascript_dialogs",
      "//components/keyed_service/content",
      "//components/metrics:test_support",
      "//components/nacl/common:buildflags",
      "//components/nacl/common:switches",
      "//components/omnibox/browser",
      "//components/os_crypt/async/browser:key_provider_interface",
      "//components/os_crypt/sync:test_support",
      "//components/password_manager/core/browser",
      "//components/password_manager/core/browser:password_form",
      "//components/password_manager/core/browser:test_support",
      "//components/password_manager/core/browser/features:password_features",
      "//components/permissions",
      "//components/prefs",
      "//components/privacy_sandbox:features",
      "//components/search_engines",
      "//components/security_interstitials/content:security_interstitial_page",
      "//components/services/app_service",
      "//components/signin/public/base",
      "//components/signin/public/identity_manager",
      "//components/storage_monitor:test_support",
      "//components/supervised_user/core/browser/proto",
      "//components/supervised_user/test_support",
      "//components/sync:test_support",
      "//components/user_education/test:test",
      "//components/user_education/views:views",
      "//components/user_manager",
      "//components/webapps/browser",
      "//components/webapps/common",
      "//content/public/browser",
      "//extensions/buildflags",
      "//google_apis",
      "//printing/buildflags",
      "//services/device/public/cpp:test_support",
      "//skia",
      "//testing/gtest",
      "//third_party/libaddressinput",
      "//ui/base:features",
      "//ui/base:test_support",
      "//ui/events:test_support",
      "//ui/gfx:test_support",
      "//ui/shell_dialogs",
      "//ui/views",
      "//ui/views:test_support",
      "//ui/views/controls/webview",
    ]

    if (use_ozone) {
      deps += [ "//ui/ozone" ]
    }

    if (use_aura) {
      deps += [ "//ui/aura:test_support" ]
      sources += [
        "base/interactive_test_utils_aura.cc",
        "base/interactive_test_utils_aura.h",
      ]
    }

    if (is_mac) {
      sources += [
        "../browser/ui/test/test_browser_dialog_mac.h",
        "../browser/ui/test/test_browser_dialog_mac.mm",
        "base/in_process_browser_test_mac.mm",
        "base/interactive_test_utils_mac.mm",
      ]
      deps += [ "//chrome/browser/apps/app_shim:app_shim" ]
    }

    if (is_win) {
      sources += [
        "base/always_on_top_window_killer_win.cc",
        "base/always_on_top_window_killer_win.h",
        "base/interactive_test_utils_win.cc",
        "base/window_contents_as_string_win.cc",
        "base/window_contents_as_string_win.h",
      ]
      deps += [ "//chrome/browser/os_crypt" ]
    }

    if (enable_ppapi) {
      sources += [
        "ppapi/ppapi_test.cc",
        "ppapi/ppapi_test.h",
        "ppapi/ppapi_test_select_file_dialog_factory.cc",
        "ppapi/ppapi_test_select_file_dialog_factory.h",
      ]
      deps += [ "//ppapi/shared_impl" ]
      data = [
        "//ppapi/tests/test_case.html",
        "//ppapi/tests/test_case.html.mock-http-headers",
        "//ppapi/tests/test_page.css",
        "//ppapi/tests/test_page.css.mock-http-headers",
      ]
    }

    if (enable_extensions) {
      deps += [ "//extensions/browser" ]
    }

    if (is_chromeos_lacros) {
      deps += [
        ":lacros_test_support_ui",
        "//chromeos/lacros",
        "//chromeos/lacros:test_support",
        "//chromeos/startup:startup",
        "//components/account_manager_core",
        "//components/account_manager_core:test_support",
      ]
    }

    if (is_chromeos_ash) {
      sources += [
        "base/ash/javascript_browser_test.cc",
        "base/ash/javascript_browser_test.h",
        "base/ash/mojo_web_ui_browser_test.cc",
        "base/ash/mojo_web_ui_browser_test.h",
        "base/ash/web_ui_browser_test.cc",
        "base/ash/web_ui_browser_test.h",
      ]
      deps += [
        "//ash",
        "//ash:test_support",
        "//ash/constants",
        "//ash/public/cpp",
        "//ash/webui/common:trusted_types_util",
        "//chrome/browser/ash/app_restore",
        "//chrome/browser/ash/crosapi:browser_util",
        "//chrome/browser/ash/input_method",
        "//chrome/browser/ash/system_web_apps",
        "//chrome/browser/ash/system_web_apps/test_support",
        "//chrome/test/data/webui/chromeos:web_ui_test_bindings",
        "//chromeos/ash/components/browser_context_helper",
        "//chromeos/ash/components/cryptohome",
        "//chromeos/ash/services/device_sync",
        "//chromeos/ash/services/device_sync:test_support",
      ]
    } else {
      sources += [
        "../browser/first_run/scoped_relaunch_chrome_browser_override.cc",
        "../browser/first_run/scoped_relaunch_chrome_browser_override.h",
        "../browser/password_manager/password_manager_signin_intercept_test_helper.cc",
        "../browser/password_manager/password_manager_signin_intercept_test_helper.h",
      ]
    }
    if (enable_dice_support || is_chromeos_lacros) {
      sources += [
        "../browser/ui/startup/first_run_test_util.cc",
        "../browser/ui/startup/first_run_test_util.h",
        "../browser/ui/views/profiles/profile_picker_test_base.cc",
        "../browser/ui/views/profiles/profile_picker_test_base.h",
      ]
    }

    if (is_win || is_mac || is_linux) {
      sources += [
        "../browser/ui/sharing_hub/fake_sharing_hub_bubble_controller.cc",
        "../browser/ui/sharing_hub/fake_sharing_hub_bubble_controller.h",
      ]
    }

    if (use_ozone) {
      deps += [ "//ui/ozone" ]
    }
  }

  proto_library("test_proto") {
    sources = [ "../common/safe_browsing/ipc_protobuf_message_test.proto" ]
  }

  if (is_chromeos_ash) {
    assert(enable_extensions)

    # These tests are only meant to run on an FYI bot because they
    # test against live sites, as a way to catch potential regressions.
    test("accessibility_live_site_tests") {
      sources = [
        "../browser/ash/accessibility/accessibility_live_site_browsertest.cc",
        "base/interactive_ui_tests_main.cc",
      ]
      configs += [ "//build/config:precompiled_headers" ]

      defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]
      ldflags = []

      deps = [
        ":chrome_test_launcher",
        ":test_support",
        ":test_support_ui",
        "//build:chromeos_buildflags",
        "//chrome:packed_resources",
        "//chrome:resources",
        "//chrome:strings",
        "//chrome/browser",
        "//chrome/browser/ash/accessibility",
        "//chrome/browser/ash/accessibility:test_support",
        "//chrome/browser/devtools",
        "//chrome/renderer",
        "//components/resources",
        "//components/sync",
        "//components/sync:test_support",
        "//content/test:test_support",
        "//crypto:test_support",
        "//extensions/buildflags",
        "//google_apis:test_support",
        "//net",
        "//net:net_resources",
        "//net:test_support",
        "//skia",
        "//testing/gmock",
        "//testing/gtest",
        "//third_party/hunspell",
        "//third_party/icu",
        "//third_party/libpng",
        "//ui/base:test_support",
        "//ui/events:test_support",
        "//ui/ozone",
        "//ui/platform_window/common",
        "//ui/resources:ui_test_pak",
        "//ui/web_dialogs:test_support",
      ]

      if (enable_extensions) {
        deps += [
          "//google_apis/common:test_support",
          "//google_apis/drive",
        ]
      }
    }
  }
}

# Interactive UI test target can't run on ChromeOS device. See
# //docs/testing/chromeos_integration for how to create an integration
# test that works on ChromeOS VM/Device.
if (!is_android && !is_chromeos_device) {
  test("interactive_ui_tests") {
    use_xvfb = use_xvfb_in_this_config

    sources = [
      "../browser/about_flags_browsertest.cc",
      "../browser/browser_keyevents_browsertest.cc",
      "../browser/chrome_render_widget_host_browsertests.cc",
      "../browser/controlled_frame/controlled_frame_interactive_browsertest.cc",
      "../browser/devtools/devtools_interactive_browsertest.cc",
      "../browser/focus_ring_browsertest.cc",
      "../browser/media/webrtc/display_media_access_handler_interactive_uitest.cc",
      "../browser/media/webrtc/media_stream_permission_interactive_uitest.cc",
      "../browser/media/webrtc/webrtc_interactive_uitest.cc",
      "../browser/media/webrtc/webrtc_mediadevices_interactive_uitest.cc",
      "../browser/mouse_events_interactive_uitest.cc",
      "../browser/net/cookie_encryption_provider_browsertest.cc",
      "../browser/new_tab_page/modules/new_tab_page_modules_interactive_uitest.cc",
      "../browser/new_tab_page/modules/test_support.cc",
      "../browser/new_tab_page/modules/test_support.h",
      "../browser/new_tab_page/new_tab_page_interactive_uitest.cc",
      "../browser/notifications/platform_notification_service_interactive_uitest.cc",
      "../browser/password_manager/password_generation_interactive_uitest.cc",
      "../browser/password_manager/password_manager_interactive_test_base.cc",
      "../browser/password_manager/password_manager_interactive_test_base.h",
      "../browser/password_manager/password_manager_interactive_uitest.cc",
      "../browser/preloading/prerender/prerender_omnibox_ui_browsertest.cc",
      "../browser/privacy_sandbox/browsing_topics_settings_interactive_uitest.cc",
      "../browser/renderer_context_menu/link_to_text_menu_observer_interactive_uitest.cc",
      "../browser/renderer_context_menu/render_view_context_menu_browsertest_util.cc",
      "../browser/renderer_context_menu/render_view_context_menu_browsertest_util.h",
      "../browser/renderer_context_menu/render_view_context_menu_interactive_uitest.cc",
      "../browser/select_popup_browsertest.cc",
      "../browser/sessions/session_restore_interactive_uitest.cc",
      "../browser/site_isolation/site_per_process_interactive_browsertest.cc",
      "../browser/site_isolation/site_per_process_text_input_browsertest.cc",
      "../browser/ssl/typed_navigation_upgrade_throttle_browsertest.cc",
      "../browser/ui/autofill/autofill_context_menu_manager_interactive_uitest.cc",
      "../browser/ui/autofill/autofill_popup_controller_interactive_uitest.cc",
      "../browser/ui/autofill/chrome_autofill_client_interactive_uitest.cc",
      "../browser/ui/browser_command_controller_interactive_browsertest.cc",
      "../browser/ui/browser_focus_uitest.cc",
      "../browser/ui/exclusive_access/fullscreen_controller_interactive_browsertest.cc",
      "../browser/ui/exclusive_access/fullscreen_controller_state_interactive_browsertest.cc",
      "../browser/ui/exclusive_access/fullscreen_interactive_browsertest.cc",
      "../browser/ui/fullscreen_keyboard_browsertest_base.cc",
      "../browser/ui/fullscreen_keyboard_browsertest_base.h",
      "../browser/ui/hung_renderer/hung_renderer_interactive_uitest.cc",
      "../browser/ui/keyboard_lock_interactive_browsertest.cc",
      "../browser/ui/omnibox/omnibox_view_browsertest.cc",
      "../browser/ui/passwords/manage_passwords_test.cc",
      "../browser/ui/passwords/manage_passwords_test.h",
      "../browser/ui/performance_controls/tab_resource_usage_tab_helper_interactive_uitest.cc",
      "../browser/ui/search/instant_extended_interactive_uitest.cc",
      "../browser/ui/search/instant_test_base.cc",
      "../browser/ui/search/instant_test_base.h",
      "../browser/ui/search/third_party_ntp_uitest.cc",
      "../browser/ui/side_search/side_search_tab_contents_helper_interactive_uitest.cc",
      "../browser/ui/signin/signin_view_controller_interactive_uitest.cc",
      "../browser/ui/startup/invalid_user_data_dir_interactive_uitest.cc",
      "../browser/ui/startup/startup_browser_creator_interactive_uitest.cc",
      "../browser/ui/test/browser_ui_interactive_uitest.cc",
      "../browser/ui/test/browser_ui_test_base.cc",
      "../browser/ui/test/browser_ui_test_base.h",
      "../browser/ui/test/fullscreen_test_util.cc",
      "../browser/ui/test/fullscreen_test_util.h",
      "../browser/ui/test/popup_multiscreen_interactive_uitest.cc",
      "../browser/ui/test/test_browser_dialog.cc",
      "../browser/ui/test/test_browser_dialog.h",
      "../browser/ui/thumbnails/thumbnail_tab_helper_interactive_uitest.cc",
      "../browser/ui/views/autofill/payments/iban_bubble_view_uitest.cc",
      "../browser/ui/views/autofill/payments/local_card_migration_uitest.cc",
      "../browser/ui/views/content_test_utils.cc",
      "../browser/ui/views/content_test_utils.h",
      "../browser/ui/views/extensions/extensions_menu_main_page_view_interactive_uitest.cc",
      "../browser/ui/views/extensions/extensions_menu_site_permissions_page_view_interactive_uitest.cc",
      "../browser/ui/views/extensions/extensions_menu_view_interactive_uitest.cc",
      "../browser/ui/views/extensions/mv2_disabled_dialog_controller_interactive_uitest.cc",
      "../browser/ui/views/location_bar/cookie_controls/cookie_controls_bubble_view_pixel_test.cc",
      "../browser/ui/views/media_router/media_router_dialog_controller_views_interactive_uitest.cc",
      "../browser/ui/views/page_info/page_info_bubble_view_interactive_uitest.cc",
      "../browser/ui/views/permissions/midi_permissions_flow_interactive_uitest.cc",
      "../browser/ui/views/permissions/permission_rhs_indicators_interactive_uitest.cc",
      "../browser/ui/views/plus_addresses/plus_address_creation_dialog_interactive_uitest.cc",
      "../browser/ui/views/privacy_sandbox/privacy_sandbox_dialog_view_interactive_ui_test.cc",
      "../browser/ui/views/side_panel/read_anything/read_anything_side_panel_controller_interactive_uitest.cc",
      "../browser/ui/views/web_apps/frame_toolbar/web_app_frame_toolbar_interactive_uitest.cc",
      "../browser/ui/views/web_dialog_view_browsertest.cc",
      "../browser/ui/web_applications/web_app_interactive_uitest.cc",
      "../browser/ui/webui/access_code_cast/access_code_cast_dialog_browsertest.cc",
      "../browser/ui/webui/access_code_cast/access_code_cast_handler_browsertest.cc",
      "../browser/ui/webui/cr_components/history_embeddings/history_embeddings_interactive_uitest.cc",
      "../browser/ui/webui/downloads/downloads_page_interactive_uitest.cc",
      "../browser/ui/webui/settings/performance_settings_interactive_uitest.cc",
      "../browser/ui/webui/settings/settings_interactive_uitest.cc",
      "../browser/ui/webui/side_panel/customize_chrome/wallpaper_search/wallpaper_search_interactive_uitest.cc",
      "../browser/webapps/web_app_offline_browsertest.cc",
      "../browser/webauth_interactive_uitest.cc",
      "../browser/webauthn/chrome_webauthn_autofill_interactive_uitest.cc",
      "//ui/base/clipboard/clipboard_unittest.cc",
      "base/interactive_ui_tests_main.cc",
    ]

    if (!is_chrome_for_testing) {
      sources += [ "../browser/search_engine_choice/search_engine_choice_dialog_interactive_uitest.cc" ]
    }

    if (is_mac || is_linux || is_win) {
      sources += [
        "../browser/ui/views/default_link_capturing_interactive_uitest.cc",
        "../browser/ui/views/media_preview/permission_prompt_preview_browsertest.cc",
      ]
    }

    if (enable_dice_support) {
      sources += [ "../browser/ui/views/promos/autofill_bubble_signin_promo_interactive_uitest.cc" ]
    }

    configs += [ "//build/config:precompiled_headers" ]
    if ((is_linux || is_chromeos) && !is_component_build) {
      configs += [ "//build/config/gcc:rpath_for_built_shared_libraries" ]
    }

    data = [
      "data/",
      "//components/test/data/autofill/",
      "//content/test/data/",
      "//net/tools/testserver/",
      "//third_party/node/node_modules/mocha/mocha.js",
      "//third_party/pywebsocket3/src/mod_pywebsocket/",
      "//tools/metrics/histograms/enums.xml",
      "//ui/webui/resources/js/",
      "//google_apis/test/",
    ]

    defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]
    ldflags = []

    deps = [
      ":chrome_test_launcher",
      ":sync_integration_test_support",
      ":test_support",
      ":test_support_ui",
      ":webrtc_browser_tests_base",
      "//build:chromeos_buildflags",
      "//chrome:packed_resources",
      "//chrome:resources",
      "//chrome:strings",
      "//chrome/app:command_ids",
      "//chrome/browser",
      "//chrome/browser:buildflags",
      "//chrome/browser:main_extra_parts",
      "//chrome/browser:unexpire_flags",
      "//chrome/browser/apps/app_service",
      "//chrome/browser/apps/app_service:app_registry_cache_waiter",
      "//chrome/browser/apps/app_service/app_icon",
      "//chrome/browser/apps/link_capturing",
      "//chrome/browser/apps/link_capturing:features",
      "//chrome/browser/apps/link_capturing:test_support",
      "//chrome/browser/autofill",
      "//chrome/browser/autofill:interactive_ui_tests",
      "//chrome/browser/autofill:test_support_ui",
      "//chrome/browser/devtools",
      "//chrome/browser/devtools:test_support",
      "//chrome/browser/media/router/discovery/access_code:access_code_cast_feature",
      "//chrome/browser/media/router/discovery/access_code:access_code_sink_service",
      "//chrome/browser/media/webrtc",
      "//chrome/browser/optimization_guide:test_support",
      "//chrome/browser/permissions",
      "//chrome/browser/permissions:interactive_ui_tests",
      "//chrome/browser/policy:test_support",
      "//chrome/browser/search",
      "//chrome/browser/search_engines",
      "//chrome/browser/sync",
      "//chrome/browser/themes",
      "//chrome/browser/ui",
      "//chrome/browser/ui:browser_element_identifiers",
      "//chrome/browser/ui:ui_features",
      "//chrome/browser/ui/apps",
      "//chrome/browser/ui/autofill/payments:interactive_ui_tests",
      "//chrome/browser/ui/blocked_content:interactive_ui_tests",
      "//chrome/browser/ui/browser_window",
      "//chrome/browser/ui/exclusive_access",
      "//chrome/browser/ui/find_bar:interactive_ui_tests",
      "//chrome/browser/ui/find_bar:test_support",
      "//chrome/browser/ui/lens:interactive_ui_tests",
      "//chrome/browser/ui/omnibox",
      "//chrome/browser/ui/toasts",
      "//chrome/browser/ui/views/bubble",
      "//chrome/browser/ui/views/side_panel",
      "//chrome/browser/ui/views/toolbar",
      "//chrome/browser/web_applications:interactive_ui_tests",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//chrome/browser/webauthn:test_support",
      "//chrome/common:version_header",
      "//chrome/common/notifications",
      "//chrome/renderer",
      "//chrome/test/media_router:browser_tests",
      "//chrome/test/media_router/access_code_cast:access_code_cast_integration_base",
      "//components/accessibility:reading",
      "//components/autofill/content/browser:test_support",
      "//components/autofill/core/common:credit_card_number_validation",
      "//components/back_forward_cache",
      "//components/blocked_content",
      "//components/bookmarks/browser",
      "//components/bookmarks/common",
      "//components/constrained_window",
      "//components/content_settings/browser",
      "//components/content_settings/core/test:test_support",
      "//components/country_codes",
      "//components/custom_handlers",
      "//components/embedder_support",
      "//components/enterprise:test_support",
      "//components/feature_engagement/public",
      "//components/feature_engagement/test:test_support",
      "//components/flags_ui",
      "//components/fullscreen_control",
      "//components/global_media_controls",
      "//components/history_embeddings",
      "//components/infobars/content",
      "//components/input",
      "//components/javascript_dialogs",
      "//components/keep_alive_registry",
      "//components/live_caption",
      "//components/live_caption:constants",
      "//components/media_device_salt",
      "//components/media_message_center",
      "//components/media_router/browser:test_support",
      "//components/metrics:content",
      "//components/os_crypt/sync:test_support",
      "//components/password_manager/content/browser",
      "//components/plus_addresses",
      "//components/plus_addresses:test_support",
      "//components/plus_addresses/settings",
      "//components/plus_addresses/settings:test_support",
      "//components/privacy_sandbox:privacy_sandbox",
      "//components/privacy_sandbox:privacy_sandbox_prefs",
      "//components/privacy_sandbox:tracking_protection_prefs",
      "//components/privacy_sandbox:tracking_protection_settings",
      "//components/reading_list/core",
      "//components/reading_list/features:flags",
      "//components/resources",
      "//components/safe_browsing/core/common",
      "//components/safe_browsing/core/common:safe_browsing_policy_handler",
      "//components/saved_tab_groups:core",
      "//components/search",
      "//components/security_interstitials/content:security_interstitial_page",
      "//components/shared_highlighting/core/common",
      "//components/site_engagement/content",
      "//components/soda:constants",
      "//components/sync",
      "//components/sync:test_support",
      "//components/sync_bookmarks",
      "//components/sync_device_info:test_support",
      "//components/tab_groups",
      "//components/translate/content/browser:test_support",
      "//components/ukm:test_support",
      "//components/ukm:ukm_test_helper",
      "//components/user_education/common",
      "//components/user_education/test",
      "//components/webapps/browser:test_support",
      "//components/webapps/common",
      "//components/webauthn/core/browser:test_support",
      "//content/test:browsertest_support",
      "//content/test:test_support",
      "//crypto:test_support",
      "//device/bluetooth:mocks",
      "//device/fido:test_support",
      "//extensions/buildflags",
      "//google_apis:test_support",
      "//mojo/core/embedder",
      "//net",
      "//net:net_resources",
      "//net:test_support",
      "//services/metrics/public/cpp:ukm_builders",
      "//skia",
      "//testing/gmock",
      "//testing/gtest",
      "//third_party/hunspell",
      "//third_party/icu",
      "//third_party/libpng",
      "//ui/base:base_interactive_ui_tests",
      "//ui/base:ozone_buildflags",
      "//ui/base:test_support",
      "//ui/base/clipboard:clipboard_test_support",
      "//ui/compositor:test_support",
      "//ui/display:test_support",
      "//ui/events:events_interactive_ui_tests",
      "//ui/events:gesture_detection",
      "//ui/events:test_support",
      "//ui/strings:ui_strings_grit",
      "//ui/views",
      "//ui/web_dialogs:test_support",
    ]

    if (include_js_tests) {
      deps += [ "//chrome/test/data/webui:interactive_ui_tests" ]
    }
    if (include_js2gtest_tests && is_chromeos_ash) {
      data += js2gtest_js_libraries
      deps +=
          [ "//chrome/test/data/webui/chromeos:interactive_ui_tests_js_webui" ]
    }

    # Runtime dependencies
    data_deps = [
      "//chrome:browser_tests_pak",
      "//testing/buildbot/filters:interactive_ui_tests_filters",
      "//third_party/angle:includes",
      "//ui/resources:ui_test_pak_data",
    ]

    if (enable_extensions) {
      sources += [
        "../browser/apps/guest_view/web_view_interactive_browsertest.cc",
        "../browser/apps/platform_apps/app_browsertest_util.cc",
        "../browser/apps/platform_apps/app_browsertest_util.h",
        "../browser/apps/platform_apps/app_pointer_lock_interactive_uitest.cc",
        "../browser/apps/platform_apps/app_window_interactive_uitest.cc",
        "../browser/apps/platform_apps/app_window_interactive_uitest_base.cc",
        "../browser/apps/platform_apps/app_window_interactive_uitest_base.h",
        "../browser/extensions/api/extension_action/browser_action_interactive_test.cc",
        "../browser/extensions/api/extension_action/extension_action_api_interactive_uitest.cc",
        "../browser/extensions/api/extension_action/page_action_interactive_test.cc",
        "../browser/extensions/api/notifications/notifications_apitest.cc",
        "../browser/extensions/api/omnibox/omnibox_api_interactive_test.cc",
        "../browser/extensions/api/permissions/permissions_api_interactive_uitest.cc",
        "../browser/extensions/api/runtime/runtime_interactive_apitest.cc",
        "../browser/extensions/api/tabs/tabs_interactive_test.cc",
        "../browser/extensions/api/tabs/window_open_interactive_apitest.cc",
        "../browser/extensions/app_window_uitest.cc",
        "../browser/extensions/extension_apitest.cc",
        "../browser/extensions/extension_browsertest.cc",
        "../browser/extensions/extension_commands_global_registry_apitest.cc",
        "../browser/extensions/extension_crash_recovery_browsertest.cc",
        "../browser/extensions/extension_fullscreen_apitest.cc",
        "../browser/extensions/extension_keybinding_apitest.cc",
        "../browser/extensions/omnibox_focus_interactive_test.cc",
        "../browser/guest_view/mime_handler_view/chrome_mime_handler_view_interactive_uitest.cc",
      ]

      deps += [ "//chrome/browser/controlled_frame:test_support" ]

      if (is_chromeos_ash) {
        # For ChromeVox tests.
        data_deps +=
            [ "//chrome/browser/resources/chromeos/accessibility:build" ]
        data += [ "$root_out_dir/resources/chromeos/" ]
      }
    }

    if (enable_ppapi) {
      sources += [ "ppapi/ppapi_interactive_browsertest.cc" ]
      deps += [ "//ppapi/shared_impl:test_support" ]
      data_deps += [ "//ppapi:ppapi_tests" ]
    }

    if (is_linux) {
      deps += [ "//ui/linux:test_support" ]
    }

    if (is_linux || is_chromeos || is_win) {
      data_deps += [ "//chrome:packed_resources" ]
    }

    if (!is_chromeos) {
      sources += [
        "../browser/password_manager/web_app_profile_switcher_interactive_uitest.cc",
        "../browser/ui/startup/default_browser_prompt/default_browser_prompt_interactive_uitest.cc",
        "../browser/ui/views/infobars/default_browser_infobar_interactive_uitest.cc",
      ]
    }

    if (use_ozone) {
      deps += [
        "//ui/ozone",
        "//ui/ozone:ozone_interactive_ui_tests",
        "//ui/platform_window/common",
      ]
    }

    if (use_aura) {
      sources += [ "../browser/ui/views/drag_and_drop_interactive_uitest.cc" ]

      deps += [
        "//chrome/browser/ui/aura/accessibility:interactive_ui_tests",
        "//ui/aura:aura_interactive_ui_tests",
        "//ui/aura:test_support",
        "//ui/base/dragdrop:types",
        "//ui/base/dragdrop/mojom",
      ]
    }

    # LaCrOS opens EyeDropper in ash via crosapi. Tests only work for ash.
    if (use_aura && !is_chromeos_lacros) {
      sources += [ "../browser/ui/views/eye_dropper/eye_dropper_view_aura_interactive_uitest.cc" ]
      deps += [ "//components/eye_dropper" ]
    }

    if (toolkit_views) {
      sources += [
        "../browser/media/webrtc/conditional_focus_browsertest.cc",
        "../browser/ui/autofill/address_bubbles_controller_interactive_uitest.cc",
        "../browser/ui/autofill/delete_address_profile_dialog_controller_impl_interactive_uitest.cc",
        "../browser/ui/autofill/edit_address_profile_dialog_controller_impl_interactive_uitest.cc",
        "../browser/ui/commerce/mock_commerce_ui_tab_helper.cc",
        "../browser/ui/commerce/mock_commerce_ui_tab_helper.h",
        "../browser/ui/toolbar/app_menu_fullscreen_interactive_uitest.cc",
        "../browser/ui/toolbar/app_menu_model_interactive_uitest.cc",
        "../browser/ui/user_education/show_promo_in_page_interactive_uitest.cc",
        "../browser/ui/views/autofill/payments/mandatory_reauth_bubble_view_uitest.cc",
        "../browser/ui/views/autofill/payments/offer_notification_bubble_views_interactive_uitest.cc",
        "../browser/ui/views/autofill/payments/save_payment_method_and_virtual_card_enroll_confirmation_bubble_views_interactive_uitest.cc",
        "../browser/ui/views/autofill/payments/virtual_card_enroll_bubble_views_interactive_uitest.cc",
        "../browser/ui/views/autofill/payments/virtual_card_manual_fallback_bubble_views_interactive_uitest.cc",
        "../browser/ui/views/bookmarks/bookmark_bar_view_test.cc",
        "../browser/ui/views/bookmarks/bookmark_bar_view_test_helper.h",
        "../browser/ui/views/bookmarks/bookmark_bubble_view_interactive_uitest.cc",
        "../browser/ui/views/bookmarks/saved_tab_groups/saved_tab_group_interactive_uitest.cc",
        "../browser/ui/views/browser_accelerator_interactive_uitest.cc",
        "../browser/ui/views/certificate_selector_browsertest.cc",
        "../browser/ui/views/commerce/discounts_interactive_uitest.cc",
        "../browser/ui/views/commerce/price_insights_icon_view_interactive_uitest.cc",
        "../browser/ui/views/commerce/price_tracking_email_dialog_view_interactive_uitest.cc",
        "../browser/ui/views/commerce/price_tracking_icon_view_interactive_uitest.cc",
        "../browser/ui/views/constrained_window_views_browsertest.cc",
        "../browser/ui/views/content_setting_bubble_contents_interactive_uitest.cc",
        "../browser/ui/views/data_sharing/data_sharing_bubble_interactive_test.cc",
        "../browser/ui/views/exclusive_access_bubble_views_interactive_uitest.cc",
        "../browser/ui/views/extensions/extension_popup_interactive_uitest.cc",
        "../browser/ui/views/extensions/extensions_toolbar_container_interactive_uitest.cc",
        "../browser/ui/views/extensions/extensions_toolbar_interactive_uitest.cc",
        "../browser/ui/views/extensions/extensions_toolbar_interactive_uitest.h",
        "../browser/ui/views/external_protocol_dialog_interactive_uitest.cc",
        "../browser/ui/views/find_bar_views_interactive_uitest.cc",
        "../browser/ui/views/frame/browser_view_focus_uitest.cc",
        "../browser/ui/views/frame/browser_view_interactive_uitest.cc",
        "../browser/ui/views/frame/picture_in_picture_browser_frame_view_interactive_uitest.cc",
        "../browser/ui/views/frame/tab_strip_region_view_interactive_uitest.cc",
        "../browser/ui/views/fullscreen_control/fullscreen_control_view_interactive_uitest.cc",
        "../browser/ui/views/keyboard_access_interactive_uitest.cc",
        "../browser/ui/views/location_bar/cookie_controls/cookie_controls_interactive_uitest.cc",
        "../browser/ui/views/location_bar/lens_overlay_page_action_icon_view_interactive_uitest.cc",
        "../browser/ui/views/location_bar/location_icon_view_interactive_uitest.cc",
        "../browser/ui/views/location_bar/selected_keyword_view_interactive_uitest.cc",
        "../browser/ui/views/location_bar/star_view_interactive_uitest.cc",
        "../browser/ui/views/media_router/media_router_ui_interactive_uitest.cc",
        "../browser/ui/views/menu_controller_interactive_uitest.cc",
        "../browser/ui/views/menu_interactive_uitest.cc",
        "../browser/ui/views/menu_item_view_interactive_uitest.cc",
        "../browser/ui/views/menu_model_adapter_test.cc",
        "../browser/ui/views/menu_test_base.cc",
        "../browser/ui/views/menu_test_base.h",
        "../browser/ui/views/menu_view_drag_and_drop_test.cc",
        "../browser/ui/views/omnibox/omnibox_popup_view_views_interactive_uitest.cc",
        "../browser/ui/views/omnibox/omnibox_popup_view_webui_interactive_uitest.cc",
        "../browser/ui/views/omnibox/omnibox_view_views_browsertest.cc",
        "../browser/ui/views/passwords/manage_passwords_icon_view_interactive_uitest.cc",
        "../browser/ui/views/passwords/password_bubble_interactive_uitest.cc",
        "../browser/ui/views/performance_controls/memory_saver_interactive_ui_test.cc",
        "../browser/ui/views/performance_controls/memory_saver_iph_interactive_uitest.cc",
        "../browser/ui/views/performance_controls/performance_intervention_interactive_ui_test.cc",
        "../browser/ui/views/permissions/chip/LHS_indicators_interactive_uitest.cc",
        "../browser/ui/views/permissions/chip/dashboard_kombucha_interactive_uitest.cc",
        "../browser/ui/views/permissions/chip/permission_chip_interactive_uitest.cc",
        "../browser/ui/views/permissions/chip/permission_chip_kombucha_interactive_uitest.cc",
        "../browser/ui/views/permissions/embedded_permission_prompt_interactive_uitest.cc",
        "../browser/ui/views/permissions/exclusive_access_permission_prompt_interactive_uitest.cc",
        "../browser/ui/views/permissions/one_time_permission_interactive_ui_test.cc",
        "../browser/ui/views/permissions/permission_bubble_interactive_uitest.cc",
        "../browser/ui/views/permissions/permission_indicators_interactive_uitest.cc",
        "../browser/ui/views/permissions/permission_metrics_ui_test.cc",
        "../browser/ui/views/sad_tab_view_interactive_uitest.cc",
        "../browser/ui/views/side_panel/side_panel_interactive_uitest.cc",
        "../browser/ui/views/side_search/side_search_browsertest.cc",
        "../browser/ui/views/side_search/side_search_browsertest.h",
        "../browser/ui/views/site_data/page_specific_site_data_dialog_interactive_uitest.cc",
        "../browser/ui/views/ssl_client_certificate_selector_browsertest.cc",
        "../browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc",
        "../browser/ui/views/tabs/tab_drag_controller_interactive_uitest.h",
        "../browser/ui/views/tabs/tab_hover_card_controller_interactive_uitest.cc",
        "../browser/ui/views/test/view_event_test_base.cc",
        "../browser/ui/views/test/view_event_test_base.h",
        "../browser/ui/views/toolbar/browser_app_menu_button_interactive_uitest.cc",
        "../browser/ui/views/toolbar/reload_button_browsertest.cc",
        "../browser/ui/views/toolbar/toolbar_action_hover_card_bubble_view_interactive_uitest.cc",
        "../browser/ui/views/toolbar/toolbar_controller_interactive_uitest.cc",
        "../browser/ui/views/toolbar/toolbar_view_interactive_uitest.cc",
        "../browser/ui/views/translate/translate_bubble_test_utils_views.cc",
        "../browser/ui/views/translate/translate_bubble_view_interactive_uitest.cc",
        "../browser/ui/views/translate/translate_icon_view_interactive_uitest.cc",
        "../browser/ui/views/user_education/browser_feature_promo_controller_interactive_uitest.cc",
        "../browser/ui/views/user_education/browser_user_education_service_interactive_uitest.cc",
        "../browser/ui/views/user_education/feature_promo_dialog_interactive_uitest.cc",
        "../browser/ui/views/user_education/feature_promo_lifecycle_interactive_uitest.cc",
        "../browser/ui/views/user_education/help_bubble_factory_registry_interactive_uitest.cc",
        "../browser/ui/views/user_education/help_bubble_factory_views_interactive_uitest.cc",
        "../browser/ui/views/user_education/help_bubble_factory_webui_interactive_uitest.cc",
        "../browser/ui/views/user_education/help_bubble_handler_interactive_uitest.cc",
        "../browser/ui/views/user_education/help_bubble_view_interactive_uitest.cc",
        "../browser/ui/views/user_education/product_messaging_controller_interactive_uitest.cc",
        "../browser/ui/views/user_education/tutorial_interactive_uitest.cc",
        "interaction/interaction_sequence_interactive_uitest.cc",
        "interaction/interaction_test_util_browser_interactive_uitest.cc",
        "interaction/interaction_test_util_interactive_uitest.cc",
        "interaction/interaction_test_util_mouse_interactive_uitest.cc",
        "interaction/interactive_browser_test_interactive_uitest.cc",
        "interaction/webcontents_interaction_test_util_interactive_uitest.cc",
      ]
      deps += [
        "//chrome/app/vector_icons:vector_icons",
        "//chrome/browser/image_fetcher",
        "//chrome/browser/ui/actions:actions",
        "//chrome/browser/ui/find_bar",
        "//chrome/browser/ui/lens",
        "//components/commerce/core:feature_list",
        "//components/commerce/core:shopping_service_test_support",
        "//components/data_sharing/public",
        "//components/image_fetcher/core:test_support",
        "//components/lens:features",
        "//components/live_caption:utils",
        "//components/lookalikes/core:safety_tips",
        "//components/omnibox/browser:vector_icons",
        "//components/optimization_guide/core:test_support",
        "//components/optimization_guide/proto:optimization_guide_proto",
        "//components/page_content_annotations/core:test_support",
        "//components/performance_manager:performance_manager",
        "//components/power_bookmarks/core:features",
        "//components/privacy_sandbox/privacy_sandbox_attestations",
        "//components/privacy_sandbox/privacy_sandbox_attestations:test_support",
        "//components/user_education/common:events",
        "//components/user_education/views",
        "//components/user_education/webui",
        "//components/user_notes:features",
        "//components/webapps/browser:browser",
        "//ui/accessibility:test_support",
        "//ui/base/dragdrop:types",
        "//ui/base/dragdrop/mojom",
        "//ui/views",
        "//ui/views:test_support",
        "//ui/views:views_interactive_ui_tests",
        "//ui/views/controls/webview:test_support",
      ]
      if (enable_pdf) {
        sources += [ "../browser/pdf/pdf_extension_interactive_uitest.cc" ]
        deps += [
          "../browser/pdf:pdf_extension_test_utils",
          "//pdf:features",
        ]
      }
      if (is_chromeos) {
        sources += [
          "../browser/signin/mirror_interactive_uitest.cc",
          "../browser/ui/views/toolbar/browser_app_menu_button_interactive_uitest_chromeos.cc",
        ]
        deps += [ "//chrome/browser/ui/chromeos" ]
      } else {
        deps += [ "//chrome/browser/ui/views/shortcuts:interactive_ui_tests" ]
      }
      if (is_linux || is_chromeos_lacros) {
        # Desktop linux.
        sources -= [
          # TODO(port): This times out. Attempts have been made to fix the
          # individual failures, but each time I disable a test from these
          # suites, it seems like one or another starts timing out too.
          "../browser/ui/views/keyboard_access_interactive_uitest.cc",
        ]
      }
      if (is_chromeos_ash) {
        sources += [
          "../browser/ui/web_applications/test/system_web_app_interactive_uitest.cc",
          "../browser/ui/webui/print_preview/print_preview_chromeos_interactive_uitest.cc",
          "//ash/drag_drop/drag_drop_interactive_uitest.cc",
        ]

        if (is_chrome_branded) {
          deps +=
              [ "//chrome/browser/ui/ash/container_app:interactive_ui_tests" ]
        }

        deps += [
          "//ash",
          "//ash:interactive_ui_test_support",
          "//ash/webui/print_management:print_management",
          "//chrome/browser/apps/app_service",
          "//chrome/browser/ash/accessibility",
          "//chrome/browser/ash/accessibility:test_support",
          "//chrome/browser/ash/app_restore",
          "//chrome/browser/ash/child_accounts:test_support",
          "//chrome/browser/ash/child_accounts/time_limits:test_support",
          "//chrome/browser/ash/crosapi",
          "//chrome/browser/ash/login:test_support",
          "//chrome/browser/ash/login/ui",
          "//chrome/browser/ash/system_web_apps/apps",
          "//chrome/browser/ash/system_web_apps/test_support",
          "//chrome/browser/ash/system_web_apps/test_support:test_support_ui",
          "//chrome/browser/ui/ash",
          "//chrome/browser/ui/ash/cast_config",
          "//chrome/browser/ui/ash/multi_user",
          "//chrome/test/base/ash/interactive:test_support",
          "//chromeos/ash/components/dbus/fwupd",
          "//chromeos/ash/components/fwupd",
          "//chromeos/ash/components/standalone_browser",
          "//components/app_constants",
          "//device/udev_linux:test_support",
          "//ui/chromeos",
          "//ui/events/devices",
          "//ui/events/devices:test_support",

          # Gather tests from other build files:
          "//chrome/browser/ash:interactive_ui_tests",
          "//chrome/browser/ui/ash:interactive_ui_tests",
          "//chrome/browser/ui/webui/ash:interactive_ui_tests",
          "//chrome/test/base/ash/interactive:interactive_ui_tests",
        ]
      } else {
        sources += [
          "../browser/ui/views/download/bubble/download_bubble_interactive_uitest.cc",
          "../browser/ui/views/global_media_controls/media_dialog_view_interactive_browsertest.cc",
          "../browser/ui/views/relaunch_notification/relaunch_notification_controller_platform_impl_desktop_browsertest.cc",
        ]
        if (enable_update_notifications) {
          sources += [ "../browser/ui/views/relaunch_notification/relaunch_notification_controller_interactive_uitest.cc" ]
        }
        deps += [
          "../browser/media/router:test_support",
          "../browser/ui/views:test_support",
          "//components/media_router/browser:test_support",
        ]
      }
      if (use_aura) {
        sources += [ "../browser/ui/views/tooltip/tooltip_browsertest.cc" ]
        deps += [ "//ui/wm/public" ]
      }
      if (use_aura || is_mac) {
        deps += [ "//ui/touch_selection" ]
      }
      if (is_mac) {
        deps += [ "//content/test:browsertest_support" ]
      }
      if (is_win) {
        sources += [
          "../browser/ui/views/accessibility/post_install_announcement_browsertest.cc",
          "../browser/ui/views/frame/browser_window_property_manager_browsertest_win.cc",
          "../browser/ui/views/status_icons/status_tray_state_changer_interactive_uitest_win.cc",
        ]
        if (use_aura) {
          sources += [ "../browser/ui/views/tooltip/tooltip_aura_interactive_uitest_win.cc" ]
        }
      }
    }

    if (is_chromeos_ash) {
      deps += [
        "//ash/constants",
        "//chrome/browser/ash/app_list/app_service",
        "//chrome/browser/media/router:test_support",
        "//chrome/browser/ui/ash/privacy_hub:interactive_ui_tests",
        "//chrome/browser/ui/ash/system_web_apps",
        "//chromeos/ash/components/dbus",
        "//chromeos/ash/components/login/auth",
        "//chromeos/ui/frame:test_support",
        "//components/exo/wayland:test_controller_stub",
        "//components/exo/wayland:ui_controls_protocol_stub",
        "//ui/display:display_manager_test_api",
        "//ui/display/manager",
      ]

      # These tests are not applicable on Chrome OS.
      sources -= [
        "../browser/ui/signin/signin_view_controller_interactive_uitest.cc",
      ]
    } else {  # ! is_chromeos_ash
      # Non-ChromeOS notifications tests.
      sources += [
        "../browser/notifications/notification_interactive_uitest.cc",
        "../browser/notifications/notification_interactive_uitest_support.cc",
        "../browser/notifications/notification_interactive_uitest_support.h",
      ]
    }

    if (is_chromeos) {
      deps += [
        ":print_preview_test_support",
        "//chrome/browser/chromeos",
        "//chrome/browser/chromeos:interactive_ui_tests",
        "//chrome/browser/smart_card:interactive_ui_tests",
        "//chrome/browser/ui/chromeos:test_support",
        "//chromeos/constants",
        "//chromeos/dbus/dlp:dlp",
        "//chromeos/ui/base",
        "//chromeos/ui/frame",
        "//chromeos/ui/frame:test_support",
        "//components/file_access:test_support",
        "//components/reporting/client:report_queue",
        "//components/reporting/client:test_support",
        "//components/reporting/storage:test_support",
        "//components/reporting/util:test_callbacks_support",
      ]

      if (enable_printing) {
        deps += [ "//components/printing/common:mojo_interfaces" ]
      }
    }

    if (is_chromeos_lacros) {
      sources +=
          [ "../browser/lacros/browser_activation_interactive_uitest.cc" ]

      # These tests require a MessageCenter which isn't available on Lacros.
      sources -=
          [ "../browser/notifications/notification_interactive_uitest.cc" ]

      deps += [
        ":lacros_test_support_ui",
        "//chromeos/lacros:lacros",
        "//ui/display:managed_display_info",
      ]
    }

    if (is_win) {
      sources += [
        "../browser/downgrade/user_data_downgrade_browsertest.cc",
        "../browser/net/sandboxed_network_change_notifier_win_browsertest.cc",
        "../browser/notifications/notification_platform_bridge_win_interactive_uitest.cc",
        "../browser/notifications/win/fake_itoastnotifier.cc",
        "../browser/notifications/win/fake_itoastnotifier.h",
        "../browser/ui/send_mouse_move_uitest_win.cc",
        "../browser/ui/views/accessibility/navigation_accessibility_uitest_win.cc",
        "../browser/ui/views/accessibility/uia_accessibility_event_waiter.cc",
        "../browser/ui/views/accessibility/uia_accessibility_event_waiter.h",
        "../browser/ui/views/touch_events_interactive_uitest_win.cc",
        "//ui/base/clipboard/clipboard_win_unittest.cc",
        "//ui/display/win/test/virtual_display_util_win_interactive_uitest.cc",
      ]

      if (use_aura) {
        sources += [ "../browser/ui/views/autofill/autofill_accessibility_win_browsertest.cc" ]
      }

      deps += [
        "//chrome:other_version",
        "//chrome/app:chrome_dll_resources",
        "//chrome/browser/os_crypt",
        "//chrome/browser/os_crypt:browser_tests",
        "//chrome/browser/os_crypt:test_support",
        "//chrome/elevation_service:public_headers",
        "//chrome/install_static:install_static_util",
        "//chrome/installer/util:strings",
        "//third_party/isimpledom",
        "//third_party/webrtc_overrides:webrtc_component",
        "//third_party/wtl",
        "//ui/resources",
      ]

      data_deps += [ "//chrome/elevation_service" ]

      libs = [
        "newdev.lib",
        "oleacc.lib",
        "runtimeobject.lib",
      ]
    }

    if (is_mac) {
      sources += [
        "../browser/app_controller_mac_interactive_uitest.mm",
        "../browser/global_keyboard_shortcuts_interactive_uitest_mac.mm",
        "../browser/notifications/mac/notification_interactive_uitest_mac.mm",
        "../browser/spellchecker/spellcheck_mac_view_interactive_uitest.mm",
        "../browser/ui/cocoa/apps/quit_with_apps_controller_mac_interactive_uitest.mm",
        "../browser/ui/cocoa/status_bubble_mac_interactive_uitest.mm",
        "../browser/ui/cocoa/tab_contents/web_contents_view_mac_interactive_uitest.mm",
        "../browser/ui/views/frame/immersive_mode_controller_mac_interactive_uitest.mm",
        "../browser/webauthn/chrome_webauthn_autofill_mac_interactive_uitest.mm",
        "//ui/display/mac/test/virtual_display_util_mac_interactive_uitest.mm",
      ]

      sources -= [
        # TODO(crbug.com/40659953): Re-enable this test when history backend failures are addressed.
        "../browser/ui/omnibox/omnibox_view_browsertest.cc",
      ]

      data_deps += [
        "//chrome",
        "//chrome:chrome_framework",
      ]

      deps += [
        "//chrome/browser/apps/app_shim",
        "//chrome/browser/web_applications/extensions",
        "//components/remote_cocoa/app_shim:app_shim",
        "//components/spellcheck:buildflags",
      ]
    }

    if (enable_downgrade_processing) {
      sources += [ "../browser/downgrade/user_data_snapshot_browsertest.cc" ]
    }

    if (enable_chrome_notifications) {
      sources += [
        "../browser/notifications/notification_ui_manager_browsertest.cc",
        "../browser/notifications/notification_ui_manager_interactive_uitest.cc",
      ]
    }

    if (is_android) {
      sources -= [
        # TODO(peter): Enable the Notification browser tests.
        "../browser/notifications/notification_interactive_uitest.cc",
        "../browser/notifications/platform_notification_service_interactive_uitest.cc",
      ]
    } else {
      sources += [ "../browser/metrics/desktop_session_duration/chrome_visibility_observer_interactive_uitest.cc" ]
    }

    if (use_atk && toolkit_views) {
      sources += [ "../browser/ui/views/accessibility/browser_accessibility_uitest_auralinux.cc" ]
      configs += [ "//build/config/linux/atk" ]
    }

    if (is_linux) {
      if (ozone_platform_x11 && enable_remoting) {
        sources += [ "//ui/display/linux/test/virtual_display_util_linux_interactive_uitest.cc" ]
      }
      deps += [ "//ui/linux:linux_ui" ]
    }

    if (is_linux || is_chromeos_lacros) {
      deps += [ "//ui/base/ime/linux" ]
    }

    if (enable_webui_tab_strip) {
      sources +=
          [ "../browser/ui/views/frame/webui_tab_strip_interactive_uitest.cc" ]
    }

    if (is_win || is_mac || is_linux || is_chromeos_lacros) {
      sources += [
        "../browser/ui/views/profiles/profile_picker_interactive_uitest.cc",
        "../browser/ui/views/profiles/profile_picker_interactive_uitest_base.cc",
        "../browser/ui/views/profiles/profile_picker_interactive_uitest_base.h",
      ]
    }

    if (is_chromeos_lacros) {
      sources += [
        "../browser/ui/views/profiles/first_run_lacros_interactive_uitest.cc",
      ]

      deps += [ "//chromeos/ui/frame:interactive_ui_tests" ]
    }

    if (is_win || is_mac || is_linux) {
      sources += [
        "../browser/enterprise/idle/idle_service_interactive_uitest.cc",
        "../browser/ui/views/profiles/first_run_interactive_uitest.cc",
        "../browser/ui/views/profiles/profile_bubble_interactive_uitest.cc",
      ]

      deps += [ "//components/enterprise/idle" ]
    }

    if (enable_print_preview) {
      sources += [ "../browser/window_management/window_management_printing_interactive_uitest.cc" ]
    }

    if (!is_chromeos_lacros) {
      sources += [
        "../browser/media/router/discovery/access_code/access_code_cast_sink_service_browsertest.cc",
        "../browser/ui/views/accessibility/caption_bubble_controller_views_browsertest.cc",
      ]

      deps += [ "//components/soda:soda" ]
    }

    if (is_chromeos_lacros && !is_chromeos_device) {
      # For support version skew testing.
      data_deps += [ "//build:version_metadata" ]
    }

    if (safe_browsing_mode == 1) {
      sources += [ "../browser/safe_browsing/safe_browsing_navigation_observer_interactive_test.cc" ]
    }

    if (enterprise_data_controls) {
      deps += [
        "//chrome/browser/enterprise/data_controls:test_support",
        "//components/enterprise/data_controls/core/browser",
      ]
    }

    if (enable_compose) {
      sources += [ "../browser/ui/views/compose/compose_interactive_uitest.cc" ]

      deps += [
        "//components/compose/core/browser",
        "//components/compose/core/browser:features",
      ]
    }
  }
}

test("chrome_app_unittests") {
  sources = [ "../app/resources/resources_unittest.cc" ]
  deps = [
    ":test_support",
    "//base/test:run_all_unittests",
    "//base/test:test_support",
    "//chrome/browser",
    "//chrome/child",
    "//chrome/common/profiler",
    "//chrome/gpu",
    "//components/crash/core/common",
    "//components/flags_ui:switches",
    "//components/heap_profiling/in_process",
    "//components/safe_browsing:buildflags",
  ]
  if (is_android) {
    sources += [ "../app/android/chrome_main_delegate_android_unittest.cc" ]
  }
}

if (!is_android) {
  # Everything needed to build/copy to run the performance_browser_tests isolate.
  # See: //testing/buildbot/gn_isolate_map.pyl
  group("performance_browser_tests") {
    testonly = true
    data_deps = [
      ":browser_tests",
      "//testing:run_perf_test",
    ]
  }
}

if (is_android) {
  android_library("sync_integration_test_support_java") {
    testonly = true
    deps = [
      "//chrome/android:chrome_all_java",
      "//chrome/browser/profiles/android:java",
      "//chrome/test/android:chrome_java_integration_test_support",
      "//chrome/test/android:live_signin_test_util_java",
      "//components/gcm_driver/instance_id/android:instance_id_driver_test_support_java",
      "//components/signin/public/android:java",
      "//components/sync/android:sync_java",
      "//content/public/test/android:content_java_test_support",
      "//third_party/jni_zero:jni_zero_java",
      "//third_party/junit",
    ]

    sources = [ "../android/javatests/src/org/chromium/chrome/browser/sync/SyncTestSigninUtils.java" ]
  }

  generate_jni("sync_integration_test_support_jni_headers") {
    testonly = true
    sources = [ "../android/javatests/src/org/chromium/chrome/browser/sync/SyncTestSigninUtils.java" ]
  }
}

# For Android, this target has to be built along with the
# sync_integration_test_support_java target from the test target dependencies.
source_set("sync_integration_test_support") {
  testonly = true
  sources = [
    "../browser/sync/test/integration/autofill_helper.cc",
    "../browser/sync/test/integration/autofill_helper.h",
    "../browser/sync/test/integration/bookmarks_helper.cc",
    "../browser/sync/test/integration/bookmarks_helper.h",
    "../browser/sync/test/integration/committed_all_nudged_changes_checker.cc",
    "../browser/sync/test/integration/committed_all_nudged_changes_checker.h",
    "../browser/sync/test/integration/contact_info_helper.cc",
    "../browser/sync/test/integration/contact_info_helper.h",
    "../browser/sync/test/integration/device_info_helper.cc",
    "../browser/sync/test/integration/device_info_helper.h",
    "../browser/sync/test/integration/encryption_helper.cc",
    "../browser/sync/test/integration/encryption_helper.h",
    "../browser/sync/test/integration/exponential_backoff_helper.cc",
    "../browser/sync/test/integration/exponential_backoff_helper.h",
    "../browser/sync/test/integration/fake_server_match_status_checker.cc",
    "../browser/sync/test/integration/fake_server_match_status_checker.h",
    "../browser/sync/test/integration/fake_sync_gcm_driver_for_instance_id.cc",
    "../browser/sync/test/integration/fake_sync_gcm_driver_for_instance_id.h",
    "../browser/sync/test/integration/history_helper.cc",
    "../browser/sync/test/integration/history_helper.h",
    "../browser/sync/test/integration/invalidations/fake_server_sync_invalidation_sender.cc",
    "../browser/sync/test/integration/invalidations/fake_server_sync_invalidation_sender.h",
    "../browser/sync/test/integration/invalidations/invalidations_status_checker.cc",
    "../browser/sync/test/integration/invalidations/invalidations_status_checker.h",
    "../browser/sync/test/integration/multi_client_status_change_checker.cc",
    "../browser/sync/test/integration/multi_client_status_change_checker.h",
    "../browser/sync/test/integration/offer_helper.cc",
    "../browser/sync/test/integration/offer_helper.h",
    "../browser/sync/test/integration/password_sharing_invitation_helper.cc",
    "../browser/sync/test/integration/password_sharing_invitation_helper.h",
    "../browser/sync/test/integration/passwords_helper.cc",
    "../browser/sync/test/integration/passwords_helper.h",
    "../browser/sync/test/integration/preferences_helper.cc",
    "../browser/sync/test/integration/preferences_helper.h",
    "../browser/sync/test/integration/quiesce_status_change_checker.cc",
    "../browser/sync/test/integration/quiesce_status_change_checker.h",
    "../browser/sync/test/integration/saved_tab_groups_helper.cc",
    "../browser/sync/test/integration/saved_tab_groups_helper.h",
    "../browser/sync/test/integration/secondary_account_helper.cc",
    "../browser/sync/test/integration/secondary_account_helper.h",
    "../browser/sync/test/integration/session_hierarchy_match_checker.cc",
    "../browser/sync/test/integration/session_hierarchy_match_checker.h",
    "../browser/sync/test/integration/shared_tab_group_data_helper.cc",
    "../browser/sync/test/integration/shared_tab_group_data_helper.h",
    "../browser/sync/test/integration/single_client_status_change_checker.cc",
    "../browser/sync/test/integration/single_client_status_change_checker.h",
    "../browser/sync/test/integration/status_change_checker.cc",
    "../browser/sync/test/integration/status_change_checker.h",
    "../browser/sync/test/integration/sync_datatype_helper.cc",
    "../browser/sync/test/integration/sync_datatype_helper.h",
    "../browser/sync/test/integration/sync_disabled_checker.cc",
    "../browser/sync/test/integration/sync_disabled_checker.h",
    "../browser/sync/test/integration/sync_engine_stopped_checker.cc",
    "../browser/sync/test/integration/sync_engine_stopped_checker.h",
    "../browser/sync/test/integration/sync_service_impl_harness.cc",
    "../browser/sync/test/integration/sync_service_impl_harness.h",
    "../browser/sync/test/integration/sync_signin_delegate.cc",
    "../browser/sync/test/integration/sync_signin_delegate.h",
    "../browser/sync/test/integration/sync_test.cc",
    "../browser/sync/test/integration/sync_test.h",
    "../browser/sync/test/integration/updated_progress_marker_checker.cc",
    "../browser/sync/test/integration/updated_progress_marker_checker.h",
    "../browser/sync/test/integration/wallet_helper.cc",
    "../browser/sync/test/integration/wallet_helper.h",
  ]
  if (!is_android) {
    sources += [
      "../browser/sync/test/integration/apps_helper.cc",
      "../browser/sync/test/integration/apps_helper.h",
      "../browser/sync/test/integration/await_match_status_change_checker.cc",
      "../browser/sync/test/integration/await_match_status_change_checker.h",
      "../browser/sync/test/integration/cookie_helper.cc",
      "../browser/sync/test/integration/cookie_helper.h",
      "../browser/sync/test/integration/dictionary_helper.cc",
      "../browser/sync/test/integration/dictionary_helper.h",
      "../browser/sync/test/integration/dictionary_load_observer.cc",
      "../browser/sync/test/integration/dictionary_load_observer.h",
      "../browser/sync/test/integration/extension_settings_helper.cc",
      "../browser/sync/test/integration/extension_settings_helper.h",
      "../browser/sync/test/integration/extensions_helper.cc",
      "../browser/sync/test/integration/extensions_helper.h",
      "../browser/sync/test/integration/migration_waiter.cc",
      "../browser/sync/test/integration/migration_waiter.h",
      "../browser/sync/test/integration/migration_watcher.cc",
      "../browser/sync/test/integration/migration_watcher.h",
      "../browser/sync/test/integration/product_specifications_helper.cc",
      "../browser/sync/test/integration/product_specifications_helper.h",
      "../browser/sync/test/integration/search_engines_helper.cc",
      "../browser/sync/test/integration/search_engines_helper.h",
      "../browser/sync/test/integration/send_tab_to_self_helper.cc",
      "../browser/sync/test/integration/send_tab_to_self_helper.h",
      "../browser/sync/test/integration/sessions_helper.cc",
      "../browser/sync/test/integration/sessions_helper.h",
      "../browser/sync/test/integration/sync_app_helper.cc",
      "../browser/sync/test/integration/sync_app_helper.h",
      "../browser/sync/test/integration/sync_extension_helper.cc",
      "../browser/sync/test/integration/sync_extension_helper.h",
      "../browser/sync/test/integration/sync_integration_test_util.cc",
      "../browser/sync/test/integration/sync_integration_test_util.h",
      "../browser/sync/test/integration/sync_signin_delegate_desktop.cc",
      "../browser/sync/test/integration/sync_signin_delegate_desktop.h",
      "../browser/sync/test/integration/themes_helper.cc",
      "../browser/sync/test/integration/themes_helper.h",
      "../browser/sync/test/integration/user_events_helper.cc",
      "../browser/sync/test/integration/user_events_helper.h",
      "../browser/sync/test/integration/webauthn_credentials_helper.cc",
      "../browser/sync/test/integration/webauthn_credentials_helper.h",
    ]
  } else {
    sources += [
      "../browser/sync/test/integration/sync_signin_delegate_android.cc",
      "../browser/sync/test/integration/sync_signin_delegate_android.h",
      "../browser/sync/test/integration/sync_test_utils_android.cc",
      "../browser/sync/test/integration/sync_test_utils_android.h",
      "../browser/sync/test/integration/webapks_helper.cc",
      "../browser/sync/test/integration/webapks_helper.h",
    ]
  }
  public_deps = [
    ":test_support",
    "//chrome/browser",
    "//chrome/browser/favicon",
    "//components/autofill/content/browser",
    "//components/power_bookmarks/core:features",
  ]
  deps = [
    "//base",
    "//build:chromeos_buildflags",
    "//chrome/browser/autofill",
    "//chrome/browser/search_engines",
    "//chrome/browser/sync",
    "//components/autofill/core/common:credit_card_number_validation",
    "//components/bookmarks/browser",
    "//components/bookmarks/browser:test_support",
    "//components/bookmarks/managed",
    "//components/browser_sync",
    "//components/favicon/core",
    "//components/invalidation/impl",
    "//components/invalidation/impl:test_support",
    "//components/os_crypt/sync:test_support",
    "//components/saved_tab_groups:core",
    "//components/signin/public/identity_manager:test_support",
    "//components/sync",
    "//components/sync:test_support",
    "//components/webapps/common",
    "//content/public/browser",
    "//content/test:test_support",
    "//net",
    "//services/network/public/mojom",
    "//skia",
  ]

  if (is_mac) {
    sources -= [
      "../browser/sync/test/integration/dictionary_helper.cc",
      "../browser/sync/test/integration/dictionary_helper.h",
      "../browser/sync/test/integration/dictionary_load_observer.cc",
      "../browser/sync/test/integration/dictionary_load_observer.h",
    ]
  }
  if (is_chromeos_ash) {
    sources += [
      "../browser/sync/test/integration/printers_helper.cc",
      "../browser/sync/test/integration/printers_helper.h",
      "../browser/sync/test/integration/sync_app_list_helper.cc",
      "../browser/sync/test/integration/sync_app_list_helper.h",
      "../browser/sync/test/integration/sync_arc_package_helper.cc",
      "../browser/sync/test/integration/sync_arc_package_helper.h",
      "../browser/sync/test/integration/workspace_desk_helper.cc",
      "../browser/sync/test/integration/workspace_desk_helper.h",
    ]
    public_deps += [ "//chrome/browser/ash/app_list" ]
    deps += [
      "//ash/app_list:test_support",
      "//ash/components/arc:arc_test_support",
      "//ash/components/arc/mojom",
      "//chrome/browser/ash/app_list/arc",
      "//chrome/browser/ash/app_list/test:test_support",
      "//chrome/browser/ash/arc",
      "//chrome/browser/ash/arc/session",
      "//chrome/browser/ash/net",
      "//chrome/browser/ash/printing",
      "//chrome/browser/ash/system_web_apps/test_support",
      "//chromeos/ash/components/network/portal_detector",
      "//chromeos/printing",
      "//components/desks_storage",
      "//components/user_manager:test_support",
    ]
  }
  if (is_android) {
    deps += [
      ":sync_integration_test_support_jni_headers",
      ":test_support_jni_headers",
      "//chrome/browser/android/webapk:webapk_sources",
    ]
  } else {
    deps += [
      "//chrome/browser/apps/app_service",
      "//chrome/browser/themes",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//components/send_tab_to_self",
      "//components/trusted_vault",
      "//components/webapps/browser",
      "//components/webauthn/core/browser",
      "//components/webauthn/core/browser:passkey_model",
    ]
  }
}

if (!is_android) {
  test("sync_integration_tests") {
    use_xvfb = use_xvfb_in_this_config

    sources = sync_integration_tests_sources

    data = [
      "//chrome/test/data/password/",
      "//chrome/test/data/sync/",
      "//chrome/test/data/webapps_integration/",
      "//chrome/test/data/web_apps/",
      "//chrome/test/data/banners/",
      "//net/tools/testserver/",
      "//third_party/pywebsocket3/src/mod_pywebsocket/",
    ]

    # TODO(phajdan.jr): Only temporary, to make transition easier.
    defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]

    deps = [
      ":browser_tests_runner",
      ":sync_integration_test_support",
      ":test_support",
      ":test_support_ui",
      "//build:chromeos_buildflags",
      "//chrome:packed_resources",
      "//chrome:resources",
      "//chrome:strings",
      "//chrome/app:chrome_dll_resources",
      "//chrome/app:command_ids",
      "//chrome/browser/apps/link_capturing",
      "//chrome/browser/apps/link_capturing:features",
      "//chrome/browser/browsing_data:constants",
      "//chrome/browser/search_engines",
      "//chrome/browser/sync",
      "//chrome/browser/themes",
      "//chrome/browser/ui:browser_navigator_params_headers",
      "//chrome/browser/ui:ui_features",
      "//chrome/browser/web_applications:web_applications_test_support",
      "//chrome/common",
      "//chrome/renderer",
      "//components/app_constants",
      "//components/bookmarks/browser",
      "//components/bookmarks/test",
      "//components/browser_sync",
      "//components/commerce/core:feature_list",
      "//components/consent_auditor",
      "//components/data_sharing/public",
      "//components/favicon/core",
      "//components/history/content/browser",
      "//components/history/core/common",
      "//components/password_manager/core/browser/sharing",
      "//components/plus_addresses",
      "//components/plus_addresses:test_support",
      "//components/plus_addresses/settings",
      "//components/plus_addresses/settings:test_support",
      "//components/plus_addresses/webdata",
      "//components/power_bookmarks/common:test_support",
      "//components/power_bookmarks/core",
      "//components/reading_list/core",
      "//components/reading_list/core:test_support",
      "//components/reading_list/features:flags",
      "//components/saved_tab_groups:core",
      "//components/saved_tab_groups:tab_group_sync_bridge",
      "//components/saved_tab_groups:test_support",
      "//components/send_tab_to_self",
      "//components/spellcheck/common",
      "//components/sync",
      "//components/sync:test_support",
      "//components/sync_bookmarks",
      "//components/sync_device_info:test_support",
      "//components/sync_preferences:common_syncable_prefs_database",
      "//components/trusted_vault",
      "//components/trusted_vault:test_support",
      "//components/undo",
      "//components/version_info",
      "//components/webapps/browser",
      "//components/webapps/common",
      "//components/webauthn/core/browser",
      "//components/webauthn/core/browser:passkey_model",
      "//testing/gmock",
      "//testing/gtest",
      "//third_party/blink/public:blink",
      "//third_party/icu",
      "//third_party/leveldatabase",
    ]

    data_deps = [
      "//testing:test_scripts_shared",
      "//testing/buildbot/filters:sync_integration_tests_filters",
      "//third_party/angle:includes",
    ]

    if (is_linux || is_chromeos || is_win) {
      data_deps += [ "//chrome:packed_resources" ]
    }

    if (is_mac) {
      # Dictionary sync is disabled on Mac.
      sources -= [
        "//chrome/browser/sync/test/integration/single_client_dictionary_sync_test.cc",
        "//chrome/browser/sync/test/integration/two_client_dictionary_sync_test.cc",
      ]

      data_deps += [
        "//chrome",
        "//chrome:chrome_framework",
      ]
    }
    if (is_win) {
      deps += [
        "//chrome:other_version",
        "//third_party/wtl",
        "//ui/resources",
      ]
    }
    if (is_chromeos_ash) {
      sources += [
        "//chrome/browser/sync/test/integration/single_client_app_list_sync_test.cc",
        "//chrome/browser/sync/test/integration/single_client_arc_package_sync_test.cc",
        "//chrome/browser/sync/test/integration/single_client_cookies_sync_test.cc",
        "//chrome/browser/sync/test/integration/single_client_os_preferences_sync_test.cc",
        "//chrome/browser/sync/test/integration/single_client_printers_sync_test.cc",
        "//chrome/browser/sync/test/integration/single_client_wifi_configuration_sync_test.cc",
        "//chrome/browser/sync/test/integration/single_client_workspace_desk_sync_test.cc",
        "//chrome/browser/sync/test/integration/two_client_app_list_sync_test.cc",
        "//chrome/browser/sync/test/integration/two_client_arc_package_sync_test.cc",
        "//chrome/browser/sync/test/integration/two_client_os_preferences_sync_test.cc",
        "//chrome/browser/sync/test/integration/two_client_printers_sync_test.cc",
        "//chrome/browser/sync/test/integration/two_client_workspace_desk_sync_test.cc",
      ]
      deps += [
        "//chrome/browser/ash/app_list",
        "//chrome/browser/ash/app_list/arc",
        "//chrome/browser/ash/app_list/internal_app",
        "//chrome/browser/ash/app_list/test:test_support",
        "//chrome/browser/ash/crosapi",
        "//chrome/browser/ash/crosapi:browser_util",
        "//chrome/browser/ash/floating_sso",
        "//chrome/browser/ash/floating_sso:test_support",
        "//chrome/browser/ash/printing",
        "//chrome/browser/ash/sync",
        "//chrome/browser/ash/system_web_apps/test_support",
        "//chromeos/ash/components/browser_context_helper",
        "//chromeos/ash/components/dbus/shill",
        "//chromeos/ash/components/standalone_browser",
        "//chromeos/ash/components/standalone_browser:test_support",
        "//chromeos/ash/components/sync_wifi",
        "//chromeos/ash/components/sync_wifi:test_support",
        "//chromeos/printing",
        "//chromeos/services/network_config/public/cpp",
        "//components/desks_storage",
      ]
    }

    if (toolkit_views) {
      deps += [ "//ui/views" ]
    }
    if (enable_printing) {
      deps += [ "//printing" ]
    }
  }

  test("sync_performance_tests") {
    sources = [
      "../browser/sync/test/integration/performance/autofill_sync_perf_test.cc",
      "../browser/sync/test/integration/performance/bookmarks_sync_perf_test.cc",
      "../browser/sync/test/integration/performance/dictionary_sync_perf_test.cc",
      "../browser/sync/test/integration/performance/extensions_sync_perf_test.cc",
      "../browser/sync/test/integration/performance/passwords_sync_perf_test.cc",
      "../browser/sync/test/integration/performance/sessions_sync_perf_test.cc",
      "../browser/sync/test/integration/performance/sync_timing_helper.cc",
      "../browser/sync/test/integration/performance/sync_timing_helper.h",
      "base/browser_perf_tests_main.cc",
    ]

    defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]

    deps = [
      ":chrome_test_launcher",
      ":sync_integration_test_support",
      ":test_support",
      ":test_support_ui",
      "//chrome/app:chrome_dll_resources",
      "//chrome/app:command_ids",
      "//chrome/browser/ui",
      "//components/bookmarks/browser",
      "//components/password_manager/core/browser",
      "//components/spellcheck/common",
      "//components/sync",
      "//testing/gmock",
      "//testing/gtest",
      "//testing/perf",
    ]

    data_deps = [ "//chrome:packed_resources" ]

    if (is_mac) {
      # Dictionary sync is disabled on Mac.
      sources -= [ "../browser/sync/test/integration/performance/dictionary_sync_perf_test.cc" ]

      # The sync_performance_tests do not run on mac without this flag.
      # Search for comments about "xcode_settings" elsewhere in this file.
      ldflags = [ "-Wl,-ObjC" ]
    }
    if (is_win) {
      deps += [
        "//chrome:other_version",
        "//chrome/installer/util:strings",
        "//third_party/wtl",
        "//ui/resources",
      ]
    }

    if (toolkit_views) {
      deps += [ "//ui/views" ]
    }

    # This target should not require the Chrome executable to run
    # except it wants to build lacros as a secondary toolchain.
    if (!(is_chromeos_ash && also_build_lacros_chrome)) {
      assert_no_deps = [
        "//chrome",
        "//chrome/test:test_lacros_chrome",
      ]
    }
  }

  # Executable to measure time to load libraries.
  test("load_library_perf_tests") {
    sources = [ "../browser/load_library_perf_test.cc" ]

    # This test deliberately does not depend in chrome's test support targets.
    # This is a small test and Chrome's test support targets bring in the
    # world, causing link time to explode. Please don't add more dependencies
    # here without understanding how it affects link time (and factor them
    # differently if possible).
    deps = [
      "//base",
      "//base/test:test_support_perf",
      "//media:media_buildflags",
      "//media/cdm:clear_key_cdm_common",
      "//testing/gtest",
      "//testing/perf",
      "//third_party/widevine/cdm:buildflags",
      "//third_party/widevine/cdm:headers",
    ]

    data_deps = [ "//testing:run_perf_test" ]

    if (enable_library_cdms) {
      deps += [ "//media/cdm:cdm_paths" ]
      data_deps += [
        "//media/cdm/library_cdm/clear_key_cdm",
        "//third_party/widevine/cdm",
      ]
    }

    # This target should not require the Chrome executable to run.
    assert_no_deps = [ "//chrome" ]
  }

  # Tests autofill on captured websites
  test("captured_sites_interactive_tests") {
    use_xvfb = use_xvfb_in_this_config

    sources = [
      "../browser/password_manager/password_manager_captured_sites_interactive_uitest.cc",
      "../browser/password_manager/password_manager_test_base.cc",
      "../browser/password_manager/password_manager_test_base.h",
      "../browser/password_manager/passwords_navigation_observer.cc",
      "../browser/password_manager/passwords_navigation_observer.h",
      "../browser/ui/views/translate/translate_bubble_test_utils_views.cc",
      "base/interactive_ui_tests_main.cc",
    ]

    configs += [ "//build/config:precompiled_headers" ]

    data = [
      "//chrome/test/data/autofill/captured_sites/",
      "//chrome/test/data/password/captured_sites/",
      "//chrome/test/data/web_page_replay_go_helper_scripts/automation_helper.js",
      "//components/test/data/autofill/web_page_replay_support_files/",
      "//third_party/catapult/telemetry/telemetry/bin/",
      "//third_party/catapult/web_page_replay_go/deterministic.js",
    ]

    if (is_linux || is_chromeos || is_win) {
      data_deps = [ "//chrome:packed_resources" ]
    }

    defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]

    ldflags = []

    deps = [
      ":chrome_test_launcher",
      ":test_support",
      ":test_support_ui",
      "//chrome:packed_resources",
      "//chrome:resources",
      "//chrome:strings",
      "//chrome/browser",
      "//chrome/browser/autofill",
      "//chrome/browser/autofill:captured_sites_interactive_tests",
      "//chrome/browser/autofill:test_support_ui",
      "//chrome/browser/devtools",
      "//chrome/browser/sync",
      "//chrome/renderer",
      "//components/javascript_dialogs",
      "//components/resources",
      "//components/sync",
      "//components/sync:test_support",
      "//content/test:test_support",
      "//crypto:test_support",
      "//google_apis:test_support",
      "//net",
      "//net:net_resources",
      "//net:test_support",
      "//skia",
      "//testing/gmock",
      "//testing/gtest",
      "//third_party/hunspell",
      "//third_party/icu",
      "//third_party/libpng",
      "//ui/base:test_support",
      "//ui/resources:ui_test_pak",
      "//ui/views",
      "//ui/web_dialogs:test_support",
    ]

    if (enable_extensions) {
      deps += [
        "//google_apis/common:test_support",
        "//google_apis/drive",
      ]
    }

    if (use_ozone) {
      deps += [ "//ui/ozone" ]
    }

    if (use_aura) {
      deps += [ "//ui/aura:test_support" ]
    }

    if (is_linux || is_chromeos) {
      deps += [ "//ui/platform_window/common" ]
    }

    if (is_mac) {
      deps += [ "//chrome/app:command_ids" ]
    }

    if (is_win) {
      deps += [
        "//chrome:other_version",
        "//chrome/installer/util:strings",
        "//third_party/webrtc_overrides:webrtc_component",
        "//third_party/wtl",
        "//ui/resources",
      ]
    }
  }

  group("telemetry_unittests") {
    testonly = true
    deps = [ "//tools/perf/chrome_telemetry_build:telemetry_chrome_test" ]

    data = [
      "//third_party/catapult/telemetry/telemetry/internal/bin/",
      "//tools/perf/run_telemetry_tests",
      "//testing/scripts/run_telemetry_as_googletest.py",
    ]

    data_deps = [
      # For isolate contract.
      "//testing:test_scripts_shared",
    ]
  }

  group("telemetry_gpu_unittests_run") {
    testonly = true
    deps = [ ":telemetry_gpu_unittests" ]
  }

  group("telemetry_gpu_unittests") {
    testonly = true
    deps = [ "//tools/perf/chrome_telemetry_build:telemetry_chrome_test_without_chrome" ]
    data = [
      # For GpuProcess.video
      "//content/test/data/media/bear.ogv",

      # For webgl_conformance_expectations_unittest
      "//third_party/webgl/src/sdk/tests/",

      # For resolve the imports in content/test/gpu/run_gpu_test.py
      "//tools/perf/core/",
      "//tools/perf/chrome_telemetry_build/",

      # From telemetry_gpu_unittests.isolate
      "//third_party/pylint/",
      "//third_party/logilab/",
      "//testing/scripts/run_telemetry_as_googletest.py",

      # For Skia Gold code, which has some GPU-specific unittests.
      "//build/skia_gold_common/",
    ]

    data_deps = [
      "//content/test:telemetry_gpu_unittest_data",
      "//content/test:webgpu_cts_scripts",
      "//testing:test_scripts_shared",
    ]
  }
}

if (is_win) {
  fuzzer_test("safe_browsing_binary_feature_extractor_fuzzer") {
    sources = [ "../common/safe_browsing/binary_feature_extractor_fuzzer.cc" ]
    deps = [
      "//base",
      "//chrome/common/safe_browsing:binary_feature_extractor",
      "//components/safe_browsing/core/common/proto:csd_proto",
      "//crypto",
    ]
    libs = [ "wintrust.lib" ]

    # Directory contains useful and non-useful files. Don't worry about
    # non-useful since they are eliminated during pruning.
    seed_corpus = "data/safe_browsing/download_protection/"
  }
}

if (is_win) {
  action("generate_allowed_imports") {
    testonly = true
    script = "delayload/generate_allowed_imports.py"
    sources = [ "delayload/supported_imports_10.0.10240.txt" ]
    outputs = [ "$target_gen_dir/chrome/test/delayload/supported_imports.inc" ]
    args = [
      "--exports-file",
      rebase_path("delayload/supported_imports_10.0.10240.txt", root_build_dir),
      "--out-file",
      rebase_path("$target_gen_dir/chrome/test/delayload/supported_imports.inc",
                  root_build_dir),
    ]
  }

  test("delayloads_unittests") {
    output_name = "delayloads_unittests"
    sources = [ "delayload/delayloads_unittest.cc" ]

    include_dirs = [ "$target_gen_dir" ]
    deps = [
      ":generate_allowed_imports",
      "//base",
      "//base/test:test_support",
      "//chrome",
      "//chrome/install_static:install_static_util",
      "//chrome/install_static/test:test_support",
      "//mojo:buildflags",
      "//testing/gtest",
    ]

    # It's not easily possible to have //chrome in data_deps without changing
    # the //chrome target to bundle up both initial/chrome.exe and chrome.exe.
    # As a workaround, explicitly include a data dep on just chrome.exe, and
    # add //chrome to deps above to make sure it's been built.
    data = [ "$root_out_dir/chrome.exe" ]

    # Don't want the test-specific dependencies to affect load tests.
    # In particular, a few system DLLs cause user32 to be loaded, which is bad.
    # Add delayloads to ensure loader validations occur properly.
    configs += [
      "//build/config/win:delayloads",
      "//build/config/win:delayloads_not_for_child_dll",
    ]
  }
}

# This is split out here instead of being part of //chrome/test:browser_tests
# because many of the Windows tests have specific hardware requirements, and
# it's cleaner to just have a separate target we can compile only on supported
# configurations instead of trying to conditionally skip tests.
if (!is_android) {
  group("xr_browser_tests") {
    testonly = true
    data_deps = [
      ":xr_browser_tests_binary",
      ":xr_browser_tests_runner",
    ]

    if (is_win) {
      # The .exe is necessary even though the target isn't an actual executable
      # since mb.py automatically appends .exe when looking for runtime deps
      # on Windows.
      write_runtime_deps = "$root_out_dir/$target_name.exe.runtime_deps"
    } else {
      write_runtime_deps = "$root_out_dir/$target_name.runtime_deps"
    }
  }

  test("xr_browser_tests_binary") {
    testonly = true
    deps = [ ":xr_browser_tests_common" ]

    # Most tests require VR to be enabled.
    if (enable_vr) {
      deps += [ "//chrome/browser/vr:xr_browser_tests_vr_required" ]
    }
  }

  # This should only contain files that are useful if enable_vr = false. For
  # tests/infrastructure that require enable_vr = true, see
  # //chrome/browser/vr:xr_browser_tests_vr_required.
  source_set("xr_browser_tests_common") {
    testonly = true
    defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]

    # Infrastructure
    sources = [
      "//chrome/browser/vr/test/conditional_skipping.cc",
      "//chrome/browser/vr/test/conditional_skipping.h",
      "//chrome/browser/vr/test/multi_class_browser_test.h",
      "//chrome/browser/vr/test/webxr_browser_test.cc",
      "//chrome/browser/vr/test/webxr_browser_test.h",
      "//chrome/browser/vr/test/webxr_vr_browser_test.cc",
      "//chrome/browser/vr/test/webxr_vr_browser_test.h",
      "//chrome/browser/vr/test/xr_browser_test.cc",
      "//chrome/browser/vr/test/xr_browser_test.h",
    ]

    # Tests
    sources += [
      "//chrome/browser/vr/webxr_vr_runtimeless_browser_test.cc",
      "//chrome/browser/vr/webxr_vr_spatial_tracking_test.cc",
    ]

    deps = [
      "//base",
      "//chrome/test:browser_tests_runner",
      "//sandbox/policy",
    ]

    public_deps = [
      "//chrome/test:test_support",
      "//chrome/test:test_support_ui",
    ]

    data = [
      "//chrome/test/data/xr/e2e_test_files/",
      "//third_party/blink/web_tests/resources/testharness.js",
    ]

    if (is_win && enable_vr) {
      deps += [
        "//device/vr",
        "//device/vr:directx_helpers",
      ]
    }

    if (!is_mac) {
      data_deps = [ "//chrome:packed_resources" ]
    }
  }

  # TODO(crbug.com/40564748): Migrate this to a generic wrapper script
  # once the functionality is available on all platforms.
  copy("xr_browser_tests_runner") {
    testonly = true
    sources = [ "//chrome/browser/vr/test/run_xr_browser_tests.py" ]
    outputs = [ "$root_out_dir/run_xr_browser_tests.py" ]
  }
}

# This target is defined for Lacros testing.
# See //chrome/test/base/chromeos/README.md for more information.
if (is_chromeos) {
  assert(use_aura)

  if (is_chromeos_ash) {
    _target_name = "test_ash_chrome"
  } else {
    _target_name = "test_lacros_chrome"
  }
  executable(_target_name) {
    output_name = _target_name
    testonly = true

    sources = [
      "//chrome/app/chrome_exe_main_aura.cc",
      "//chrome/app/chrome_main_delegate.cc",
      "//chrome/app/chrome_main_delegate.h",
      "//chrome/app/startup_timestamps.h",
      "base/chromeos/test_chrome_base.cc",
      "base/chromeos/test_chrome_base.h",
      "base/chromeos/test_chrome_main.cc",
    ]

    deps = [
      "//base/test:test_support",
      "//chrome/common:version_header",
      "//testing/gmock",

      # On Linux, link the dependencies (libraries) that make up actual
      # Chromium functionality directly into the executable.
      "//chrome:dependencies",

      # For the sampling profiler.
      # The way it's currently implemented requires us to keep it, but from a
      # technical perspective it shouldn't be necessary
      "//chrome/common/profiler",
      "//content/public/app",

      # For headless mode.
      "//headless:headless_shell_lib",
    ]

    data = [ "$root_out_dir/resources.pak" ]
    data_deps = [
      # The step's output are needed at runtime, so we also need a data_dep.
      "//chrome:packed_resources",
    ]

    if (is_chromeos_ash) {
      sources += [
        "base/chromeos/test_ash_chrome_browser_main_extra_parts.cc",
        "base/chromeos/test_ash_chrome_browser_main_extra_parts.h",
      ]
      deps += [
        "//ash:test_support",
        "//chrome/browser:main_extra_parts",
        "//chrome/browser/ash/boot_times_recorder",
        "//chrome/browser/ash/crosapi",
        "//chrome/browser/ash/crosapi:test_support",
        "//chrome/browser/ash/locale",
        "//chrome/browser/ash/login/signin",
        "//chrome/browser/ash/schedqos",
        "//chromeos/services/machine_learning/public/cpp:stub",
        "//components/exo/wayland:test_controller",
        "//components/exo/wayland:ui_controls_protocol",
        "//ui/base:test_support",
      ]

      # crbug.com/1223310 There is an issue that for the second toolchain the built
      # nacl_irt_x86_64.nexe is not in subfolder ash_clang_x64.
      # This action will copy the related files to the correct folder.
      if (enable_nacl && current_cpu == "x64" && also_build_ash_chrome) {
        copy("copy_files_to_ash_clang_x64") {
          sources = [
            "${root_build_dir}/nacl_irt_x86_64.nexe",
            "${root_build_dir}/nacl_irt_x86_64.nexe.debug",
          ]
          outputs = [ "${root_build_dir}/ash_clang_x64/{{source_file_part}}" ]
          deps = [ "//ppapi/native_client:irt" ]
        }
        deps += [ ":copy_files_to_ash_clang_x64" ]
      }
    }

    if (is_chromeos_lacros) {
      sources += [
        "//chrome/test/chromeos/standalone_browser_test_controller.cc",
        "//chrome/test/chromeos/standalone_browser_test_controller.h",
        "base/chromeos/test_lacros_chrome_browser_main_extra_parts.cc",
        "base/chromeos/test_lacros_chrome_browser_main_extra_parts.h",
      ]
      deps += [
        "//chrome/browser:main_extra_parts",

        # For StandaloneBrowserTestController.
        "//chrome/browser/apps/app_service",
        "//chrome/browser/extensions:test_support",
        "//chrome/browser/ui",
        "//chrome/browser/web_applications",
        "//chromeos/lacros:lacros_paths",
        "//components/webapps/browser",
        "//components/webapps/common",
        "//content/test:test_support",
        "//extensions/browser",
      ]
    }

    if (use_ozone) {
      deps += [ "//ui/ozone" ]
    }
  }
}

# This target is for Lacros version skew testing.
if (is_chromeos_ash) {
  copy("test_ash_chrome_cipd_yaml") {
    testonly = true
    deps = [
      ":test_ash_chrome",
      "//chrome",
    ]
    sources = [ "//infra/archive_config/test-ash-chrome.yaml" ]
    outputs = [ "$root_out_dir/test_ash_chrome.yaml" ]
  }
}

if (is_chromeos_ash) {
  # This target is for Ash-side crosapi testing.
  test("ash_crosapi_tests") {
    use_xvfb = use_xvfb_in_this_config
    defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]

    deps = [ "//chrome/browser/ash/crosapi/test" ]
    data_deps = [ ":test_ash_chrome" ]
  }
}

if (is_linux || is_mac || is_win) {
  script_test("variations_smoke_tests") {
    if (is_linux) {
      script = "//testing/xvfb.py"
    } else {
      script = "//testing/test_env.py"
    }

    args = [ "@WrappedPath(" +
             rebase_path("//testing/scripts/run_variations_smoke_tests.py",
                         root_build_dir) + ")" ]

    data_deps = [
      "//chrome",
      "//chrome/test/chromedriver:chromedriver_server",
      "//testing:test_scripts_shared",
      "//ui/base:goldctl",
    ]

    data = [
      "//.vpython3",
      "//build/skia_gold_common",
      "//testing/scripts/skia_gold_infra/",
      "//testing/scripts/run_variations_smoke_tests.py",
      "//testing/scripts/variations_seed_access_helper.py",
      "//testing/scripts/variations_smoke_test_data/",
      "//testing/scripts/variations_smoke_test_data/http_server/",
      "//third_party/webdriver/pylib/",
    ]
  }
}

if (!is_android) {
  static_library("print_preview_test_support") {
    testonly = true

    sources = [
      "../browser/printing/test_print_preview_dialog_cloned_observer.cc",
      "../browser/printing/test_print_preview_dialog_cloned_observer.h",
      "../browser/printing/test_print_view_manager_for_request_preview.cc",
      "../browser/printing/test_print_view_manager_for_request_preview.h",
    ]

    deps = [
      "//base",
      "//chrome/browser",
      "//components/printing/common:mojo_interfaces",
      "//content/public/browser",
    ]
  }
}