blob: f6ad16d14ddd401bb21f327c4a92a2c5b4a5e3b2 [file] [log] [blame]
Avi Drissman24976592022-09-12 15:24:311# Copyright 2013 The Chromium Authors
[email protected]f0e7ff882013-12-26 21:23:092# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5# This is the root build file for GN. GN will start processing by loading this
6# file, and recursively load all dependencies until all dependencies are either
7# resolved or known not to exist (which will cause the build to fail). So if
8# you add a new build file, there must be some path of dependencies from this
9# file to your new one or GN won't know about it.
10
Yuke Liaoa2d10312020-09-15 22:19:2911import("//build/config/chromeos/ui_mode.gni")
dprankead249c72016-06-11 18:01:2212import("//build/config/compiler/compiler.gni")
Dirk Prankef452bb2a2020-10-09 22:11:5513import("//build/config/dcheck_always_on.gni")
rockot2f1326e2015-02-23 23:53:5114import("//build/config/features.gni")
Collina1e27a42022-01-26 20:12:0315import("//build/config/rust.gni")
aizatskyfc46a9f2015-10-09 21:20:0816import("//build/config/sanitizers/sanitizers.gni")
[email protected]378b4f02014-06-10 15:58:4517import("//build/config/ui.gni")
Andrew Grievefebea022020-08-07 17:17:5318import("//build/gn_logs.gni")
John Budorick7c8273b2019-04-25 15:27:4719import("//build/util/generate_wrapper.gni")
Tommy Steimele417e712020-01-30 14:07:5520import("//chrome/browser/buildflags.gni")
Dirk Prankeccc0c362017-09-28 22:15:1121import("//components/nacl/features.gni")
Scott Violetc8240b02018-03-08 22:03:5922import("//device/vr/buildflags/buildflags.gni")
23import("//extensions/buildflags/buildflags.gni")
Sam McNally11dc0142018-11-23 01:11:0524import("//gpu/vulkan/features.gni")
Alexandre Courbot8ad2427d2017-08-25 14:04:5525import("//media/gpu/args.gni")
Sam McNally11dc0142018-11-23 01:11:0526import("//media/media_options.gni")
Lei Zhang242fc9a2021-05-18 23:48:4227import("//pdf/features.gni")
David Dorwin35ee05a72022-03-08 22:12:2128import("//ppapi/buildflags/buildflags.gni")
Lei Zhang8baa2942021-05-19 03:59:4829import("//printing/buildflags/buildflags.gni")
brettw2b112cd2016-10-12 19:35:3630import("//remoting/remoting_enable.gni")
Josip Sokcevic4d590cf2020-07-07 10:48:2331import("//third_party/closure_compiler/compile_js.gni")
thakis3f7d4fc2016-06-10 18:47:5032import("//tools/ipc_fuzzer/ipc_fuzzer.gni")
Peter Beverloo69948322017-07-28 19:01:5733import("//ui/base/ui_features.gni")
Elly Fong-Jonesb03817a2019-11-14 18:10:1234import("//ui/gl/features.gni")
machenbachd65ec5c2016-07-22 09:05:2335import("//v8/gni/v8.gni")
dprankee2ef3822015-02-24 21:42:1836
cjhopmanca675d3e2014-10-24 03:50:4537if (is_android) {
38 import("//build/config/android/config.gni")
39}
[email protected]378b4f02014-06-10 15:58:4540
Greg Thompsonada4b212022-09-12 13:31:4941if (is_fuchsia) {
42 import("//build/config/fuchsia/generate_runner_scripts.gni")
43 import("//third_party/fuchsia-sdk/sdk/build/component.gni")
44 import("//third_party/fuchsia-sdk/sdk/build/package.gni")
45}
46
Andrey Kosyakov0e234d902021-03-30 19:00:2747if (is_linux) {
48 import("build/config/linux/gtk/gtk.gni")
49}
50
Rohit Rao123b39e2021-09-17 19:52:3851if (!is_ios) {
52 import("//v8/gni/snapshot_toolchain.gni")
53}
54
brettwb84b29472014-10-22 22:58:4555declare_args() {
56 # A list of extra dependencies to add to the root target. This allows a
57 # checkout to add additional targets without explicitly changing any checked-
58 # in files.
59 root_extra_deps = []
60}
61
brucedawsonc8d6d652016-09-02 19:43:1862if (is_official_build) {
63 # An official (maximally optimized!) component (optimized for build times)
64 # build doesn't make sense and usually doesn't work.
65 assert(!is_component_build)
66}
67
Wez09fb3a932017-12-20 21:33:4668# This file defines the following two main targets:
dpranked62d8512015-03-02 03:06:0369#
Wez09fb3a932017-12-20 21:33:4670# "gn_all" is used to create explicit dependencies from the root BUILD.gn to
71# each top-level component that we wish to include when building everything via
72# "all". This is required since the set of targets built by "all" is determined
73# automatically based on reachability from the root BUILD.gn (for details, see
74# crbug.com/503241). Builders should typically use "all", or list targets
75# explicitly, rather than relying on "gn_all".
dprankeddc174902015-04-29 01:38:3576#
dprankeb6128d02015-05-01 16:40:3077# "gn_visibility": targets that are normally not visible to top-level targets,
dprankeef9c5e582015-11-15 23:22:0878# but are built anyway by "all". Since we don't want any such targets, we have
79# this placeholder to make sure hidden targets that aren't otherwise depended
80# on yet are accounted for.
dprankeff30e3d2015-02-24 06:52:3981
dprankee2ef3822015-02-24 21:42:1882group("gn_all") {
83 testonly = true
84
85 deps = [
dprankeb6128d02015-05-01 16:40:3086 ":gn_visibility",
Robert Liao38b1b4f2017-09-06 20:32:2487 "//base:base_perftests",
dprankee2ef3822015-02-24 21:42:1888 "//base:base_unittests",
Austin Sullivan33da70a2020-10-07 15:39:4189 "//codelabs",
Wez04eb259f2019-09-16 19:41:5990 "//components:components_unittests",
Vlad Tsyrklevich207f3272019-08-02 16:18:2691 "//components/gwp_asan:gwp_asan_unittests",
Stephanie Kimc94072c2022-03-22 22:31:4192 "//infra/orchestrator:orchestrator_all",
sheroukce1c7d72015-08-24 15:21:5993 "//net:net_unittests",
Guocheng Weid9c875f2022-06-28 18:56:4094 "//sandbox:sandbox_unittests",
Wez3c761e62019-04-15 16:42:5395 "//services:services_unittests",
96 "//services/service_manager/public/cpp",
Sergey Ulanovdd606ed2017-07-13 00:44:2497 "//skia:skia_unittests",
brettwa874dcc2015-08-28 23:59:1898 "//sql:sql_unittests",
Yuly Novikov7f2d0b02021-01-27 20:57:2799 "//third_party/angle/src/tests:angle_end2end_tests",
100 "//third_party/angle/src/tests:angle_unittests",
101 "//third_party/angle/src/tests:angle_white_box_tests",
Wez3c761e62019-04-15 16:42:53102 "//third_party/flatbuffers:flatbuffers_unittests",
Ben Kellyad8343ba2020-10-28 18:48:53103 "//third_party/liburlpattern:liburlpattern_unittests",
Andrew Grievea7f1ee902018-05-18 16:17:22104 "//tools/binary_size:binary_size_trybot_py",
ochangcc11d0e2016-04-26 19:58:26105 "//tools/ipc_fuzzer:ipc_fuzzer_all",
Wez3c761e62019-04-15 16:42:53106 "//tools/metrics:metrics_metadata",
Sergey Ulanovfbd2fea2017-07-14 01:01:38107 "//ui/base:ui_base_unittests",
Robert Liao2d9b6432020-03-04 19:56:43108 "//ui/color:color_unittests",
Wez3c761e62019-04-15 16:42:53109 "//ui/gfx:gfx_unittests",
sherouk4fb74d42015-08-24 15:58:41110 "//url:url_unittests",
dprankee2ef3822015-02-24 21:42:18111 ]
dpranke2a294622015-08-07 05:23:01112
Mirko Bonadei3de25fd2020-06-25 22:19:14113 if (!is_component_build) {
Brian Sheedyc4740bf42020-07-08 02:28:33114 deps += [ "//third_party/abseil-cpp:absl_tests" ]
Mirko Bonadei3de25fd2020-06-25 22:19:14115 }
116
Ryan Keanea67d8022022-06-18 00:20:32117 if (enable_js_type_check) {
118 deps += [ ":webui_closure_compile" ]
119 }
120
121 if (!is_android && !is_castos) {
sdefresne21832bf92016-03-30 22:01:02122 deps += [
123 "//crypto:crypto_unittests",
124 "//google_apis/gcm:gcm_unit_tests",
125 ]
126 }
127
Ryan Keanea67d8022022-06-18 00:20:32128 if (!is_ios && !is_android && !is_castos) {
sherouk53f0f1a2015-08-03 15:59:35129 deps += [
sherouk53f0f1a2015-08-03 15:59:35130 "//chrome",
Robert Liaof3e619e2020-03-02 21:17:55131 "//chrome/browser/ui/color:dump_colors",
sherouk53f0f1a2015-08-03 15:59:35132 "//chrome/test:browser_tests",
133 "//chrome/test:interactive_ui_tests",
134 "//chrome/test:sync_integration_tests",
Charlie Harrison65c798902018-04-30 17:44:43135 "//components/subresource_filter/tools:subresource_filter_tools",
Samuel Huang577ef6c2018-03-13 18:19:34136 "//components/zucchini:zucchini",
137 "//components/zucchini:zucchini_unittests",
dprankedbdd9d82015-08-12 21:18:18138 "//gpu/gles2_conform_support:gles2_conform_test",
stevenjb604316362016-05-06 22:10:26139 "//gpu/khronos_glcts_support:khronos_glcts_test",
sherouk53f0f1a2015-08-03 15:59:35140 "//net:hpack_example_generator",
Jamie Madill178f84e2020-12-18 00:47:58141 "//third_party/vulkan-deps/spirv-tools/src:SPIRV-Tools",
Nan Lincaa89af2021-07-07 19:49:46142 "//tools/aggregation_service:aggregation_service_tool",
Andrew Paseltiner0bcbc692022-02-03 22:36:32143 "//tools/attribution_reporting:attribution_reporting_simulator",
pkotwicz558d5252015-10-19 21:09:55144 "//tools/perf/clear_system_cache",
rbpotterd8ca34c2019-07-25 18:48:05145 "//tools/polymer:polymer_tools_python_unittests",
Alex Turner21735e22020-11-04 16:51:26146 "//tools/privacy_budget:privacy_budget_tools",
Ryan Keanea67d8022022-06-18 00:20:32147 "//ui/accessibility:accessibility_perftests",
148 "//ui/accessibility:accessibility_unittests",
149 "//ui/accessibility/extensions:extension_tests",
150 "//ui/accessibility/extensions:extensions",
pkotwicz558d5252015-10-19 21:09:55151 ]
152 }
153
Daniel Nicoaracf98a1bf2022-08-09 19:51:44154 if (!is_castos) {
155 deps += [
156 "//chrome/installer",
157 "//chrome/updater",
158 ]
159 }
160
K. Moon46aabb282022-07-22 22:06:49161 if (enable_ppapi) {
David Dorwin35ee05a72022-03-08 22:12:21162 deps += [
163 "//ppapi:ppapi_unittests",
164 "//ppapi/examples",
165 ]
166 }
167
Yuta Hijikata05f38002020-12-17 00:49:24168 if (is_chromeos_lacros) {
Joel Hockey61347d52021-01-06 01:18:33169 deps += [
170 "//chrome/test:lacros_chrome_browsertests",
171 "//chrome/test:lacros_chrome_unittests",
172 ]
Yuke Liaoa2d10312020-09-15 22:19:29173 }
174
Daniel Nicoaracf98a1bf2022-08-09 19:51:44175 if (!is_ios && !is_castos) {
176 deps += [ "//chrome/test:unit_tests" ]
177 }
178
Sergey Ulanovfbd2fea2017-07-14 01:01:38179 if (!is_ios) {
180 deps += [
David Dorwin776712222022-04-13 23:01:54181 ":chromedriver",
Wez57c96392017-12-05 22:19:05182 "//cc:cc_unittests",
Chong Gu83a1ddf2021-10-14 22:04:52183 "//components:components_browsertests",
Wez57c96392017-12-05 22:19:05184 "//components/policy:policy_templates",
Mustafa Emre Acer52a809002019-06-27 20:41:28185 "//components/url_formatter/tools:format_url",
Sergey Ulanov19240f762019-05-10 22:26:20186 "//components/viz:viz_perftests",
187 "//components/viz:viz_unittests",
Wez57c96392017-12-05 22:19:05188 "//content/shell:content_shell",
189 "//content/test:content_browsertests",
Wez57c96392017-12-05 22:19:05190 "//content/test:content_unittests",
Chong Gu83a1ddf2021-10-14 22:04:52191 "//device:device_unittests",
Nathan Zabriskie92461a02020-02-06 20:44:27192 "//gpu:gpu_benchmark",
Wez57c96392017-12-05 22:19:05193 "//gpu:gpu_unittests",
Wez57c96392017-12-05 22:19:05194 "//ipc:ipc_tests",
Sergey Ulanov135ba082017-07-18 19:39:22195 "//media:media_unittests",
Chong Gu83a1ddf2021-10-14 22:04:52196 "//media/capture:capture_unittests",
Wez57c96392017-12-05 22:19:05197 "//media/midi:midi_unittests",
198 "//media/mojo:media_mojo_unittests",
Sergey Ulanovfbd2fea2017-07-14 01:01:38199 "//mojo",
Oksana Zhuravlova1792d19f2018-02-22 19:13:31200 "//mojo:mojo_unittests",
Wez57c96392017-12-05 22:19:05201 "//net:net_perftests",
Sergey Ulanov6ab219c2019-05-11 00:42:20202 "//storage:storage_unittests",
Sergey Ulanov6ab219c2019-05-11 00:42:20203 "//third_party/blink/common:blink_common_unittests",
Kent Tamuraef54e402019-02-14 07:18:36204 "//third_party/blink/renderer/controller:blink_unittests",
Sergey Ulanov6ab219c2019-05-11 00:42:20205 "//third_party/blink/renderer/platform:blink_platform_unittests",
206 "//third_party/blink/renderer/platform/heap:blink_heap_unittests",
Blink Reformata30d4232018-04-07 15:31:06207 "//third_party/blink/renderer/platform/wtf:wtf_unittests",
Sergey Ulanov7c6ba7f52022-01-25 18:18:46208 "//third_party/libjingle_xmpp:libjingle_xmpp_unittests",
Sergey Ulanov6ab219c2019-05-11 00:42:20209 "//tools/imagediff",
210 "//ui/display:display_unittests",
211 "//ui/events:events_unittests",
Sergey Ulanovfbd2fea2017-07-14 01:01:38212 "//ui/gl:gl_unittests",
Sergey Ulanov6ab219c2019-05-11 00:42:20213 "//ui/latency:latency_unittests",
Peter Kasting8d5c4d62019-09-20 00:16:09214 "//ui/native_theme:native_theme_unittests",
Sergey Ulanov6ab219c2019-05-11 00:42:20215 "//ui/touch_selection:ui_touch_selection_unittests",
Wez57c96392017-12-05 22:19:05216 "//url/ipc:url_ipc_unittests",
Sergey Ulanov6ab219c2019-05-11 00:42:20217 "//v8:gn_all",
Sergey Ulanovfbd2fea2017-07-14 01:01:38218 ]
219 }
220
Amy Huang08b73f52022-08-25 18:33:30221 if (!is_ios && !is_android) {
222 deps += [
223 "//components/cronet:cronet_tests",
224 "//components/cronet:cronet_unittests",
225 "//components/viz/demo:viz_demo",
226 ]
Wez115d4312018-02-17 04:05:19227 }
228
David Dorwin9985426fc2022-03-30 00:06:04229 if (!is_ios) {
pkotwicz558d5252015-10-19 21:09:55230 deps += [
varkha5aa18a02017-05-31 22:39:50231 "//google_apis/gcm:mcs_probe",
miu45b848fe2015-11-26 01:23:29232 "//media/cast:cast_unittests",
nednguyenc42bf912016-01-27 01:39:28233 "//third_party/catapult/telemetry:bitmaptools($host_toolchain)",
sherouk53f0f1a2015-08-03 15:59:35234 ]
Brian Sheedyc512ec692021-09-17 23:52:23235 if (!is_android) {
Daniel Nicoaracf98a1bf2022-08-09 19:51:44236 if (!is_castos) {
237 deps += [ "//chrome/test:telemetry_perf_unittests" ]
238 }
Brian Sheedyc512ec692021-09-17 23:52:23239 } else {
Brian Sheedyf74819b2021-06-04 01:38:38240 import("//tools/perf/chrome_telemetry_build/android_browser_types.gni")
241 foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
242 deps += [ "//chrome/test:telemetry_perf_unittests${_target_suffix}" ]
243 }
244 }
David Dorwin9985426fc2022-03-30 00:06:04245 } else {
Rohit Rao45623282019-11-15 17:59:31246 deps += [
247 "//ios:all",
248 "//third_party/crashpad/crashpad:crashpad_tests",
249 ]
David Dorwin9985426fc2022-03-30 00:06:04250 }
251
Ryan Keanea67d8022022-06-18 00:20:32252 if (is_fuchsia) {
David Dorwin7adc701c2022-05-27 16:45:16253 # Add targets that only exist on Fuchsia.
Scott Graham4411204b2018-10-03 19:46:26254 deps += [
255 ":d8_fuchsia",
David Dorwinb33d924c2022-05-06 21:48:31256 "//build/fuchsia/cipd",
David Dorwin3b9ceec2022-06-16 04:34:18257 "//chrome/app:chrome_fuchsia",
David Dorwin7adc701c2022-05-27 16:45:16258 "//fuchsia_web:gn_all",
David Dorwin3114ea72022-05-11 19:47:19259 "//tools/fuchsia/size_tests:fuchsia_sizes",
David Dorwin7d40e7f2022-03-31 19:13:39260
David Dorwin7d40e7f2022-03-31 19:13:39261 # Ensure this target continues to build.
262 "//chromecast/bindings:bindings_manager_fuchsia",
Scott Graham4411204b2018-10-03 19:46:26263 ]
sherouk53f0f1a2015-08-03 15:59:35264 }
dprankee2ef3822015-02-24 21:42:18265
scottmg34fb7e52014-12-03 23:27:24266 deps += root_extra_deps
[email protected]fce5c3fe2014-04-10 21:13:05267
Lei Zhang8baa2942021-05-19 03:59:48268 if (enable_basic_printing) {
269 deps += [ "//printing:printing_unittests" ]
270 }
271
tfarina4aa9edc2015-10-26 22:14:02272 if (enable_extensions) {
thestig344fe3f2017-06-08 23:42:13273 deps += [
274 "//extensions:extensions_browsertests",
275 "//extensions:extensions_unittests",
Karandeep Bhatiaef35fb22020-11-25 21:29:14276 "//extensions/browser/api/declarative_net_request/filter_list_converter",
thestig344fe3f2017-06-08 23:42:13277 "//extensions/shell:app_shell_unittests",
278 ]
rockot2f1326e2015-02-23 23:53:51279 }
280
Lei Zhang242fc9a2021-05-18 23:48:42281 if (enable_pdf) {
Lei Zhang9d594912021-06-21 18:23:13282 deps += [
283 "//pdf/pdfium/fuzzers",
284 "//third_party/pdfium/samples:pdfium_test",
285 ]
Lei Zhang242fc9a2021-05-18 23:48:42286 }
287
garykac3eddb5b2015-04-17 23:16:38288 if (enable_remoting) {
289 deps += [ "//remoting:remoting_all" ]
dprankece5eb832015-04-01 20:21:05290 }
291
dprankee2ef3822015-02-24 21:42:18292 if (toolkit_views) {
ellyjones41c21fe2016-06-09 17:10:19293 deps += [
294 "//ui/views:views_unittests",
Allen Bauer486d8872020-04-17 03:07:11295 "//ui/views/examples:views_examples",
Allen Bauer0678d772020-05-11 22:25:17296 "//ui/views/examples:views_examples_unittests",
Allen Bauer486d8872020-04-17 03:07:11297 "//ui/views/examples:views_examples_with_content",
ellyjones41c21fe2016-06-09 17:10:19298 ]
James Robinson060f2e32014-09-10 22:31:37299 }
300
jamescook4c02a0b2016-12-02 23:14:42301 if (use_aura) {
302 deps += [
Robert Liaoee8a6672019-08-15 21:02:03303 "//ui/aura:aura_demo",
mswda0133e62016-02-16 20:50:02304 "//ui/aura:aura_unittests",
Robert Liao1d63dfe2022-09-10 00:28:23305 "//ui/webui/examples:webui_examples",
mswda0133e62016-02-16 20:50:02306 "//ui/wm:wm_unittests",
307 ]
dprankee2ef3822015-02-24 21:42:18308 }
309
310 if (use_ozone) {
kylechar5c9a1fb62016-10-21 13:17:25311 deps += [
312 "//ui/ozone",
Michael Spanga9cf1382020-09-26 07:10:57313 "//ui/ozone:unittests",
kylechar5c9a1fb62016-10-21 13:17:25314 ]
Greg Thompson4eb355a2022-09-14 00:16:29315 if (!is_fuchsia) {
316 deps += [ "//ui/ozone/demo" ]
317 }
[email protected]a306aaa2014-05-24 13:21:50318 }
319
Roger Tawaf761bb62018-10-09 20:19:27320 if (is_win) {
321 deps += [
322 "//chrome/credential_provider",
323 "//chrome/credential_provider/test:gcp_unittests",
324 ]
325 }
326
Nicolas Ouellet-Payeurfa454332021-09-15 15:23:24327 if (is_win || is_linux) {
328 deps += [ "//tools/traffic_annotation/auditor:traffic_annotation_auditor" ]
Nicolas Ouellet-payeur0d23b5cf2018-10-19 14:53:07329 }
330
thakisdc11faf52017-04-25 21:49:42331 if (is_mac) {
Sigurdur Asgeirsson650fe96d2021-09-30 17:00:38332 deps += [
333 "//chrome/installer/gcapi_mac:gcapi_example",
334 "//tools/mac/power:all",
335 ]
thakisdc11faf52017-04-25 21:49:42336 }
337
Adenilson Cavalcanti3d10c9b2020-06-03 09:32:10338 # Allow building md5sum tool for other OSes (android is added below).
339 # For Windows, see: crbug.com/1090428.
340 # TODO(cavalcantii): move it out of 'android' folder.
341 if (!is_win) {
342 deps += [ "//tools/android/md5sum" ]
343 }
344
[email protected]5a8d5162014-04-12 01:19:16345 if (is_android) {
[email protected]26046b52014-07-16 00:11:03346 deps += [
Abhijith Nair4d396022022-04-08 17:44:49347 "//android_webview/js_sandbox/javatests:webview_js_sandbox_test_app",
pkotwicze2dae8b2015-11-03 20:12:55348 "//base:base_junit_tests",
Eric Stevensonc3c269a32017-08-02 21:40:06349 "//base/android/jni_generator:jni_generator_tests",
dpranke244f973d62015-11-20 05:38:10350 "//base/android/linker:chromium_android_linker",
cjhopman3d85c6d2014-11-18 03:39:38351 "//build/android/gyp/test:hello_world",
agrievea350dbdb2017-07-05 15:27:17352 "//build/android/stacktrace:java_deobfuscate",
Sky Malice43955522020-01-07 19:55:56353 "//build/config/android/test/proto:test_build_protos",
Peter Kotwiczda2f11102020-10-09 05:29:50354 "//chrome/android/monochrome:monochrome_public_apk_checker",
Egor Paskofd5c84d62018-04-11 20:20:11355 "//chrome/android/webapk/shell_apk:maps_go_webapk",
pkotwicz2dd67962016-05-10 00:21:08356 "//chrome/android/webapk/shell_apk:webapk",
Peter Kotwiczf4f4cd62019-06-11 19:57:38357 "//chrome/android/webapk/shell_apk/prepare_upload_dir:prepare_webapk_shell_upload_dir",
danakjcb3fb4c02019-06-28 17:43:00358 "//chrome/test:android_browsertests",
Tao Bai59eb7dd2020-04-17 04:16:14359 "//components:components_junit_tests",
pkotwicze2dae8b2015-11-03 20:12:55360 "//content/public/android:content_junit_tests",
pkotwicz8adff4e2015-12-17 21:55:45361 "//content/shell/android:content_shell_apk",
mcasaseddfbeb2017-05-10 04:47:49362 "//device:device_junit_tests",
markdittmer6e70beb82016-05-02 05:40:47363 "//media/gpu:video_decode_accelerator_unittest",
pkotwicze2dae8b2015-11-03 20:12:55364 "//net/android:net_junit_tests",
Reilly Grant20121a112020-07-28 02:10:07365 "//services:services_junit_tests",
jbudorick5ef42902016-04-07 04:17:11366 "//testing/android/junit:junit_unit_tests",
Peter Wen0878d76412022-07-01 13:35:17367 "//third_party/android_build_tools/lint:custom_lint_java",
John Budorick3fa43152017-06-12 19:13:20368 "//third_party/catapult/devil",
Peter Wen5ef0e3bb2021-01-15 19:59:08369 "//third_party/r8:custom_d8_java",
pkotwicze38594d2015-09-25 00:05:10370 "//tools/android:android_tools",
pkotwicz6b5571b2015-12-08 21:54:49371 "//tools/android:memconsumer",
mikecasef5e98302016-03-11 18:38:34372 "//tools/android:push_apps_to_background",
jbudorickdfc01f62016-06-01 15:42:12373 "//tools/android/audio_focus_grabber:audio_focus_grabber_apk",
374 "//tools/android/customtabs_benchmark:customtabs_benchmark_apk",
dgn28050da2015-10-19 10:16:43375 "//tools/android/kerberos/SpnegoAuthenticator:spnego_authenticator_apk",
newt9e226032016-01-26 01:30:15376 "//ui/android:ui_junit_tests",
dprankee2ef3822015-02-24 21:42:18377 ]
378 deps -= [
rockot9c67e5f2015-03-12 20:01:21379 "//net:net_perftests",
dprankee2ef3822015-02-24 21:42:18380 "//url:url_unittests",
[email protected]26046b52014-07-16 00:11:03381 ]
382
pkotwicz92e2e2312015-12-15 22:29:46383 if (!is_component_build) {
384 deps += [
John Budorickbc3571aa2019-04-25 02:20:06385 "//components/cronet/android:cronet_package_android",
jbudorickdfc01f62016-06-01 15:42:12386 "//components/cronet/android:cronet_perf_test_apk",
pkotwicz92e2e2312015-12-15 22:29:46387 "//components/cronet/android:cronet_sample_apk",
388 "//components/cronet/android:cronet_sample_test_apk",
pkotwicz92e2e2312015-12-15 22:29:46389 "//components/cronet/android:cronet_test_instrumentation_apk",
Wez3042f15a2018-02-24 01:05:49390 "//components/cronet/android:cronet_unittests_android",
pkotwicz92e2e2312015-12-15 22:29:46391 ]
392 }
393
Ryan Keanea67d8022022-06-18 00:20:32394 if (!is_cast_android) {
pkotwicz061c5a42015-09-30 02:16:54395 deps += [
Robbie McElrath0b2663c2019-12-05 20:49:06396 "//android_webview:empty_group",
agrieveb08e2f5b2015-12-29 01:17:30397 "//android_webview/test",
mikecasecb1b5062016-07-01 20:53:44398 "//android_webview/tools/automated_ui_tests:webview_ui_test_app",
mikecase49971fc2016-03-21 21:18:05399 "//android_webview/tools/system_webview_shell",
pkotwicze2dae8b2015-11-03 20:12:55400 "//chrome/android:chrome_junit_tests",
pkotwicz061c5a42015-09-30 02:16:54401 "//chrome/android:chrome_public_apk",
smaierd50624e2016-08-05 14:21:10402 "//chrome/android:chrome_public_test_apk",
Haiyang Pana0cc0052021-08-13 20:07:44403 "//chrome/android:chrome_public_unit_test_apk",
Peter E Conne4f9a4f2020-04-14 15:43:20404 "//chrome/browser/android/examples/custom_tabs_client:custom_tabs_client_example_apk",
Theresa Wellington565178d2020-04-03 20:43:51405 "//chrome/browser/android/examples/partner_browser_customizations_provider:partner_browser_customizations_example_apk",
agrieve473155b42015-12-28 20:23:11406 "//content/shell/android:content_shell_test_apk",
pkotwicz061c5a42015-09-30 02:16:54407 ]
408 }
409
dgnd1e190d2017-03-17 13:34:49410 if (enable_chrome_android_internal) {
brettwf9427f92016-05-05 23:18:55411 deps += [ "//clank" ]
cjhopmanca675d3e2014-10-24 03:50:45412 }
dprankedb5527d72015-03-08 04:22:47413 }
414
David 'Digit' Turner799d2122018-04-18 08:10:57415 # NOTE: The following should really be 'is_android', but the fuzzing build
416 # seems currently broken for this platform at the moment, and the
417 # corresponding code build and works on Linux unmodified.
418 # See instructions in the corresponding BUILD.gn.
Sean McAllisterdeaa7402020-07-31 04:42:54419 if (is_linux || is_chromeos) {
David 'Digit' Turner799d2122018-04-18 08:10:57420 deps +=
421 [ "//third_party/android_crazy_linker:android_crazy_linker_zip_fuzzer" ]
422 }
423
Anand K. Mistry5cd170e2018-11-06 00:25:21424 if (is_linux || is_chromeos) {
425 # This is only used by ChromeOS, but we want maximal fuzzer coverage, so
426 # run it under linux too.
427 deps += [
428 "//third_party/minizip:minizip_compress_fuzzer",
429 "//third_party/minizip:minizip_uncompress_fuzzer",
430 ]
431 }
432
Sean McAllisterdeaa7402020-07-31 04:42:54433 if (is_linux || is_chromeos || is_android) {
dprankefd1813272015-04-13 23:56:00434 deps += [
Mark Mentovaiebb9ddd62017-09-25 17:24:41435 "//third_party/breakpad:breakpad_unittests",
436 "//third_party/breakpad:core-2-minidump",
437 "//third_party/breakpad:generate_test_dump",
438 "//third_party/breakpad:minidump-2-core",
Benoit Lizee34d38a2018-06-18 09:19:02439 "//tools/dump_process_memory:dump_process",
dprankefd1813272015-04-13 23:56:00440 ]
441 }
442
Benoit Lized85493fe2022-04-25 10:26:00443 if (is_linux || is_chromeos || is_android || is_mac) {
444 deps += [ "//tools/memory/partition_allocator:all" ]
445 }
446
Yuta Hijikata05f38002020-12-17 00:49:24447 if (is_chromeos_ash) {
dpranke6293d252015-04-14 19:12:00448 deps += [
James Cookf8a2bf72017-10-16 18:51:39449 "//ash:ash_unittests",
Yao Li6172c23c2022-01-04 20:02:19450 "//ash/components:ash_components_unittests",
Darren Shen50e14952019-05-14 03:40:43451 "//ash/keyboard/ui:keyboard_unittests",
Yeunjoo Choi9b62f1a2021-06-23 13:17:00452 "//ash/webui:ash_webui_unittests",
Ben Pastene834e39882020-04-16 17:39:19453 "//chrome/browser/metrics/perf:profile_provider_unittest",
Anna Sato7f0cc9292022-08-12 15:10:25454 "//chrome/test:ash_crosapi_browsertests",
Anna Sato458124762022-09-20 00:53:20455 "//chrome/test:ash_crosapi_tests",
G. Silvad21fb1542019-03-15 02:17:33456 "//chrome/test:usage_time_limit_unittests",
Henrique Ferreiro5813efe2022-10-05 21:47:35457 "//chromeos/ash/components/proximity_auth:proximity_auth_unittests",
khorimoto4c539952016-12-04 02:37:11458 "//chromeos/components:chromeos_components_unittests",
Lloyd Piqueef3a2ab2020-10-15 19:29:09459 "//components/exo/wayland:wayland_client_compatibility_tests",
jamescook4c02a0b2016-12-02 23:14:42460 "//components/session_manager/core",
Amr Aboelkher1735ed72020-12-01 19:01:09461 "//third_party/shell-encryption:shell_encryption_unittests",
Baijun Zhua9842652022-05-19 23:28:34462 "//tools/traffic_annotation/auditor:traffic_annotation_auditor",
dpranke6293d252015-04-14 19:12:00463 "//ui/chromeos:ui_chromeos_unittests",
464 ]
465 }
466
Nico Weberd73c90382022-03-30 20:37:50467 if (is_chromeos) {
Samuel Huangeacc7502021-03-18 17:01:31468 deps += [ "//chromeos:chromeos_unittests" ]
469 }
470
Yuta Hijikata05f38002020-12-17 00:49:24471 if (is_chromeos_ash || is_mac || is_win) {
dprankefd1813272015-04-13 23:56:00472 deps += [
473 "//rlz:rlz_id",
474 "//rlz:rlz_lib",
475 "//rlz:rlz_unittests",
476 ]
477 }
478
Sean McAllisterdeaa7402020-07-31 04:42:54479 if (is_linux || is_chromeos) {
dprankedb5527d72015-03-08 04:22:47480 # The following are definitely linux-only.
hiroshigee6d374c2015-02-24 07:54:06481 deps += [
dprankedb5527d72015-03-08 04:22:47482 "//net:disk_cache_memory_test",
dprankedb5527d72015-03-08 04:22:47483 "//net:quic_client",
484 "//net:quic_server",
485 "//sandbox/linux:chrome_sandbox",
Henrique Nakashima87b6d8b2022-07-13 13:59:04486 "//sandbox/linux:sandbox_linux_unittests",
hiroshigee6d374c2015-02-24 07:54:06487 ]
Arthur Eubanks87cdea12022-02-17 21:18:51488 if (!is_clang) {
489 deps += [ "//testing:empty_main" ]
490 }
dnicoara8c6aa8e2015-03-11 23:20:32491
Daniel Nicoaracf98a1bf2022-08-09 19:51:44492 if (!is_castos) {
493 deps += [ "//chrome:xdg_mime" ]
494 }
495
mbjorgea12e5a52016-05-31 22:15:17496 if (use_dbus) {
497 deps += [
498 "//dbus:dbus_test_server",
499 "//dbus:dbus_unittests",
500 ]
501 }
502
dpranke2bc89212015-11-18 00:24:43503 if (is_chrome_branded && is_official_build) {
504 # TODO(dpranke): add the linux_dump_symbols flag?
505 deps += [ "//chrome:linux_symbols" ]
506 }
dprankedb5527d72015-03-08 04:22:47507 }
508
David Dorwin9985426fc2022-03-30 00:06:04509 if (is_ios || is_win || is_linux || is_chromeos_lacros || is_fuchsia) {
sherouke1859f92015-08-05 10:19:10510 deps += [
511 "//base:base_i18n_perftests",
sherouk710734d2015-09-02 19:02:58512 "//google_apis:google_apis_unittests",
sherouke1859f92015-08-05 10:19:10513 ]
514 }
515
Alexis Hetu56d21552018-08-10 19:22:41516 if ((is_win || is_mac || is_linux || is_chromeos || is_fuchsia) &&
sugoia1b7b922016-12-13 12:52:49517 (target_cpu == "x86" || target_cpu == "x64")) {
Alexis Hetu52981a32022-04-13 21:43:07518 deps += [
519 "//third_party/swiftshader/src/Vulkan:icd_file",
520 "//third_party/swiftshader/src/Vulkan:swiftshader_libvulkan",
521 ]
sugoiabe91892016-09-20 12:53:51522 }
523
thakis507c15c2016-06-01 00:26:01524 # TODO(GYP): Figure out which of these should (and can) build
David Dorwin9985426fc2022-03-30 00:06:04525 # for Chrome OS and iOS.
526 if (!is_chromeos_ash && !is_ios) {
tfarina9e7cf702015-02-23 21:13:44527 deps += [
dprankedb5527d72015-03-08 04:22:47528 "//base:build_utf8_validator_tables",
dpranke244f973d62015-11-20 05:38:10529 "//base:check_example",
dprankedb5527d72015-03-08 04:22:47530 "//cc:cc_perftests",
dprankedb5527d72015-03-08 04:22:47531 "//components:components_perftests",
dprankedb5527d72015-03-08 04:22:47532 "//device:device_unittests",
533 "//gin:gin_shell",
dprankedb5527d72015-03-08 04:22:47534 "//gin:gin_unittests",
Antoine Labourc6ade252017-10-19 01:01:16535 "//gpu:command_buffer_perftests",
Takuto Ikutaf5333252019-11-06 16:07:08536 "//gpu:gl_tests",
dpranke244f973d62015-11-20 05:38:10537 "//gpu:gpu_perftests",
dprankedb5527d72015-03-08 04:22:47538 "//ipc:ipc_perftests",
dprankedb5527d72015-03-08 04:22:47539 "//media:media_perftests",
dprankefd1813272015-04-13 23:56:00540 "//net:dump_cache",
dprankefd1813272015-04-13 23:56:00541 "//third_party/libphonenumber:libphonenumber_unittests",
dprankedb5527d72015-03-08 04:22:47542 "//ui/compositor:compositor_unittests",
543 ]
544
Daniel Nicoaracf98a1bf2022-08-09 19:51:44545 if (!is_android && !is_castos) {
agrieve473155b42015-12-28 20:23:11546 deps += [
547 "//chrome/test:load_library_perf_tests",
548 "//chrome/test:sync_performance_tests",
Daniel Nicoaracf98a1bf2022-08-09 19:51:44549 ]
550 }
551
552 if (!is_android) {
553 deps += [
agrieve473155b42015-12-28 20:23:11554 "//courgette:courgette",
555 "//courgette:courgette_fuzz",
556 "//courgette:courgette_minimal_tool",
557 "//courgette:courgette_unittests",
stevenjb7b6fd642016-05-18 18:15:30558 "//media/cast:generate_barcode_video",
559 "//media/cast:generate_timecode_audio",
agrieve473155b42015-12-28 20:23:11560 "//net:crash_cache",
Nico Weber2d5aa49bc2020-01-28 20:59:42561 "//net:net_watcher", # TODO(GYP): This should be conditional on
562 # use_v8_in_net
agrieve473155b42015-12-28 20:23:11563 "//net:run_testserver",
564 "//net:stress_cache",
565 "//net:tld_cleanup",
agrieve473155b42015-12-28 20:23:11566 "//third_party/leveldatabase:env_chromium_unittests",
567 "//third_party/libaddressinput:libaddressinput_unittests",
568 ]
569 }
dpranke7e19b472015-11-13 00:49:33570
jamescookfbbf9112016-06-14 16:24:49571 if (enable_extensions) {
Michael Giuffrida8ca5b932019-08-08 15:43:12572 deps += [ "//extensions/shell:app_shell" ]
jamescookfbbf9112016-06-14 16:24:49573 }
574
Mark Seaborn7c29eff92022-03-23 20:08:14575 # TODO(https://crbug.com/1299021): Implement building these NaCl targets
576 # as ARM32 when Chrome is built for ARM64 (for Linux/Chrome OS).
577 if (enable_nacl && target_cpu != "arm64") {
brettwf4b4a4282015-12-16 00:41:13578 deps += [ "//components/nacl/loader:nacl_loader_unittests" ]
dpranke2bc89212015-11-18 00:24:43579
Sean McAllisterdeaa7402020-07-31 04:42:54580 if (is_linux || is_chromeos) {
dpranke2bc89212015-11-18 00:24:43581 # TODO(dpranke): Figure out what platforms should actually have this.
milko.leporis3de038d2016-08-18 09:59:37582 deps += [ "//components/nacl/loader:nacl_helper" ]
dpranke2bc89212015-11-18 00:24:43583 }
dprankedb5527d72015-03-08 04:22:47584 }
585
xhwangfa2d9d472015-12-18 23:31:18586 if (media_use_ffmpeg && !is_android) {
mostynb2196a462015-08-20 17:22:10587 deps += [ "//media:ffmpeg_regression_tests" ]
588 }
dprankefd1813272015-04-13 23:56:00589 }
590
K. Moon46aabb282022-07-22 22:06:49591 if (enable_ppapi) {
David Dorwin35ee05a72022-03-08 22:12:21592 deps += [
593 "//ppapi:pepper_hash_for_uma",
594 "//ppapi:ppapi_perftests",
595 ]
596 }
597
David Dorwin42f98902022-04-05 15:55:56598 if (is_android || is_linux || is_chromeos_lacros) {
dprankefd1813272015-04-13 23:56:00599 deps += [
dprankefd1813272015-04-13 23:56:00600 "//components/network_hints/browser",
Nico Weber73db2f532020-04-21 19:40:18601 "//content/public/app",
Oksana Zhuravlova32f0a132018-02-27 00:12:55602 "//mojo:mojo_perftests",
rockot734fb662016-10-15 16:41:30603 "//services/service_manager/public/cpp",
dprankefd1813272015-04-13 23:56:00604 "//testing/gmock:gmock_main",
Mark Mentovaiebb9ddd62017-09-25 17:24:41605 "//third_party/breakpad:dump_syms($host_toolchain)",
606 "//third_party/breakpad:microdump_stackwalk($host_toolchain)",
607 "//third_party/breakpad:minidump_dump($host_toolchain)",
608 "//third_party/breakpad:minidump_stackwalk($host_toolchain)",
dprankefd1813272015-04-13 23:56:00609 ]
Ryan Keanea67d8022022-06-18 00:20:32610 }
dprankefd1813272015-04-13 23:56:00611
Ryan Keanea67d8022022-06-18 00:20:32612 if (is_linux || is_chromeos_lacros) {
613 deps += [
Ryan Keanea67d8022022-06-18 00:20:32614 "//gpu/khronos_glcts_support:khronos_glcts_test",
615 "//media/cast:cast_benchmarks",
616 "//media/cast:tap_proxy",
617 "//skia:filter_fuzz_stub",
618 "//skia:image_operations_bench",
619 "//ui/snapshot:snapshot_unittests",
620 ]
dprankefd1813272015-04-13 23:56:00621
Daniel Nicoaracf98a1bf2022-08-09 19:51:44622 if (!is_castos) {
623 deps += [ "//chrome/test:chrome_app_unittests" ]
624 }
625
626 if (!is_debug && !is_component_build && !is_castos) {
Ryan Keanea67d8022022-06-18 00:20:32627 deps += [ "//chrome/tools/service_discovery_sniffer" ]
dprankefd1813272015-04-13 23:56:00628 }
Ryan Keanea67d8022022-06-18 00:20:32629 }
dprankefd1813272015-04-13 23:56:00630
Ryan Keanea67d8022022-06-18 00:20:32631 if (ozone_platform_x11 && !is_castos && target_cpu != "arm") {
632 deps += [ "//gpu/tools/compositor_model_bench" ]
dprankedb5527d72015-03-08 04:22:47633 }
634
635 if (is_mac) {
636 deps += [
Mark Mentovaiebb9ddd62017-09-25 17:24:41637 "//third_party/breakpad:crash_inspector",
638 "//third_party/breakpad:dump_syms",
Alexander Surkove8851ed2020-09-03 21:03:24639
640 # The following are accessibility API tools.
Alexander Surkov836d76c2020-09-24 19:37:17641 "//tools/accessibility/inspect:ax_dump_events",
Alexander Surkove8851ed2020-09-03 21:03:24642 "//tools/accessibility/inspect:ax_dump_tree",
tfarina9e7cf702015-02-23 21:13:44643 ]
dpranke43760592014-11-08 02:59:57644 deps -= [
brettw011138d2015-10-21 03:05:38645 # Mojo in GN contains some things which are never compiled in GYP on Mac,
646 # so compilation fails on Mac. They need porting.
brettwe1d40652015-10-23 23:06:10647 "//mojo",
dprankecf8465db72014-11-10 23:51:22648 ]
dprankefd1813272015-04-13 23:56:00649 }
650
651 if (is_win) {
652 deps += [
653 "//base:pe_image_test",
John Budorickeee513d2019-11-08 00:38:52654 "//chrome/chrome_cleaner",
Patrick Monette0196be22019-05-10 03:33:15655 "//chrome/chrome_elf:chrome_elf_unittests",
656 "//chrome/chrome_elf:dll_hash_main",
S. Ganeshf1734082018-05-23 03:34:07657 "//chrome/elevation_service:elevation_service_unittests",
anantaf2e54a92016-05-28 00:39:16658 "//chrome/install_static:install_static_unittests",
Xi Chengec65b3b2018-02-02 20:42:02659 "//chrome/installer/gcapi",
grt734e87b2015-07-06 19:36:43660 "//chrome/installer/setup:setup_unittests",
Xi Chengd47af342018-04-24 02:36:33661 "//chrome/notification_helper:notification_helper_unittests",
Cliff Smolinsky56ac67b2019-05-08 14:20:36662 "//chrome/test:delayloads_unittests",
dprankefd1813272015-04-13 23:56:00663 "//components/wifi:wifi_test",
Samuel Huang577ef6c2018-03-13 18:19:34664 "//components/zucchini",
dprankefd1813272015-04-13 23:56:00665 "//net:quic_client",
666 "//net:quic_server",
dprankefd1813272015-04-13 23:56:00667 "//sandbox/win:sbox_integration_tests",
668 "//sandbox/win:sbox_unittests",
669 "//sandbox/win:sbox_validation_tests",
670 "//testing/gtest:gtest_main",
Xi Chengec65b3b2018-02-02 20:42:02671
672 # The following two are accessibility API debugging tools.
673 "//tools/accessibility/inspect:ax_dump_events",
674 "//tools/accessibility/inspect:ax_dump_tree",
robliaofd54b5c2017-01-13 00:41:30675 "//tools/win/chromeexts:chromeexts",
dprankefd1813272015-04-13 23:56:00676 ]
fdorayfb048bff2016-04-28 22:07:36677
Nico Weber300365f2018-02-23 20:45:04678 # TODO(thakis): Enable this in cross builds, https://crbug.com/799827
679 if (!(is_component_build && is_debug && target_cpu == "x86") &&
680 host_os == "win") {
Mike Meadeaf555182018-03-21 23:26:20681 deps += [ "//chrome/test/mini_installer:mini_installer_tests" ]
fdorayfb048bff2016-04-28 22:07:36682 }
scottmg6ea9ff3e2017-05-19 00:08:16683 } else if (!is_android && !is_ios && !is_fuchsia) {
Mark Mentovaiebb9ddd62017-09-25 17:24:41684 deps += [ "//third_party/breakpad:symupload($host_toolchain)" ]
mohsenf837da7c2014-12-09 19:01:34685 }
rsesek985bd812016-04-26 21:06:15686
David Dorwin92e520b2022-07-14 22:40:09687 if (is_cast_android || is_castos || (is_fuchsia && enable_cast_receiver)) {
Sergey Ulanov07406542019-12-18 00:09:43688 deps += [ "//chromecast:cast_test_lists" ]
Ryan Keanea67d8022022-06-18 00:20:32689 }
Sergey Ulanov07406542019-12-18 00:09:43690
Ryan Keanea67d8022022-06-18 00:20:32691 if (is_cast_android || is_castos) {
692 deps += [
693 "//chromecast:cast_shell",
694 "//chromecast/cast_core:core_runtime_simple",
695 ]
slance9d62f2015-11-04 01:15:01696 }
miu45b848fe2015-11-26 01:23:29697
Joshua Perazaec757a352020-11-11 04:05:09698 if (is_mac || is_win || is_android || is_linux || is_chromeos) {
rsesek985bd812016-04-26 21:06:15699 deps += [
Mark Mentovai1782adb2017-11-08 05:11:27700 "//third_party/crashpad/crashpad:crashpad_tests",
rsesek985bd812016-04-26 21:06:15701 "//third_party/crashpad/crashpad/handler:crashpad_handler",
702 "//third_party/crashpad/crashpad/tools:crashpad_database_util",
703 ]
704 }
705
Peter Beverloo69948322017-07-28 19:01:57706 if (enable_message_center) {
707 deps += [ "//ui/message_center:message_center_unittests" ]
708 }
709
David Dorwin0b132172022-03-30 04:56:11710 if (!is_android && !is_ios) {
scheib35dc9202016-04-26 22:35:43711 deps += [ "//content/browser/bluetooth/tools:bluetooth_metrics_hash" ]
712 }
713
Sean McAllisterdeaa7402020-07-31 04:42:54714 if (is_win || is_linux || is_chromeos) {
Xiaohan Wang5e2c87a2020-03-27 20:05:13715 deps += [ "//mojo" ]
sky97b65592015-11-02 20:08:25716 }
717
Sean McAllisterdeaa7402020-07-31 04:42:54718 if (is_mac || is_linux || is_chromeos || is_android || is_fuchsia) {
Oystein Eftevaaga9439b922018-01-08 19:30:14719 deps += [ "//third_party/perfetto:all" ]
720 }
721
Sean McAllisterdeaa7402020-07-31 04:42:54722 if (is_win || is_mac || is_linux || is_chromeos) {
Victor Costanaff027744a32018-11-19 21:05:32723 deps += [ "//third_party/sqlite:sqlite_shell" ]
724 }
725
Ryan Keanea67d8022022-06-18 00:20:32726 if ((is_linux && !is_castos) || is_chromeos_lacros || is_fuchsia) {
727 # TODO(https://crbug.com/1329673): Figure out if this should be in gn_all
728 # and how cross-platform this is.
Fabrice de Gans069214f2022-05-31 18:26:11729 deps += [ "//components/services/filesystem:filesystem_service_unittests" ]
730 }
731
Ryan Keanea67d8022022-06-18 00:20:32732 if ((is_linux && !is_castos) || is_chromeos_lacros) {
733 # TODO(https://crbug.com/1329673): Figure out if any of these should be in
734 # gn_all and figure out how cross-platform they are.
isherman0f89b43eb2015-04-11 00:02:45735 deps += [
dprankedb5527d72015-03-08 04:22:47736 "//chrome/installer/util:strings",
dprankedb5527d72015-03-08 04:22:47737 "//chrome/tools/convert_dict",
738 "//components/constrained_window:unit_tests",
dprankedb5527d72015-03-08 04:22:47739 "//components/metrics:serialization",
dprankedb5527d72015-03-08 04:22:47740 "//components/sessions:unit_tests",
stevenjb7b6fd642016-05-18 18:15:30741 "//media/cast:udp_proxy",
dprankedb5527d72015-03-08 04:22:47742 "//storage/browser:dump_file_system",
743 "//third_party/angle:libANGLE",
744 "//third_party/angle:libEGL",
745 "//third_party/angle:libGLESv2",
pwnallcfb346f12017-03-02 22:01:37746 "//third_party/leveldatabase:leveldb_test_targets",
dprankedb5527d72015-03-08 04:22:47747 "//third_party/libjpeg_turbo:simd",
dprankedb5527d72015-03-08 04:22:47748 "//third_party/opus:opus_compare",
749 "//third_party/opus:opus_demo",
dpranke244f973d62015-11-20 05:38:10750 "//third_party/opus:test_opus_api",
dprankedb5527d72015-03-08 04:22:47751 "//third_party/opus:test_opus_decode",
752 "//third_party/opus:test_opus_encode",
dprankedb5527d72015-03-08 04:22:47753 "//third_party/opus:test_opus_padding",
dprankedb5527d72015-03-08 04:22:47754 "//ui/display/types",
755 "//ui/shell_dialogs:shell_dialogs_unittests",
dprankedb5527d72015-03-08 04:22:47756 ]
dprankeb0713542015-07-31 21:07:21757
Gordana.Cmiljanovic85746ff12015-04-28 08:17:16758 if (target_cpu == "x86" || target_cpu == "x64") {
agrieve473155b42015-12-28 20:23:11759 if (!is_android) {
760 deps += [ "//chrome/test:load_library_perf_tests" ]
761 }
Dirk Pranke4dabe802017-11-02 07:18:55762 deps += [ "//third_party/libjpeg_turbo:simd_asm" ]
Gordana.Cmiljanovic85746ff12015-04-28 08:17:16763 }
Sean McAllisterdeaa7402020-07-31 04:42:54764 if ((is_linux || is_chromeos) && current_toolchain == host_toolchain) {
jochen11513aa02016-05-11 09:59:51765 deps += [ "//v8:v8_shell" ]
dpranke807f602b2015-03-17 23:20:56766 }
dprankedb5527d72015-03-08 04:22:47767 }
dprankeb0713542015-07-31 21:07:21768
Ryan Keanea67d8022022-06-18 00:20:32769 if ((is_linux && !is_castos) || is_chromeos ||
770 ((is_win || is_mac) && use_libfuzzer)) {
aizatskyaf496112016-04-15 19:26:32771 deps += [
772 "//testing/libfuzzer/fuzzers",
Dominik Röttsches0db553e02021-02-25 13:41:28773 "//third_party/freetype-testing:fuzzers",
Max Moroz174bee52019-02-21 00:11:28774 "//third_party/grpc:fuzzers",
aizatsky3f560172016-06-03 23:26:06775 "//third_party/icu/fuzzers",
noel6997c5c2017-04-13 14:12:18776 "//third_party/qcms:fuzzers",
Alex Chauab640752020-07-09 15:43:49777 "//third_party/ukey2/fuzzers",
Lei Zhang1295fa762017-12-12 00:49:16778 "//third_party/zlib/contrib/tests/fuzzers",
aizatskyaf496112016-04-15 19:26:32779 ]
Jonathan Metzman2656ecd2018-11-21 08:22:41780
Lei Zhang8baa2942021-05-19 03:59:48781 if (is_chromeos_ash) {
782 deps += [ "//chrome/services/ipp_parser/public/cpp:fuzzers" ]
783 }
784
Jonathan Metzman2656ecd2018-11-21 08:22:41785 # TODO(crbug.com/906751): Get the libFuzzer tests working on Windows.
Lei Zhang8baa2942021-05-19 03:59:48786 # Disable them for now because they cause the Windows clang ToT builder to
Jonathan Metzman2656ecd2018-11-21 08:22:41787 # fail.
788 if (!is_win) {
789 deps += [ "//testing/libfuzzer/tests:libfuzzer_tests" ]
790 }
aizatskyaf496112016-04-15 19:26:32791 }
792
Mark Seaborn7c29eff92022-03-23 20:08:14793 # TODO(https://crbug.com/1299021): Remove the special case for arm64.
794 if (enable_nacl && target_cpu != "arm64") {
sbc92b4d572016-02-18 03:28:23795 deps += [ "//native_client_sdk/src:nacl_core_sdk" ]
796 }
797
David Dorwin7d40e7f2022-03-31 19:13:39798 if (((is_linux || is_chromeos) && use_ozone) || is_fuchsia) {
skyostilfe116162016-02-26 20:53:33799 deps += [
Nicolas Ouellet-Payeurc7a9d262019-05-14 01:00:25800 "//headless:headless_non_renderer",
skyostilfe116162016-02-26 20:53:33801 "//headless:headless_tests",
802 ]
803 }
Christopher Grant193648b2017-06-07 15:08:36804
805 if (enable_vr) {
Tibor Goldschwendt213a42202017-10-17 20:13:44806 deps += [
807 "//chrome/browser/vr:vr_common_perftests",
808 "//chrome/browser/vr:vr_common_unittests",
Christopher Grant55c15892017-11-21 14:03:32809 "//chrome/browser/vr:vr_pixeltests",
Tibor Goldschwendt213a42202017-10-17 20:13:44810 ]
Brian Sheedyc512ec692021-09-17 23:52:23811 if (!is_android) {
812 deps += [ "//tools/perf/contrib/vr_benchmarks:vr_perf_tests" ]
813 } else {
bsheedy3b8ce262019-03-18 18:40:33814 deps += [ "//chrome/browser/android/vr:vr_android_unittests" ]
Brian Sheedyf74819b2021-06-04 01:38:38815 import("//tools/perf/chrome_telemetry_build/android_browser_types.gni")
816 foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
817 deps += [
818 "//tools/perf/contrib/vr_benchmarks:vr_perf_tests${_target_suffix}",
819 ]
820 }
Yash Malik8109b5bb2017-07-13 22:40:03821 }
Christopher Grant193648b2017-06-07 15:08:36822 }
Scott Grahamf24e3742017-08-11 17:50:22823
Martin Robinson297928532018-09-07 18:11:18824 if (use_atk) {
Martin Robinsone4fddede2018-09-18 10:30:21825 deps += [
826 "//tools/accessibility/inspect:ax_dump_events",
827 "//tools/accessibility/inspect:ax_dump_tree",
828 ]
Martin Robinson297928532018-09-07 18:11:18829 }
Alessio Bazzica383dcef92019-02-08 14:14:42830
Kai Ninomiya873ceec2020-01-30 04:19:28831 if (build_dawn_tests) {
Elly Fong-Jonesb03817a2019-11-14 18:10:12832 deps += [
dan sinclair2cccba462022-06-17 20:20:53833 "//third_party/dawn/src/dawn/fuzzers:fuzzers",
Austin Engbab1a5d2022-02-10 17:35:10834 "//third_party/dawn/src/dawn/tests:dawn_end2end_tests",
835 "//third_party/dawn/src/dawn/tests:dawn_unittests",
dan sinclair5bad2262022-06-20 16:10:55836 "//third_party/dawn/src/tint:tint_unittests",
Ryan Harrison2ec610f2022-04-02 02:30:24837 "//third_party/dawn/src/tint/fuzzers",
Elly Fong-Jonesb03817a2019-11-14 18:10:12838 ]
839 }
840
Alessio Bazzica383dcef92019-02-08 14:14:42841 # PFFFT.
842 deps += [
843 "//third_party/pffft:fuzzers",
844 "//third_party/pffft:pffft_benchmark",
845 "//third_party/pffft:pffft_unittest",
846 ]
Daniel Ruberyc81676b2020-05-13 00:48:27847
Adrian Taylor21dcb362021-09-01 14:58:14848 # Minimal binaries to exercise Rust toolchain.
849 deps += [ ":rust_build_tests" ]
Collina1e27a42022-01-26 20:12:03850
851 # More Rust targets.
852 if (toolchain_has_rust) {
853 deps += [
854 "//mojo/public/rust",
Collin Baker53f5a7b2022-03-03 00:59:17855 "//mojo/public/rust:mojo_rust_tests",
Adrian Taylor645390802022-04-21 18:22:48856 "//third_party/rust/autocxx/chromium_integration/tests",
Collin Baker829a71252022-06-24 19:08:23857
858 # TODO(crbug.com/1291994): Determine whether it makes sense to build/run
859 # this even on Android. If not, remove this and figure out how to run it
860 # only on desktop testers.
861 "//tools/crates/gnrt:gnrt_unittests",
Collin Baker6ee5f692022-06-23 21:06:22862 "//tools/crates/gnrt($host_toolchain)",
Collina1e27a42022-01-26 20:12:03863 ]
864 }
danakj71dabfa2022-02-24 14:32:14865 if (enable_rust) {
866 deps += [ "//testing/rust_gtest_interop:rust_gtest_interop_unittests" ]
867 }
Adrian Taylor21dcb362021-09-01 14:58:14868}
869
Adrian Taylor645390802022-04-21 18:22:48870# This group and the following exist to give targets for the waterfall to refer to.
Adrian Taylor21dcb362021-09-01 14:58:14871group("rust_build_tests") {
Lukasz Anforowicz8524e3562021-09-23 14:12:26872 testonly = true
Adrian Taylor21dcb362021-09-01 14:58:14873 deps = [ "//build/rust/tests" ]
tfarinafbc992492017-03-08 22:44:04874}
875
Adrian Taylor352d554a2022-04-22 15:44:40876group("rust_autocxx_tests") {
Adrian Taylor645390802022-04-21 18:22:48877 testonly = true
878 deps = [ "//third_party/rust/autocxx/chromium_integration/tests" ]
879}
880
Maksim Sisov25c86c82020-08-18 19:25:08881# TODO(https://crbug.com/1112776): ensure remoting is functional on Linux builds with
Maksim Sisov941ac832021-11-09 06:34:19882# other than X11 Ozone backends.
883if (enable_remoting && ((is_linux && ozone_platform_x11) ||
884 ((is_chromeos || is_win) && !use_ozone))) {
Nicolas Ouellet-Payeurebe785238d2021-11-12 14:49:55885 # On CQ, run the Traffic Annotation Auditor when a change affects one of these
886 # targets.
887 group("traffic_annotation_auditor_dependencies") {
Takuto Ikuta9d11eb12018-11-20 02:30:00888 deps = [
889 "//chrome:chrome",
Yuwei Huang256df172019-10-01 00:55:12890 "//remoting/client",
Takuto Ikuta9d11eb12018-11-20 02:30:00891 "//remoting/host:host",
Nicolas Ouellet-Payeur8026e2a2022-10-03 18:27:55892 "//tools/traffic_annotation:annotations_xml",
Takuto Ikuta9d11eb12018-11-20 02:30:00893 ]
Joe Mason448d37b5d2019-12-11 16:00:50894
895 if (is_win) {
896 deps += [ "//chrome/chrome_cleaner:shipped_binaries" ]
897 }
Takuto Ikuta9d11eb12018-11-20 02:30:00898 }
899}
900
Baijun Zhua9842652022-05-19 23:28:34901if (is_chromeos_ash) {
902 group("traffic_annotation_auditor_dependencies") {
903 deps = [
904 "//chrome",
905 "//chromeos",
Nicolas Ouellet-Payeur8026e2a2022-10-03 18:27:55906 "//tools/traffic_annotation:annotations_xml",
Baijun Zhua9842652022-05-19 23:28:34907 ]
908 }
909}
910
Nicolas Ouellet-Payeurebe785238d2021-11-12 14:49:55911if (is_android) {
912 # On CQ, run the Traffic Annotation Auditor when a change affects one of these
913 # targets.
914 group("traffic_annotation_auditor_dependencies") {
915 deps = [
916 "//chrome/android:chrome_public_apk",
Nicolas Ouellet-Payeur8026e2a2022-10-03 18:27:55917 "//tools/traffic_annotation:annotations_xml",
Nicolas Ouellet-Payeurebe785238d2021-11-12 14:49:55918 ]
919 }
920}
921
Scott Graham677e79102017-08-15 20:07:37922if (is_fuchsia) {
923 # TODO(https://crbug.com/731217): This can't practically be in //v8 without
924 # duplicating all the Fuchsia running infrastructure there.
Greg Thompsonada4b212022-09-12 13:31:49925 fuchsia_component("d8_component") {
Kevin Marshall57a19db2018-09-12 20:07:05926 testonly = true
Greg Thompsonada4b212022-09-12 13:31:49927 manifest = "//v8/gni/v8.cml"
928 data_deps = [ "//v8:d8" ]
Kevin Marshall39b4aa82018-06-23 00:12:15929 }
Greg Thompsonada4b212022-09-12 13:31:49930 fuchsia_package("d8_pkg") {
931 testonly = true
932 package_name = "d8"
933 deps = [ ":d8_component" ]
934 }
Kevin Marshall5fadadd2021-10-16 00:08:25935 fuchsia_package_installer("d8_fuchsia") {
Kevin Marshall57a19db2018-09-12 20:07:05936 testonly = true
Greg Thompsonada4b212022-09-12 13:31:49937 package = ":d8_pkg"
Kevin Marshall5fadadd2021-10-16 00:08:25938 package_name = "d8"
Scott Graham677e79102017-08-15 20:07:37939 }
940}
941
tfarinafbc992492017-03-08 22:44:04942# TODO(GYP_GONE): Figure out if we really need this target or if there's
943# some better way to specify things.
944if (is_win) {
945 group("chrome_official_builder_no_unittests") {
946 deps = [
probergefe476002017-06-23 14:29:01947 "//chrome/common/win:eventlog_provider",
Roger Tawa5cb75d72018-11-09 21:56:38948 "//chrome/credential_provider",
tfarinafbc992492017-03-08 22:44:04949 "//chrome/installer/gcapi",
950 "//chrome/installer/mini_installer",
Joshua Pawlickie7e42ef2021-11-10 00:19:19951 "//chrome/updater/win:updater_zip",
tfarinafbc992492017-03-08 22:44:04952 "//components/policy:pack_policy_templates",
Samuel Huang577ef6c2018-03-13 18:19:34953 "//components/zucchini",
tfarinafbc992492017-03-08 22:44:04954 "//courgette",
955 "//courgette:copy_courgette_binaries",
Koji Ishii4adc9c072020-09-07 04:03:43956 "//third_party/hyphenation-patterns",
holteb87f01f52017-04-10 20:45:53957 "//tools/metrics:metrics_metadata",
tfarinafbc992492017-03-08 22:44:04958 ]
959
960 if (target_cpu == "x86") {
961 if (is_clang) {
Nico Weber94d731c12017-07-25 19:40:46962 deps += [ "//courgette(//build/toolchain/win:win_clang_x64)" ]
tfarinafbc992492017-03-08 22:44:04963 } else {
964 deps += [ "//courgette(//build/toolchain/win:x64)" ]
965 }
966 }
967 if (is_chrome_branded) {
968 deps += [ "//remoting/host:remoting_host_installation" ]
969 }
970 }
971
972 group("chrome_official_builder") {
973 testonly = true
974
975 deps = [
976 ":chrome_official_builder_no_unittests",
977 "//base:base_unittests",
978 "//chrome/test:browser_tests",
tfarinafbc992492017-03-08 22:44:04979 "//ipc:ipc_tests",
980 "//media:media_unittests",
981 "//media/midi:midi_unittests",
982 "//net:net_unittests",
983 "//printing:printing_unittests",
984 "//sql:sql_unittests",
Michael Moss0484ee5c2020-05-14 17:18:06985 "//third_party/breakpad:symupload($host_toolchain)",
tfarinafbc992492017-03-08 22:44:04986 "//ui/base:ui_base_unittests",
987 "//ui/gfx:gfx_unittests",
988 "//ui/touch_selection:ui_touch_selection_unittests",
989 "//ui/views:views_unittests",
990 "//url:url_unittests",
991 ]
992 }
tfarinafbc992492017-03-08 22:44:04993}
994
Yuta Hijikata05f38002020-12-17 00:49:24995if (is_chromeos_ash) {
Ben Pastenebbb9bf142020-03-30 17:51:14996 # This group is used to collect all targets used when verifying a new version
997 # of Chrome for Chrome OS.
tfarinafbc992492017-03-08 22:44:04998 group("chromiumos_preflight") {
999 testonly = true
Ben Pastene3ea517912020-07-02 00:20:421000 data_deps = [
tfarinafbc992492017-03-08 22:44:041001 "//chrome",
1002 "//chrome/test/chromedriver",
Wei Lee01d63ef2019-05-09 09:24:501003 "//components/chromeos_camera:jpeg_decode_accelerator_unittest",
Jim Shargo906dbce2021-10-14 18:48:461004 "//components/exo/wayland:wayland_client_integration_tests",
Ben Pastenebbb9bf142020-03-30 17:51:141005 "//components/exo/wayland:wayland_client_perftests",
Lucas Berthou8841d6272021-02-24 20:28:501006 "//components/exo/wayland:wayland_client_tests",
Mohamed Omar42fe5872022-08-10 17:25:531007 "//components/policy/test_support:fake_dmserver",
tfarinafbc992492017-03-08 22:44:041008 "//media:media_unittests",
Ben Pastenebbb9bf142020-03-30 17:51:141009 "//media/capture:capture_unittests",
tfarinafbc992492017-03-08 22:44:041010 "//sandbox/linux:chrome_sandbox",
Henrique Nakashima87b6d8b2022-07-13 13:59:041011 "//sandbox/linux:sandbox_linux_unittests",
Mark Mentovaiebb9ddd62017-09-25 17:24:411012 "//third_party/breakpad:minidump_stackwalk($host_toolchain)",
Austin Engbab1a5d2022-02-10 17:35:101013 "//third_party/dawn/src/dawn/tests:dawn_end2end_tests",
1014 "//third_party/dawn/src/dawn/tests:dawn_unittests",
Jim Shargoc84cb582022-04-28 17:10:571015 "//ui/ozone:ozone_integration_tests",
tfarinafbc992492017-03-08 22:44:041016
1017 # Blocked on https://github.com/catapult-project/catapult/issues/2297
1018 #"//third_party/catapult/telemetry:bitmaptools",
1019 "//tools/perf/clear_system_cache",
Ben Pastenebbb9bf142020-03-30 17:51:141020 "//ui/ozone/gl:ozone_gl_unittests",
tfarinafbc992492017-03-08 22:44:041021 ]
Alexandre Courbot8ad2427d2017-08-25 14:04:551022
Lei Zhang1e297622022-06-28 10:30:061023 if (enable_plugins) {
1024 data_deps += [ "//ppapi/examples/video_decode" ]
1025 }
1026
Alexandre Courbot8ad2427d2017-08-25 14:04:551027 if (use_v4l2_codec || use_vaapi) {
Ben Pastene3ea517912020-07-02 00:20:421028 data_deps += [
Wei Lee01d63ef2019-05-09 09:24:501029 "//components/chromeos_camera:jpeg_encode_accelerator_unittest",
David Staessens601a2102019-02-06 03:37:131030 "//media/gpu:video_decode_accelerator_perf_tests",
David Staessens82b5b7d2018-11-21 10:40:261031 "//media/gpu:video_decode_accelerator_tests",
Hirokazu Hondad4a42c62020-08-21 04:39:081032 "//media/gpu:video_encode_accelerator_perf_tests",
1033 "//media/gpu:video_encode_accelerator_tests",
Nathan Hebert702396b2021-06-09 20:06:311034 "//media/gpu/chromeos:image_processor_test",
Alexandre Courbot8ad2427d2017-08-25 14:04:551035 ]
Ben Pastenebbb9bf142020-03-30 17:51:141036 if (use_vaapi) {
Jao-ke Chin-Lee994de272020-12-28 20:05:081037 data_deps += [
1038 "//media/gpu/vaapi:decode_test",
1039 "//media/gpu/vaapi:vaapi_unittest",
1040 ]
Ben Pastenebbb9bf142020-03-30 17:51:141041 }
Steve Cho2ac5f2d2022-02-04 17:15:421042 if (use_v4l2_codec) {
1043 data_deps += [ "//media/gpu/v4l2:v4l2_stateless_decoder" ]
1044 }
Alexandre Courbot8ad2427d2017-08-25 14:04:551045 }
tfarinafbc992492017-03-08 22:44:041046 }
dprankedb5527d72015-03-08 04:22:471047}
1048
dprankedb5527d72015-03-08 04:22:471049group("gn_visibility") {
dpranked62d8512015-03-02 03:06:031050 deps = [
dprankeb6128d02015-05-01 16:40:301051 "//build/config/sanitizers:options_sources",
dprankedb5527d72015-03-08 04:22:471052 # "//third_party/pdfium:pdfium_embeddertests", # TODO(GYP): visibility?
1053 # "//third_party/pdfium:pdfium_unittests", # TODO(GYP): visibility?
dpranked62d8512015-03-02 03:06:031054 ]
dpranked2fb5222015-09-10 22:39:051055
1056 if (!is_ios) {
Peng Huanga3f0ece52018-01-20 01:22:461057 deps += [ "//v8:postmortem-metadata" ]
Simon Zündb6e449b2019-10-15 07:33:431058 if (!v8_use_external_startup_data) {
Peng Huanga3f0ece52018-01-20 01:22:461059 deps += [ "//v8:v8_snapshot" ]
1060 }
dpranked2fb5222015-09-10 22:39:051061 }
dpranked62d8512015-03-02 03:06:031062}
1063
Sergey Ulanovdaa25ebc2018-01-02 18:17:171064if (!is_ios) {
David Dorwin776712222022-04-13 23:01:541065 group("chromedriver") {
1066 testonly = true
1067
1068 if (is_fuchsia || is_android) {
Ryan Keanea67d8022022-06-18 00:20:321069 # On Fuchsia and non-Cast Android, ChromeDriver runs on the host, not the
1070 # device.
1071 if (!is_cast_android) {
David Dorwin776712222022-04-13 23:01:541072 deps = [ "//chrome/test/chromedriver:chromedriver($host_toolchain)" ]
Ryan Keanea67d8022022-06-18 00:20:321073 }
1074 if (is_android && !is_cast_android) {
1075 deps += [ "//chrome/test/chromedriver/test/webview_shell:chromedriver_webview_shell_apk" ]
David Dorwin776712222022-04-13 23:01:541076 }
Daniel Nicoaracf98a1bf2022-08-09 19:51:441077 } else if (!is_castos) {
David Dorwin776712222022-04-13 23:01:541078 deps = [
1079 "//chrome/test/chromedriver:chromedriver",
1080 "//chrome/test/chromedriver:chromedriver_unittests",
1081 ]
1082 }
1083 }
1084
tfarinacb2638b2015-05-12 03:24:151085 # This group includes all of the targets needed to build and test Blink,
Giovanni Ortuño Urquidie7f98f82019-10-29 00:26:591086 # including running web tests (see below). This target is defined here because
1087 # previously //third_party/WebKit, now //third_party/blink, couldn't depend on
1088 # //content/shell. This might not longer be true, see
1089 # https://crbug.com/1018659.
tfarinacb2638b2015-05-12 03:24:151090 group("blink_tests") {
1091 testonly = true
1092
1093 deps = [
Kent Tamuraef54e402019-02-14 07:18:361094 ":blink_web_tests",
Weizhong Xia8b786422022-06-23 14:46:511095 ":blink_wpt_tests",
Blink Reformata30d4232018-04-07 15:31:061096 "//third_party/blink/public:all_blink",
tansell88df42592016-11-15 07:22:591097 ]
1098 }
1099
Kent Tamuraef54e402019-02-14 07:18:361100 # Web tests runner
Kent Tamura5e69e912018-05-02 13:05:001101 # third_party/blink/tools/run_web_tests.py
Kent Tamuraef54e402019-02-14 07:18:361102 group("run_web_tests") {
tansell88df42592016-11-15 07:22:591103 testonly = true
Weizhong Xia8b786422022-06-23 14:46:511104 deps = [
1105 ":blink_web_tests",
1106 ":blink_wpt_tests",
1107 ]
tansell88df42592016-11-15 07:22:591108 }
1109
Daniel Nicoaracf98a1bf2022-08-09 19:51:441110 if (!is_chromeos_ash && !is_ios && !is_fuchsia && !is_android && !is_castos) {
kyle Juf8cdeac2019-02-07 00:10:011111 # WPT Webdriver tests runner
1112 # chrome/test/chromedriver/test/run_webdriver_tests.py
Stephen McGruer367e9b202021-03-19 13:32:181113 script_test("webdriver_wpt_tests") {
1114 # The script is wrapped in testing/xvfb.py; the actual
1115 # run_webdriver_tests.py script is passed as an arg in gn_isolate_map.pyl
1116 script = "//testing/xvfb.py"
1117
kyle Juf8cdeac2019-02-07 00:10:011118 data = [
Brian Sheedy6bcba67d2022-02-23 23:45:111119 "//build/skia_gold_common/",
kyle Ju1c031852019-03-28 16:31:481120 "//chrome/test/chromedriver/chrome_paths.py",
1121 "//chrome/test/chromedriver/server/server.py",
1122 "//chrome/test/chromedriver/test/run_webdriver_tests.py",
1123 "//chrome/test/chromedriver/util.py",
kyle Ju0eabe31e2019-02-15 15:29:501124 "//third_party/blink/tools/blinkpy/",
kyle Juf8cdeac2019-02-07 00:10:011125 "//third_party/blink/web_tests/external/wpt/webdriver/",
kyle Ju1c031852019-03-28 16:31:481126 "//third_party/blink/web_tests/VirtualTestSuites",
1127 "//third_party/blink/web_tests/WebDriverExpectations",
Keita Suzuki9ff17d42020-03-10 06:19:511128 "//third_party/pywebsocket3/src/mod_pywebsocket/",
Stephen McGruere934d52e2021-01-27 22:26:101129 "//third_party/wpt_tools/",
kyle Juf8cdeac2019-02-07 00:10:011130 ]
1131 data_deps = [
1132 "//chrome:chrome",
1133 "//chrome/test/chromedriver",
Will Harrisd35e2c92021-04-07 01:42:021134 "//testing:test_scripts_shared",
Robert Ma6f908762020-01-31 16:24:541135 "//third_party/catapult/third_party/typ",
kyle Juf8cdeac2019-02-07 00:10:011136 ]
Scott Violet0a4949d32020-02-11 18:53:031137 if (is_win) {
1138 data_deps += [ "//build/win:copy_cdb_to_output" ]
1139 }
kyle Juf8cdeac2019-02-07 00:10:011140 }
Luke Zielinski57397c7c2021-03-04 22:53:511141 script_test("wpt_tests_isolate") {
Nihar Damarasingu509ce0c2022-09-01 14:18:201142 script = "//third_party/blink/tools/run_wpt_tests.py"
Nihar Damarasingu655e7c182022-09-22 16:54:571143 args = [ "--product=chrome" ]
Luke Zielinski218ddea32019-07-15 16:52:241144 data_deps = [
1145 "//chrome:chrome",
1146 "//chrome/test/chromedriver",
Luke Zielinski57397c7c2021-03-04 22:53:511147 "//third_party/blink/tools:wpt_tests_isolate",
Luke Zielinski218ddea32019-07-15 16:52:241148 ]
Luke Zielinski218ddea32019-07-15 16:52:241149 }
Thorben Troebst9ae657482022-08-25 23:26:251150 script_test("wpt_tests_isolate_content_shell") {
Nihar Damarasingu509ce0c2022-09-01 14:18:201151 script = "//third_party/blink/tools/run_wpt_tests.py"
Thorben Troebst9ae657482022-08-25 23:26:251152 data_deps = [
1153 ":blink_web_tests_support_data",
1154 "//third_party/blink/tools:wpt_tests_isolate",
1155 ]
1156 }
kyle Juf8cdeac2019-02-07 00:10:011157 }
1158
Kai Ninomiyafb9e5962020-03-17 06:11:381159 group("blink_web_tests_support_data") {
John Budorick7c8273b2019-04-25 15:27:471160 testonly = true
tansell88df42592016-11-15 07:22:591161 data_deps = [
yzshena0646992017-04-02 22:01:271162 ":layout_test_data_mojo_bindings",
Ken Rockot86d360462018-10-24 02:50:091163 ":layout_test_data_mojo_bindings_lite",
tansell88df42592016-11-15 07:22:591164 "//content/shell:content_shell",
Ken Rockot3d21f6a2020-10-09 03:39:431165 "//content/test:mojo_bindings_web_test_mojom_js_data_deps",
Natalie Chouinard3f8829c2019-12-17 02:39:201166 "//content/test:mojo_web_test_bindings_js_data_deps",
Reilly Grantfa93b142018-02-01 02:13:481167 "//device/bluetooth/public/mojom:fake_bluetooth_interfaces_js_data_deps",
Rafael Cintron5b95b8d2020-11-04 01:58:101168 "//device/vr/public/mojom:vr_service_js_data_deps",
Christian Fremerey65d1f5e2018-03-02 23:46:481169 "//media/capture/mojom:image_capture_js_data_deps",
Adithya Srinivasan5b82b2e2018-12-14 16:08:091170 "//media/midi:mojo_js_data_deps",
yzshen9e737bf2017-06-21 19:38:231171 "//mojo/public/interfaces/bindings/tests:test_data_deps",
Giovanni Ortuño Urquidif07d80c2019-10-03 07:43:381172 "//mojo/public/js/ts/bindings/tests:test_interfaces_js_data_deps",
Natalie Chouinard3f8829c2019-12-17 02:39:201173 "//mojo/public/mojom/base:base_js_data_deps",
Ke He31d0bb02018-02-24 07:16:241174 "//services/device/public/mojom:generic_sensor_js_data_deps",
Natalie Chouinard3f8829c2019-12-17 02:39:201175 "//services/device/public/mojom:mojom_js_data_deps",
Donna Wu4dc9df32019-05-20 03:56:211176 "//services/device/public/mojom:usb_js_data_deps",
Natalie Chouinard3f8829c2019-12-17 02:39:201177 "//services/shape_detection/public/mojom:mojom_js_data_deps",
Miyoung Shin40adbd62019-07-30 07:33:401178 "//skia/public/mojom:mojom_js_data_deps",
jonrossc1179f2c2019-04-23 22:56:151179 "//testing/buildbot/filters:blink_web_tests_filter",
Blink Reformata30d4232018-04-07 15:31:061180 "//third_party/blink/public:blink_devtools_frontend_resources_files",
Alex Rudenko9d994132020-06-02 12:37:001181 "//third_party/blink/public:blink_devtools_inspector_resources",
Julie Jeongeun Kim4f1b5aa2019-05-08 01:32:091182 "//third_party/blink/public/mojom:mojom_platform_js_data_deps",
Morten Stenshorne8d7c45b2020-10-14 18:33:061183 "//third_party/blink/renderer/core:js_files_for_form_controls_web_tests",
Rakib M. Hasan995ca2e2019-10-14 19:48:401184 "//third_party/catapult/third_party/typ",
Koji Ishiia507ce82020-10-20 21:39:451185 "//third_party/hyphenation-patterns:test_data",
Alexis Hetu0f218862018-08-13 18:51:421186 "//third_party/mesa_headers",
agrieve993374cf2016-04-13 00:05:391187 "//tools/imagediff",
Brian Sheedy6bcba67d2022-02-23 23:45:111188 "//ui/base:goldctl",
tfarinacb2638b2015-05-12 03:24:151189 ]
1190
tfarinacb2638b2015-05-12 03:24:151191 if (is_android) {
tansell88df42592016-11-15 07:22:591192 data_deps += [
Mark Mentovaiebb9ddd62017-09-25 17:24:411193 "//third_party/breakpad:breakpad_unittests",
1194 "//third_party/breakpad:dump_syms",
1195 "//third_party/breakpad:microdump_stackwalk",
1196 "//third_party/breakpad:minidump_dump",
1197 "//third_party/breakpad:minidump_stackwalk",
1198 "//third_party/breakpad:symupload",
jbudoricke7bcf092016-09-28 18:24:141199 "//tools/android/forwarder2",
ojan94989c72015-07-17 21:56:421200 ]
Peter Kotwiczdeb8c9fda2020-07-03 23:34:091201 } else {
danakj89f47082020-09-02 17:53:431202 data_deps += [ "//content/web_test:web_test_common_mojom_js_data_deps" ]
tfarinacb2638b2015-05-12 03:24:151203 }
1204
tfarinacb2638b2015-05-12 03:24:151205 if (!is_win && !is_android) {
Mark Mentovaiebb9ddd62017-09-25 17:24:411206 data_deps +=
1207 [ "//third_party/breakpad:minidump_stackwalk($host_toolchain)" ]
tfarinacb2638b2015-05-12 03:24:151208 }
1209
1210 if (is_mac) {
Mark Mentovaiebb9ddd62017-09-25 17:24:411211 data_deps += [ "//third_party/breakpad:dump_syms($host_toolchain)" ]
tfarinacb2638b2015-05-12 03:24:151212 }
1213
Sean McAllisterdeaa7402020-07-31 04:42:541214 if (is_linux || is_chromeos) {
Mark Mentovaiebb9ddd62017-09-25 17:24:411215 data_deps += [ "//third_party/breakpad:dump_syms($host_toolchain)" ]
tfarinacb2638b2015-05-12 03:24:151216 }
qyearsley165a17a82016-08-01 17:58:501217
Sergey Ulanovdaa25ebc2018-01-02 18:17:171218 if (is_fuchsia) {
Kevin Marshall5fadadd2021-10-16 00:08:251219 data_deps += [
1220 "//build/config/fuchsia:deployment_resources",
1221 "//content/shell:content_shell_fuchsia",
1222 "//content/shell:content_shell_pkg__archive-manifest",
1223 "//content/shell:content_shell_pkg__archive-metadata",
1224 ]
Sergey Ulanovdaa25ebc2018-01-02 18:17:171225 }
1226
qyearsley165a17a82016-08-01 17:58:501227 data = [
Brian Sheedy6bcba67d2022-02-23 23:45:111228 "//build/skia_gold_common/",
Austin Eng11eba3d2020-10-01 15:08:191229 "//testing/scripts/common.py",
1230 "//testing/scripts/run_isolated_script_test.py",
1231 "//testing/xvfb.py",
Kent Tamurac1e4c412018-04-19 02:01:361232 "//third_party/blink/tools/",
Kai Ninomiyafb9e5962020-03-17 06:11:381233 "//third_party/blink/web_tests/resources/",
Keita Suzuki9ff17d42020-03-10 06:19:511234 "//third_party/pywebsocket3/src/mod_pywebsocket/",
Kent Tamura5a9c7e42020-06-18 10:38:141235 "//third_party/test_fonts/test_fonts/",
Stephen McGruere934d52e2021-01-27 22:26:101236 "//third_party/wpt_tools/",
qyearsley165a17a82016-08-01 17:58:501237 ]
tansell0e6baaf22017-02-16 09:14:531238
tansell820f7df2017-02-16 13:59:151239 if (is_win) {
tansell1b05bbd2017-05-04 09:30:321240 data += [
1241 "//third_party/apache-win32/",
Takuto Ikuta1623ca32018-11-12 15:16:081242 "//third_party/perl/perl/",
tansell1b05bbd2017-05-04 09:30:321243 ]
Scott Violet0a4949d32020-02-11 18:53:031244 data_deps += [ "//build/win:copy_cdb_to_output" ]
tansell820f7df2017-02-16 13:59:151245 }
1246
Weizhong Xia05781fc2022-03-16 01:05:091247 if (is_mac) {
Nico Weber5a0046e2022-03-23 20:46:301248 data += [
1249 "//third_party/apache-mac/",
1250 "//third_party/apache-mac-arm64/",
1251 ]
Weizhong Xia05781fc2022-03-16 01:05:091252 }
1253
Weizhong Xiaa14eaad2022-04-01 02:04:441254 if (is_linux || is_fuchsia) {
1255 data += [ "//third_party/apache-linux/" ]
1256 }
1257
tansell0e6baaf22017-02-16 09:14:531258 if (is_android) {
1259 data += [
1260 "//third_party/catapult/",
1261 "//build/android/",
1262 ]
1263 }
tfarinacb2638b2015-05-12 03:24:151264 }
yzshena0646992017-04-02 22:01:271265
Dirk Pranke67bc5a9d2020-10-09 16:33:481266 _common_web_test_script = "//testing/scripts/run_isolated_script_test.py"
1267
1268 _common_web_test_args = [ "@WrappedPath(" + rebase_path(
1269 "//third_party/blink/tools/run_web_tests.py",
1270 root_build_dir) + ")" ]
1271 if (is_debug) {
1272 _common_web_test_args += [ "--debug" ]
1273 } else {
1274 _common_web_test_args += [ "--release" ]
Dirk Prankef452bb2a2020-10-09 22:11:551275 if (dcheck_always_on) {
Weizhong Xia91b53362022-01-05 17:13:351276 _common_web_test_args += [ "--timeout-ms=12000" ]
Dirk Prankef452bb2a2020-10-09 22:11:551277 }
Dirk Pranke67bc5a9d2020-10-09 16:33:481278 }
1279
1280 if (is_android) {
1281 _common_web_test_args += [
1282 "--platform",
1283 "android",
1284 ]
1285 }
1286
1287 _common_web_test_args += [
1288 "--seed",
1289 "4",
Weizhong Xiaeaff2f22022-01-24 18:34:141290 "--debug-rwt-logging",
Dirk Pranke67bc5a9d2020-10-09 16:33:481291 "--no-show-results",
1292 "--zero-tests-executed-ok",
1293 "--clobber-old-results",
1294 "--exit-after-n-failures",
1295 "5000",
1296 "--exit-after-n-crashes-or-timeouts",
1297 "100",
1298 ]
1299
John Palmer0e0f72bf2021-06-07 09:10:201300 # https://chromium.googlesource.com/chromium/src/+/main/docs/testing/web_tests.md
Dirk Pranke6188075b2020-10-01 19:31:281301 script_test("blink_web_tests") {
Dirk Pranke67bc5a9d2020-10-09 16:33:481302 script = _common_web_test_script
Dirk Pranke6188075b2020-10-01 19:31:281303
Dirk Pranke67bc5a9d2020-10-09 16:33:481304 args = _common_web_test_args
Dirk Pranke6188075b2020-10-01 19:31:281305
Ian Clelland07ffd02c2021-07-08 19:22:381306 data_deps = [ ":blink_web_tests_support_data" ]
Kai Ninomiyafb9e5962020-03-17 06:11:381307 data = [
1308 "//third_party/blink/perf_tests/",
Weizhong Xia02352952022-04-29 00:49:421309 "//third_party/blink/web_tests/SmokeTests/Default.txt",
Weizhong Xia53c492162021-09-09 17:08:241310 "//third_party/blink/web_tests/VirtualTestSuites",
Alastair Donaldson308bb212021-09-14 20:50:271311
Weizhong Xia53c492162021-09-09 17:08:241312 # List all test expectations here
1313 "//third_party/blink/web_tests/ASANExpectations",
1314 "//third_party/blink/web_tests/LeakExpectations",
1315 "//third_party/blink/web_tests/MSANExpectations",
1316 "//third_party/blink/web_tests/NeverFixTests",
1317 "//third_party/blink/web_tests/SlowTests",
1318 "//third_party/blink/web_tests/StaleTestExpectations",
1319 "//third_party/blink/web_tests/TestExpectations",
1320 "//third_party/blink/web_tests/WebDriverExpectations",
1321 "//third_party/blink/web_tests/WebGPUExpectations",
Alastair Donaldson308bb212021-09-14 20:50:271322
Weizhong Xia53c492162021-09-09 17:08:241323 # === List Test Cases folders here ===
1324 "//third_party/blink/web_tests/accessibility/",
1325 "//third_party/blink/web_tests/android/",
1326 "//third_party/blink/web_tests/animations/",
1327 "//third_party/blink/web_tests/app_banner/",
1328 "//third_party/blink/web_tests/bindings/",
1329 "//third_party/blink/web_tests/clipboard/",
1330 "//third_party/blink/web_tests/compositing/",
1331 "//third_party/blink/web_tests/crypto/",
1332 "//third_party/blink/web_tests/css-parser/",
1333 "//third_party/blink/web_tests/css1/",
1334 "//third_party/blink/web_tests/css2.1/",
1335 "//third_party/blink/web_tests/css3/",
1336 "//third_party/blink/web_tests/cssom/",
1337 "//third_party/blink/web_tests/custom-elements/",
1338 "//third_party/blink/web_tests/custom-properties/",
1339 "//third_party/blink/web_tests/dark-mode/",
Vladimir Levinf1aa4e02022-01-20 21:56:411340 "//third_party/blink/web_tests/document-transition/",
Weizhong Xia53c492162021-09-09 17:08:241341 "//third_party/blink/web_tests/dom/",
1342 "//third_party/blink/web_tests/editing/",
Weizhong Xia53c492162021-09-09 17:08:241343 "//third_party/blink/web_tests/fast/",
1344 "//third_party/blink/web_tests/fonts/",
1345 "//third_party/blink/web_tests/fragmentation/",
1346 "//third_party/blink/web_tests/fullscreen/",
1347 "//third_party/blink/web_tests/gamepad/",
1348 "//third_party/blink/web_tests/harness-tests/",
1349 "//third_party/blink/web_tests/hittesting/",
1350 "//third_party/blink/web_tests/html/",
1351 "//third_party/blink/web_tests/html5lib/",
1352 "//third_party/blink/web_tests/http/",
1353 "//third_party/blink/web_tests/idle-callback/",
1354 "//third_party/blink/web_tests/ietestcenter/",
1355 "//third_party/blink/web_tests/images/",
1356 "//third_party/blink/web_tests/inspector-protocol/",
1357 "//third_party/blink/web_tests/intersection-observer/",
1358 "//third_party/blink/web_tests/jquery/",
1359 "//third_party/blink/web_tests/js/",
1360 "//third_party/blink/web_tests/lifecycle/",
1361 "//third_party/blink/web_tests/loader/",
1362 "//third_party/blink/web_tests/media/",
1363 "//third_party/blink/web_tests/media_capabilities/",
1364 "//third_party/blink/web_tests/mhtml/",
1365 "//third_party/blink/web_tests/navigator_language/",
1366 "//third_party/blink/web_tests/navigator_webdriver/",
1367 "//third_party/blink/web_tests/netinfo/",
1368 "//third_party/blink/web_tests/overflow/",
1369 "//third_party/blink/web_tests/paint/",
1370 "//third_party/blink/web_tests/payments/",
1371 "//third_party/blink/web_tests/permissionclient/",
1372 "//third_party/blink/web_tests/plugins/",
1373 "//third_party/blink/web_tests/pointer-lock/",
1374 "//third_party/blink/web_tests/print_testharness/",
1375 "//third_party/blink/web_tests/printing/",
1376 "//third_party/blink/web_tests/register-protocol-handler/",
1377 "//third_party/blink/web_tests/regress/",
1378 "//third_party/blink/web_tests/resize-observer/",
1379 "//third_party/blink/web_tests/resources/",
1380 "//third_party/blink/web_tests/rootscroller/",
1381 "//third_party/blink/web_tests/screen_orientation/",
1382 "//third_party/blink/web_tests/scrollbars/",
1383 "//third_party/blink/web_tests/scrollingcoordinator/",
1384 "//third_party/blink/web_tests/security/",
Jiewei Qian4db71f42021-12-09 02:31:071385 "//third_party/blink/web_tests/handwriting/",
Weizhong Xia53c492162021-09-09 17:08:241386 "//third_party/blink/web_tests/shadow-dom/",
1387 "//third_party/blink/web_tests/storage/",
1388 "//third_party/blink/web_tests/svg/",
1389 "//third_party/blink/web_tests/synthetic_gestures/",
1390 "//third_party/blink/web_tests/tables/",
1391 "//third_party/blink/web_tests/test_runner/",
1392 "//third_party/blink/web_tests/third_party/",
1393 "//third_party/blink/web_tests/timezonechange/",
1394 "//third_party/blink/web_tests/touchadjustment/",
1395 "//third_party/blink/web_tests/transforms/",
1396 "//third_party/blink/web_tests/transitions/",
1397 "//third_party/blink/web_tests/traversal/",
1398 "//third_party/blink/web_tests/typedcssom/",
1399 "//third_party/blink/web_tests/vibration/",
1400 "//third_party/blink/web_tests/virtual/",
1401 "//third_party/blink/web_tests/virtualkeyboard/",
1402 "//third_party/blink/web_tests/wake-lock/",
1403 "//third_party/blink/web_tests/wasm/",
1404 "//third_party/blink/web_tests/webaudio/",
1405 "//third_party/blink/web_tests/webexposed/",
1406 "//third_party/blink/web_tests/webgpu/",
Weizhong Xia53c492162021-09-09 17:08:241407 "//third_party/blink/web_tests/xmlviewer/",
Alastair Donaldson308bb212021-09-14 20:50:271408
Weizhong Xia53c492162021-09-09 17:08:241409 # === Test Case Folders Ends ===
Kai Ninomiyafb9e5962020-03-17 06:11:381410 ]
Weizhong Xia53c492162021-09-09 17:08:241411
1412 if (is_win || is_linux || is_fuchsia) {
1413 data += [
1414 "//third_party/blink/web_tests/platform/win/",
Weizhong Xiadfb5304f2022-05-12 20:36:261415 "//third_party/blink/web_tests/platform/win10/",
Weizhong Xia53c492162021-09-09 17:08:241416 ]
1417 if (is_linux || is_fuchsia) {
1418 data += [ "//third_party/blink/web_tests/platform/linux/" ]
1419 }
1420 if (is_fuchsia) {
Weizhong Xia6ff3dcf02022-05-03 05:10:431421 data += [ "//third_party/blink/web_tests/platform/fuchsia/" ]
Weizhong Xia53c492162021-09-09 17:08:241422 }
1423 } else if (is_mac) {
1424 data += [
Weizhong Xia02352952022-04-29 00:49:421425 "//third_party/blink/web_tests/SmokeTests/Mac.txt",
Weizhong Xia53c492162021-09-09 17:08:241426 "//third_party/blink/web_tests/platform/mac/",
Weizhong Xia53c492162021-09-09 17:08:241427 "//third_party/blink/web_tests/platform/mac-mac10.13/",
1428 "//third_party/blink/web_tests/platform/mac-mac10.14/",
1429 "//third_party/blink/web_tests/platform/mac-mac10.15/",
Jonathan Leedbea4d4d2022-05-25 15:35:091430 "//third_party/blink/web_tests/platform/mac-mac11/",
Weizhong Xia53c492162021-09-09 17:08:241431 "//third_party/blink/web_tests/platform/mac-mac11-arm64/",
Jonathan Leedbea4d4d2022-05-25 15:35:091432 "//third_party/blink/web_tests/platform/mac-mac12-arm64/",
Weizhong Xia53c492162021-09-09 17:08:241433 ]
1434 }
1435
1436 # flag-specific tests only runs on linux as of now
1437 if (is_linux) {
1438 data += [
1439 "//third_party/blink/web_tests/FlagSpecificConfig",
1440 "//third_party/blink/web_tests/FlagExpectations/",
1441 "//third_party/blink/web_tests/flag-specific/",
1442 ]
1443 }
Kai Ninomiyafb9e5962020-03-17 06:11:381444 }
1445
Weizhong Xia8b786422022-06-23 14:46:511446 script_test("blink_wpt_tests") {
1447 script = _common_web_test_script
1448
1449 args = _common_web_test_args
1450
Weizhong Xia904cdf562022-08-25 02:00:331451 # Use --wpt-only to skip tests under web_tests/virtual/
1452 args += [ "--wpt-only" ]
1453
Weizhong Xia8b786422022-06-23 14:46:511454 data_deps = [ ":blink_web_tests_support_data" ]
1455 data = [
1456 "//third_party/blink/perf_tests/",
1457 "//third_party/blink/web_tests/SmokeTests/Default.txt",
1458 "//third_party/blink/web_tests/VirtualTestSuites",
1459
1460 # List all test expectations here
1461 "//third_party/blink/web_tests/ASANExpectations",
1462 "//third_party/blink/web_tests/LeakExpectations",
1463 "//third_party/blink/web_tests/MSANExpectations",
1464 "//third_party/blink/web_tests/NeverFixTests",
1465 "//third_party/blink/web_tests/SlowTests",
1466 "//third_party/blink/web_tests/StaleTestExpectations",
1467 "//third_party/blink/web_tests/TestExpectations",
1468 "//third_party/blink/web_tests/WebDriverExpectations",
1469 "//third_party/blink/web_tests/WebGPUExpectations",
1470
Weizhong Xia8b786422022-06-23 14:46:511471 # === List Test Cases folders here ===
1472 "//third_party/blink/web_tests/external/",
1473 "//third_party/blink/web_tests/wpt_internal/",
Weizhong Xia904cdf562022-08-25 02:00:331474 "//third_party/blink/web_tests/virtual/",
Weizhong Xia8b786422022-06-23 14:46:511475
1476 # === Test Case Folders Ends ===
1477 ]
1478
1479 if (is_win || is_linux || is_fuchsia) {
1480 data += [
1481 "//third_party/blink/web_tests/platform/win/",
1482 "//third_party/blink/web_tests/platform/win10/",
Weizhong Xia8b786422022-06-23 14:46:511483 ]
1484 if (is_linux || is_fuchsia) {
1485 data += [ "//third_party/blink/web_tests/platform/linux/" ]
1486 }
1487 if (is_fuchsia) {
1488 data += [ "//third_party/blink/web_tests/platform/fuchsia/" ]
1489 }
1490 } else if (is_mac) {
1491 data += [
1492 "//third_party/blink/web_tests/SmokeTests/Mac.txt",
1493 "//third_party/blink/web_tests/platform/mac/",
1494 "//third_party/blink/web_tests/platform/mac-mac10.13/",
1495 "//third_party/blink/web_tests/platform/mac-mac10.14/",
1496 "//third_party/blink/web_tests/platform/mac-mac10.15/",
1497 "//third_party/blink/web_tests/platform/mac-mac11-arm64/",
1498 ]
1499 }
1500
1501 # flag-specific tests only runs on linux as of now
1502 if (is_linux) {
1503 data += [
1504 "//third_party/blink/web_tests/FlagSpecificConfig",
1505 "//third_party/blink/web_tests/FlagExpectations/",
1506 "//third_party/blink/web_tests/flag-specific/",
1507 ]
1508 }
1509 }
1510
Dirk Pranke67bc5a9d2020-10-09 16:33:481511 script_test("devtools_web_tests") {
1512 # This target differs from :blink_web_tests in that it uses the
1513 # same test harness but runs an entirely different set of tests
1514 # and doesn't have a dependency on the web_test directory at all.
1515 script = _common_web_test_script
Kai Ninomiyafb9e5962020-03-17 06:11:381516
Dirk Pranke67bc5a9d2020-10-09 16:33:481517 args = _common_web_test_args + [
Patrick Brossetf30adff2020-10-12 18:33:321518 "--layout-tests-directory=@WrappedPath(" + rebase_path(
Dirk Pranke67bc5a9d2020-10-09 16:33:481519 "//third_party/devtools-frontend/src/test/webtests",
1520 root_out_dir) + ")",
1521 "http/tests/devtools",
1522 ]
Kai Ninomiyafb9e5962020-03-17 06:11:381523
Dirk Pranke67bc5a9d2020-10-09 16:33:481524 data_deps = [ ":blink_web_tests_support_data" ]
1525 data = [ "//third_party/devtools-frontend/src/test/webtests/" ]
1526 }
1527
1528 script_test("webgpu_blink_web_tests") {
1529 # This target differs from :blink_web_tests in that it uses the same
1530 # test harness and a few additional flags but, more importantly, only runs
1531 # the web_tests/wpt_internal/webgpu tests, so it doesn't have a data
Austin Eng2cddb7752022-06-09 02:40:291532 # dependency on the whole web_test directory.
Dirk Pranke67bc5a9d2020-10-09 16:33:481533 script = _common_web_test_script
Austin Eng4beb5d62021-03-24 16:29:591534
Austin Eng2cddb7752022-06-09 02:40:291535 args = _common_web_test_args
Austin Eng8e638d92021-04-02 17:08:081536 if (is_asan) {
Weizhong Xia91b53362022-01-05 17:13:351537 args += [ "--timeout-ms=30000" ]
Austin Eng8e638d92021-04-02 17:08:081538 }
Austin Eng4beb5d62021-03-24 16:29:591539 args += [
Austin Eng2cddb7752022-06-09 02:40:291540 "--ignore-default-expectations",
1541 "--additional-expectations",
Austin Eng4beb5d62021-03-24 16:29:591542 "@WrappedPath(../../third_party/blink/web_tests/WebGPUExpectations)",
Austin Eng2cddb7752022-06-09 02:40:291543 "--isolated-script-test-filter=wpt_internal/webgpu/web_platform/reftests/*",
Austin Eng4beb5d62021-03-24 16:29:591544 ]
Kai Ninomiyafb9e5962020-03-17 06:11:381545
Austin Eng32e07032021-03-18 16:30:101546 data_deps = [
1547 ":blink_web_tests_support_data",
1548 "//third_party/webgpu-cts",
1549 ]
Kai Ninomiyafb9e5962020-03-17 06:11:381550 data = [
Weizhong Xiad8a66332022-07-30 00:34:201551 "//third_party/blink/web_tests/external/wpt/common/",
1552 "//third_party/blink/web_tests/external/wpt/resources/",
Brian Sheedy10ddf0a2021-08-16 23:19:071553 "//third_party/blink/web_tests/FlagSpecificConfig",
Weizhong Xiad8a66332022-07-30 00:34:201554 "//third_party/blink/web_tests/VirtualTestSuites",
Kai Ninomiyafb9e5962020-03-17 06:11:381555 "//third_party/blink/web_tests/WebGPUExpectations",
Weizhong Xia64ec8c22022-06-24 03:39:341556 "//third_party/blink/web_tests/wpt_internal/",
Austin Eng4beb5d62021-03-24 16:29:591557 "//third_party/webgpu-cts/scripts/",
Kai Ninomiyafb9e5962020-03-17 06:11:381558 ]
1559 }
1560
yzshena0646992017-04-02 22:01:271561 copy("layout_test_data_mojo_bindings") {
1562 testonly = true
1563
Nico Weber77da4942020-01-13 20:13:351564 sources = [ "$root_gen_dir/mojo/public/js/mojo_bindings.js" ]
yzshena0646992017-04-02 22:01:271565
Nico Weber77da4942020-01-13 20:13:351566 outputs =
1567 [ "$root_gen_dir/layout_test_data/mojo/public/js/mojo_bindings.js" ]
yzshena0646992017-04-02 22:01:271568
Nico Weber77da4942020-01-13 20:13:351569 deps = [ "//mojo/public/js:bindings" ]
yzshena0646992017-04-02 22:01:271570 }
Dirk Pranke43a5c812017-09-06 03:25:411571
Ken Rockot86d360462018-10-24 02:50:091572 copy("layout_test_data_mojo_bindings_lite") {
1573 testonly = true
1574
Nico Weber77da4942020-01-13 20:13:351575 sources = [ "$root_gen_dir/mojo/public/js/mojo_bindings_lite.js" ]
Ken Rockot86d360462018-10-24 02:50:091576
1577 outputs = [
1578 "$root_gen_dir/layout_test_data/mojo/public/js/mojo_bindings_lite.js",
1579 ]
1580
Nico Weber77da4942020-01-13 20:13:351581 deps = [ "//mojo/public/js:bindings_lite" ]
Ken Rockot86d360462018-10-24 02:50:091582 }
1583
Dirk Pranke6188075b2020-10-01 19:31:281584 script_test("blink_python_tests") {
1585 script = "//testing/scripts/run_isolated_script_test.py"
Jonathan Lee53676f22022-08-11 18:57:211586 args = [ "@WrappedPath(" +
1587 rebase_path("//third_party/blink/tools/run_blinkpy_tests.py",
1588 root_build_dir) + ")" ]
Dirk Pranke6188075b2020-10-01 19:31:281589
Dirk Pranke43a5c812017-09-06 03:25:411590 data = [
Andrew Grieve4c4cede2020-11-20 22:09:361591 # These tests use //build/android/devil_chromium.py even when !is_android,
1592 # so cannot use the helpers in //build/android (they assert(is_android)).
Dirk Pranke43a5c812017-09-06 03:25:411593 "//build/android/",
Andrew Grieve4c4cede2020-11-20 22:09:361594 "//build/gn_helpers.py",
1595 "//build/config/gclient_args.gni",
Brian Sheedy6bcba67d2022-02-23 23:45:111596 "//build/skia_gold_common/",
Dirk Pranke43a5c812017-09-06 03:25:411597 "//components/crash/content/tools/generate_breakpad_symbols.py",
Brian Sheedyfe26b942021-08-05 16:00:501598 "//testing/unexpected_passes_common/",
Kent Tamura968e76912018-04-17 23:05:571599 "//third_party/blink/renderer/bindings/scripts/",
1600 "//third_party/blink/renderer/build/scripts/",
Dirk Pranke43a5c812017-09-06 03:25:411601 "//third_party/blink/tools/",
Kent Tamura77578cc2018-11-25 22:33:431602 "//third_party/blink/web_tests/ASANExpectations",
1603 "//third_party/blink/web_tests/LeakExpectations",
1604 "//third_party/blink/web_tests/MSANExpectations",
1605 "//third_party/blink/web_tests/NeverFixTests",
1606 "//third_party/blink/web_tests/SlowTests",
1607 "//third_party/blink/web_tests/StaleTestExpectations",
1608 "//third_party/blink/web_tests/TestExpectations",
1609 "//third_party/blink/web_tests/VirtualTestSuites",
Dirk Pranke43a5c812017-09-06 03:25:411610 "//third_party/catapult/common/py_utils/",
1611 "//third_party/catapult/devil/",
1612 "//third_party/catapult/dependency_manager/",
Ned Nguyenc335c432018-04-23 01:16:461613 "//third_party/catapult/third_party/typ/",
Mike Frysinger8f8404b2019-08-21 02:20:291614 "//third_party/depot_tools/pylint-1.5",
1615 "//third_party/depot_tools/pylint_main.py",
Dirk Pranke43a5c812017-09-06 03:25:411616 "//third_party/depot_tools/pylintrc",
Dirk Pranke43a5c812017-09-06 03:25:411617 "//third_party/ply/",
Jonathan Leeee7f45862022-08-02 00:13:021618 "//third_party/wpt_tools/",
Dirk Pranke43a5c812017-09-06 03:25:411619 "//tools/idl_parser/",
1620 ]
Brian Sheedy6bcba67d2022-02-23 23:45:111621
1622 data_deps = [ "//ui/base:goldctl" ]
Dirk Pranke43a5c812017-09-06 03:25:411623 }
tfarinacb2638b2015-05-12 03:24:151624}
1625
Will Cassella857c8d82022-04-12 15:01:051626# TODO(cassew): Add more OS's that don't support x86.
1627is_valid_x86_target =
1628 target_os != "ios" && target_os != "mac" &&
1629 (target_os != "linux" || use_libfuzzer || !build_with_chromium)
Michael Achenbachc4273962022-06-27 09:12:511630
1631# Note: v8_target_cpu == arm allows using the V8 arm simulator on x86 for fuzzing.
Will Cassella857c8d82022-04-12 15:01:051632assert(
Michael Achenbach1a7961012022-06-27 11:19:001633 is_valid_x86_target || target_cpu != "x86" || v8_target_cpu == "arm",
Will Cassella857c8d82022-04-12 15:01:051634 "'target_cpu=x86' is not supported for 'target_os=$target_os'. Consider omitting 'target_cpu' (default) or using 'target_cpu=x64' instead.")
1635
dpranke2302dfa2015-09-29 02:21:521636group("chromium_builder_perf") {
1637 testonly = true
1638
Ryan Keanea67d8022022-06-18 00:20:321639 if (!is_ios && !is_android && !is_castos) {
malets6b7062402016-09-15 08:14:261640 data_deps = [
dpranke2302dfa2015-09-29 02:21:521641 "//cc:cc_perftests",
dpranke2302dfa2015-09-29 02:21:521642 "//chrome/test:load_library_perf_tests",
Emily Hanleyedab9e52018-01-17 18:47:321643 "//chrome/test:performance_test_suite",
kraynovc0797582016-10-25 16:45:061644 "//components/tracing:tracing_perftests",
Antoine Labourc6ade252017-10-19 01:01:161645 "//gpu:command_buffer_perftests",
dpranke2302dfa2015-09-29 02:21:521646 "//gpu:gpu_perftests",
1647 "//media:media_perftests",
kbr1e58e782016-05-27 17:21:191648 "//tools/perf/chrome_telemetry_build:telemetry_chrome_test",
dpranke2302dfa2015-09-29 02:21:521649 ]
1650
Yuta Hijikata05f38002020-12-17 00:49:241651 if (!is_chromeos_ash) {
malets6b7062402016-09-15 08:14:261652 data_deps += [ "//chrome/test:performance_browser_tests" ]
dpranke2302dfa2015-09-29 02:21:521653 }
dpranke2302dfa2015-09-29 02:21:521654
Ryan Keanea67d8022022-06-18 00:20:321655 if (!is_win) {
Mark Mentovaiebb9ddd62017-09-25 17:24:411656 data_deps +=
1657 [ "//third_party/breakpad:minidump_stackwalk($host_toolchain)" ]
dpranke2302dfa2015-09-29 02:21:521658 }
Ryan Keanea67d8022022-06-18 00:20:321659 }
1660
1661 if ((is_linux && !is_castos) || is_chromeos_lacros) {
1662 if (is_official_build) {
1663 # In GN builds, this is controlled by the 'linux_dump_symbols'
1664 # flag, which defaults to 1 for official builds. For now,
1665 # we skip the separate flag and just key off of is_official_build.
1666 data_deps += [ "//chrome:linux_symbols" ]
Yuly Novikov8a6e6352017-11-11 02:00:401667 }
David Dorwin0b132172022-03-30 04:56:111668
Ryan Keanea67d8022022-06-18 00:20:321669 data_deps += [ "//tools/perf/clear_system_cache" ]
1670 }
1671
1672 if (is_win) {
1673 data_deps += [
1674 "//chrome/installer/mini_installer:mini_installer",
1675 "//components:components_perftests",
1676 "//third_party/angle/src/tests:angle_perftests",
1677 ]
1678 }
1679
1680 # An `if (is_fuchsia)` condition in //chrome/test/BUILD.gn prevents this
1681 # target from being defined.
1682 # TODO(crbug.com/1310086): Resolve that and remove this exception.
1683 if (is_fuchsia) {
1684 data_deps -= [ "//chrome/test:performance_test_suite" ]
dpranke2302dfa2015-09-29 02:21:521685 }
1686}
agrieve017b91f2016-02-29 20:15:061687
Ryan Keanea67d8022022-06-18 00:20:321688if (!is_ios && !is_android && !is_castos) {
thakis3f7d4fc2016-06-10 18:47:501689 group("chromium_builder_asan") {
1690 testonly = true
1691
1692 deps = [
1693 "//chrome:chrome",
1694 "//content/shell:content_shell",
Adrian Taylore6288432021-09-09 22:59:501695 "//third_party/blink/public/mojom:mojom_modules_js",
thakis3f7d4fc2016-06-10 18:47:501696 "//v8:d8",
1697 ]
1698 if (!is_win) {
Eric Orthdd5b8632020-11-13 02:59:421699 deps += [ "//skia:filter_fuzz_stub" ]
thakis3f7d4fc2016-06-10 18:47:501700 }
1701 if (enable_ipc_fuzzer && !is_component_build) {
Ken Rockotf87b01cf2018-12-26 06:52:261702 deps += [ "//tools/ipc_fuzzer:ipc_fuzzer_all" ]
thakis3f7d4fc2016-06-10 18:47:501703 }
Yuta Hijikata05f38002020-12-17 00:49:241704 if (!is_chromeos_ash) {
thakis3f7d4fc2016-06-10 18:47:501705 deps += [
1706 "//third_party/pdfium/samples:pdfium_test",
dpranke8a2de902016-07-14 20:08:371707 "//v8:v8_shell($v8_snapshot_toolchain)",
thakis3f7d4fc2016-06-10 18:47:501708 ]
1709 }
Max Moroz109e76b2020-02-10 17:19:521710
1711 if (!is_component_build) {
1712 # See https://bugs.chromium.org/p/chromium/issues/detail?id=942546#c11.
1713 deps += [
1714 "//third_party/webrtc/rtc_tools:rtp_generator",
1715 "//third_party/webrtc/rtc_tools:video_replay",
1716 ]
1717 }
Alastair Donaldson308bb212021-09-14 20:50:271718
1719 if (build_dawn_tests) {
Ryan Harrison2ec610f2022-04-02 02:30:241720 deps += [ "//third_party/dawn/src/tint/fuzzers:fuzzers" ]
Alastair Donaldson308bb212021-09-14 20:50:271721 }
thakis3f7d4fc2016-06-10 18:47:501722 }
1723}
1724
agrieve95ba4442016-04-25 15:47:131725if (is_android) {
1726 group("optimize_gn_gen") {
1727 deps = [
1728 # These run expensive scripts in non-default toolchains. Generally, host
1729 # toolchain targets are loaded in the later part of the run, and the
1730 # result is they push out the end of generation. By preloading these, the
1731 # scripts can be parallelized with the rest of the load.
1732 "//build/config/linux(//build/toolchain/linux:clang_x64)",
1733 "//build/config/posix(//build/toolchain/linux:clang_x64)",
1734
1735 # Include x86 toolchains as well since V8 uses them for 32-bit snapshot
1736 # generation.
1737 "//build/config/linux(//build/toolchain/linux:clang_x86)",
1738 "//build/config/posix(//build/toolchain/linux:clang_x86)",
1739 ]
1740 }
1741}
1742
Mirko Bonadeif17649c2020-06-18 21:36:291743if (enable_js_type_check) {
Christopher Lam739a90d2018-03-07 03:54:371744 group("webui_closure_compile") {
Trent Apted572ba7552018-10-17 00:03:301745 testonly = true
Christopher Lam739a90d2018-03-07 03:54:371746 data_deps = [
Reilly Grant2c3893d2019-10-29 20:11:421747 "components/neterror/resources:closure_compile",
dpapada750ecba2022-02-23 04:29:341748 "components/security_interstitials:closure_compile",
Christopher Lam76610802019-01-14 03:37:241749 "mojo/public/tools/bindings/generators/js_templates/lite/test:closure_compile",
1750 "ui/webui/resources:closure_compile",
Christopher Lam739a90d2018-03-07 03:54:371751 ]
Yuta Hijikata05f38002020-12-17 00:49:241752 if (is_chromeos_ash) {
Josh Nohlea2263fa2019-08-29 19:17:061753 data_deps += [
Yeunjoo Choi9b62f1a2021-06-23 13:17:001754 "ash/webui:closure_compile",
Josh Nohlea2263fa2019-08-29 19:17:061755 "ui/file_manager:closure_compile",
1756 ]
Christopher Lamb97769322018-04-26 01:47:491757 }
Daniel Nicoaracf98a1bf2022-08-09 19:51:441758 if (!is_castos) {
1759 data_deps += [
1760 "chrome/browser/resources:closure_compile",
1761 "chrome/test:closure_compile",
1762 ]
1763 }
Christopher Lam739a90d2018-03-07 03:54:371764 }
1765}
1766
Andrew Grievefebea022020-08-07 17:17:531767# Write debug logs to gn_logs.txt.
1768_lines = [
1769 "Generated during 'gn gen' by //BUILD.gn.",
1770 "",
1771 ] + build_gn_logs
1772
1773# GN evaluates each .gn file once per toolchain, so restricting to default
1774# toolchain will ensure write_file() is called only once.
1775assert(current_toolchain == default_toolchain)
1776
1777write_file("$root_build_dir/gn_logs.txt", _lines)