Revert r196089 "Add default values for Latin script font prefs."
[chromium-blink-merge.git] / chrome / chrome_tests.gypi
blobffd4d10ecdef3a02d560cb4c6d5dd2b0163ea319
1 # Copyright 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
5   'variables' : {
6     'pyautolib_sources': [
7       'app/chrome_command_ids.h',
8       'app/chrome_dll_resource.h',
9       'common/automation_constants.h',
10       'common/pref_names.cc',
11       'common/pref_names.h',
12       'browser/chromeos/cros/network_constants.h',
13       'test/automation/browser_proxy.cc',
14       'test/automation/browser_proxy.h',
15       'test/automation/tab_proxy.cc',
16       'test/automation/tab_proxy.h',
17       '../content/public/common/page_type.h',
18       '../content/public/common/security_style.h',
19       # Must come before cert_status_flags.h
20       '../net/base/net_export.h',
21       '../net/cert/cert_status_flags.h',
22     ],
23     'conditions': [
24       ['asan==1', {
25         'pyautolib_sources': [
26           'test/pyautolib/asan_stub.c',
27         ]
28       }],
29     ],
30   },
31   'includes': [
32     'js_unittest_vars.gypi',
33   ],
34   'targets': [
35     {
36       'target_name': 'test_support_ui',
37       'type': 'static_library',
38       'dependencies': [
39         'chrome_resources.gyp:chrome_resources',
40         'chrome_resources.gyp:chrome_strings',
41         'chrome_resources.gyp:theme_resources',
42         'test_support_common',
43         '../skia/skia.gyp:skia',
44         '../testing/gtest.gyp:gtest',
45       ],
46       'export_dependent_settings': [
47         'test_support_common',
48       ],
49       'include_dirs': [
50         '..',
51       ],
52       'sources': [
53         'test/automation/proxy_launcher.cc',
54         'test/automation/proxy_launcher.h',
55         'test/reliability/automated_ui_test_base.cc',
56         'test/reliability/automated_ui_test_base.h',
57         'test/ui/javascript_test_util.cc',
58         'test/ui/run_all_unittests.cc',
59         'test/ui/ui_perf_test.cc',
60         'test/ui/ui_perf_test.h',
61         'test/ui/ui_test.cc',
62         'test/ui/ui_test.h',
63         'test/ui/ui_test_suite.cc',
64         'test/ui/ui_test_suite.h',
65       ],
66       'conditions': [
67         ['OS=="win"', {
68           'dependencies': [
69             'chrome.gyp:crash_service',  # run time dependency
70           ],
71         }],
72         ['OS=="win" and target_arch=="ia32"', {
73           'dependencies': [
74             'chrome.gyp:crash_service_win64',  # run time dependency
75           ],
76         }],
77         ['toolkit_uses_gtk == 1', {
78           'dependencies': [
79             '../build/linux/system.gyp:gtk',
80           ],
81         }],
82       ],
83       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
84       'msvs_disabled_warnings': [ 4267, ],
85     },
86     {
87       'target_name': 'automated_ui_tests',
88       'type': 'executable',
89       'dependencies': [
90         'browser',
91         'chrome_resources.gyp:theme_resources',
92         'renderer',
93         'test_support_common',
94         'test_support_ui',
95         '../base/base.gyp:base',
96         '../skia/skia.gyp:skia',
97         '../third_party/libxml/libxml.gyp:libxml',
98         '../testing/gtest.gyp:gtest',
99       ],
100       'include_dirs': [
101         '..',
102       ],
103       'sources': [
104         'test/reliability/automated_ui_tests.cc',
105         'test/reliability/automated_ui_tests.h',
106       ],
107       'conditions': [
108         ['OS=="win" and buildtype=="Official"', {
109           'configurations': {
110             'Release': {
111               'msvs_settings': {
112                 'VCCLCompilerTool': {
113                   'WholeProgramOptimization': 'false',
114                 },
115               },
116             },
117           },
118         },],
119         ['use_x11==1', {
120           'dependencies': [
121             '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
122           ],
123         }],
124         ['OS=="win"', {
125           'dependencies': [
126             'automated_ui_tests_exe_pdb_workaround',
127           ],
128           'include_dirs': [
129             '<(DEPTH)/third_party/wtl/include',
130           ],
131           'conditions': [
132             ['win_use_allocator_shim==1', {
133               'dependencies': [
134                 '<(allocator_target)',
135               ],
136             }],
137           ],
138         }],
139         ['OS=="linux" and enable_webrtc==1', {
140           'dependencies': [
141             # TODO(tommi): Figure out why the 32bit lucid builder fails to
142             # find this dependency for this target (other builders pick it up
143             # correctly).  crbug.com/231068.
144             '../third_party/libjingle/libjingle.gyp:libpeerconnection',
145           ],
146         }],
147       ],
148     },
149     {
150       'target_name': 'interactive_ui_tests',
151       'type': 'executable',
152       'dependencies': [
153         'browser',
154         'chrome_resources.gyp:chrome_resources',
155         'chrome_resources.gyp:chrome_strings',
156         'chrome_resources.gyp:packed_extra_resources',
157         'chrome_resources.gyp:packed_resources',
158         'common/extensions/api/api.gyp:api',
159         'debugger',
160         'renderer',
161         'test_support_common',
162         # NOTE: don't add test_support_ui, no more UITests. See
163         # http://crbug.com/137365
164         '../third_party/hunspell/hunspell.gyp:hunspell',
165         '../net/net.gyp:net',
166         '../net/net.gyp:net_resources',
167         '../net/net.gyp:net_test_support',
168         '../skia/skia.gyp:skia',
169         '../sync/sync.gyp:sync',
170         '../third_party/icu/icu.gyp:icui18n',
171         '../third_party/icu/icu.gyp:icuuc',
172         '../third_party/libpng/libpng.gyp:libpng',
173         '../third_party/zlib/zlib.gyp:zlib',
174         '../testing/gmock.gyp:gmock',
175         '../testing/gtest.gyp:gtest',
176         '../third_party/npapi/npapi.gyp:npapi',
177         # Runtime dependencies
178         '../ppapi/ppapi_internal.gyp:ppapi_tests',
179         '../ui/web_dialogs/web_dialogs.gyp:web_dialogs_test_support',
180         '../webkit/support/webkit_support.gyp:webkit_resources',
181       ],
182       'include_dirs': [
183         '..',
184       ],
185       'defines': [
186         'HAS_OUT_OF_PROC_TEST_RUNNER',
187         'INTERACTIVE_TESTS',
188       ],
189       'sources': [
190         'browser/autofill/autofill_interactive_uitest.cc',
191         'browser/browser_keyevents_browsertest.cc',
192         'browser/extensions/api/omnibox/omnibox_api_interactive_test.cc',
193         'browser/extensions/api/tabs/tabs_interactive_test.cc',
194         'browser/extensions/extension_apitest.cc',
195         'browser/extensions/extension_browsertest.cc',
196         'browser/extensions/extension_crash_recovery_browsertest.cc',
197         'browser/extensions/extension_function_test_utils.cc',
198         'browser/extensions/extension_keybinding_apitest.cc',
199         'browser/extensions/extension_test_message_listener.cc',
200         'browser/extensions/extension_test_message_listener.h',
201         'browser/extensions/notifications_apitest.cc',
202         'browser/extensions/platform_app_browsertest_util.cc',
203         'browser/extensions/platform_app_browsertest_util.h',
204         'browser/extensions/web_view_interactive_browsertest.cc',
205         'browser/extensions/window_open_interactive_apitest.cc',
206         'browser/extensions/extension_fullscreen_apitest.cc',
207         'browser/extensions/extension_pointer_lock_apitest.cc',
208         'browser/mouseleave_browsertest.cc',
209         'browser/notifications/desktop_notifications_unittest.cc',
210         'browser/notifications/desktop_notifications_unittest.h',
211         'browser/notifications/notification_browsertest.cc',
212         'browser/printing/print_dialog_cloud_interative_uitest.cc',
213         'browser/profiles/incognito_selection_clipboard_uitest.cc',
214         'browser/task_manager/task_manager_browsertest_util.cc',
215         'browser/ui/app_modal_dialogs/javascript_dialog_interactive_uitest.cc',
216         'browser/ui/browser_focus_uitest.cc',
217         'browser/ui/cocoa/panels/panel_cocoa_browsertest.mm',
218         'browser/ui/find_bar/find_bar_interactive_uitest.cc',
219         'browser/ui/fullscreen/fullscreen_controller_interactive_browsertest.cc',
220         'browser/ui/fullscreen/fullscreen_controller_state_interactive_browsertest.cc',
221         'browser/ui/gtk/bookmarks/bookmark_bar_gtk_interactive_uitest.cc',
222         'browser/ui/omnibox/action_box_browsertest.cc',
223         'browser/ui/omnibox/omnibox_view_browsertest.cc',
224         'browser/ui/panels/base_panel_browser_test.cc',
225         'browser/ui/panels/base_panel_browser_test.h',
226         'browser/ui/panels/detached_panel_browsertest.cc',
227         'browser/ui/panels/docked_panel_browsertest.cc',
228         'browser/ui/panels/panel_browsertest.cc',
229         'browser/ui/panels/panel_drag_browsertest.cc',
230         'browser/ui/panels/panel_resize_browsertest.cc',
231         'browser/ui/panels/stacked_panel_browsertest.cc',
232         'browser/ui/panels/test_panel_active_state_observer.cc',
233         'browser/ui/panels/test_panel_active_state_observer.h',
234         'browser/ui/panels/test_panel_mouse_watcher.cc',
235         'browser/ui/panels/test_panel_mouse_watcher.h',
236         'browser/ui/panels/test_panel_notification_observer.cc',
237         'browser/ui/panels/test_panel_notification_observer.h',
238         'browser/ui/panels/test_panel_collection_squeeze_observer.cc',
239         'browser/ui/panels/test_panel_collection_squeeze_observer.h',
240         'browser/ui/search/instant_extended_interactive_uitest.cc',
241         'browser/ui/search/instant_extended_manual_interactive_uitest.cc',
242         'browser/ui/search/instant_test_utils.h',
243         'browser/ui/search/instant_test_utils.cc',
244         'browser/ui/startup/startup_browser_creator_interactive_uitest.cc',
245         'browser/ui/views/ash/tab_scrubber_browsertest.cc',
246         'browser/ui/views/bookmarks/bookmark_bar_view_test.cc',
247         'browser/ui/views/button_dropdown_test.cc',
248         'browser/ui/views/constrained_window_views_browsertest.cc',
249         'browser/ui/views/find_bar_controller_interactive_uitest.cc',
250         'browser/ui/views/find_bar_host_interactive_uitest.cc',
251         'browser/ui/views/frame/browser_view_interactive_uitest.cc',
252         'browser/ui/views/keyboard_access_browsertest.cc',
253         'browser/ui/views/location_bar/star_view_browsertest.cc',
254         'browser/ui/views/menu_item_view_test.cc',
255         'browser/ui/views/menu_model_adapter_test.cc',
256         'browser/ui/views/message_center/web_notification_tray_win_browsertest.cc',
257         'browser/ui/views/native_widget_win_interactive_uitest.cc',
258         'browser/ui/views/omnibox/omnibox_view_views_browsertest.cc',
259         'browser/ui/views/panels/panel_view_browsertest.cc',
260         'browser/ui/views/ssl_client_certificate_selector_browsertest.cc',
261         'browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc',
262         'browser/ui/views/tabs/tab_drag_controller_interactive_uitest.h',
263         'browser/ui/views/tabs/tab_drag_controller_interactive_uitest_win.cc',
264         'test/base/chrome_test_launcher.cc',
265         'test/base/interactive_test_utils.cc',
266         'test/base/interactive_test_utils.h',
267         'test/base/interactive_test_utils_aura.cc',
268         'test/base/interactive_test_utils_aura.h',
269         'test/base/interactive_test_utils_gtk.cc',
270         'test/base/interactive_test_utils_mac.mm',
271         'test/base/interactive_test_utils_views.cc',
272         'test/base/interactive_test_utils_win.cc',
273         'test/base/view_event_test_base.cc',
274         'test/base/view_event_test_base.h',
275         'test/base/ui_controls.h',
276         'test/base/ui_controls_ash.cc',
277         'test/base/ui_controls_aura.h',
278         'test/base/ui_controls_aura.cc',
279         'test/base/ui_controls_aurawin.cc',
280         'test/base/ui_controls_aurax11.cc',
281         'test/base/ui_controls_gtk.cc',
282         'test/base/ui_controls_internal_win.cc',
283         'test/base/ui_controls_internal_win.h',
284         'test/base/ui_controls_mac.mm',
285         'test/base/ui_controls_win.cc',
286         'test/ppapi/ppapi_interactive_browsertest.cc',
287       ],
288       'conditions': [
289         ['use_x11==1', {
290           'dependencies': [
291             '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
292           ],
293         }],
294         ['toolkit_uses_gtk == 1', {
295           'dependencies': [
296             '../build/linux/system.gyp:gtk',
297           ],
298           'sources!': [
299             'browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc',
300           ],
301         }],
302         ['toolkit_uses_gtk == 1 or chromeos==1 or (OS=="linux" and use_aura==1)', {
303           'dependencies': [
304             '../build/linux/system.gyp:ssl',
305           ],
306         }],
307         ['toolkit_uses_gtk == 1 and toolkit_views == 0', {
308           'sources!': [
309             # TODO(port)
310             'browser/ui/views/bookmarks/bookmark_bar_view_test.cc',
311             'browser/ui/views/button_dropdown_test.cc',
312             'browser/ui/views/constrained_window_views_browsertest.cc',
313             'browser/ui/views/crypto_module_password_dialog_view_unittest.cc',
314             'browser/ui/views/find_bar_host_interactive_uitest.cc',
315             'browser/ui/views/keyboard_access_browsertest.cc',
316             'browser/ui/views/menu_item_view_test.cc',
317             'browser/ui/views/menu_model_adapter_test.cc',
318             'test/base/view_event_test_base.cc',
319             'test/base/view_event_test_base.h',
320           ],
321         }],
322         ['OS=="linux" and toolkit_views==1', {
323           'sources!': [
324             # TODO(port)
325             'browser/ui/gtk/bookmarks/bookmark_bar_gtk_interactive_uitest.cc',
326           ],
327         }],
328         ['OS=="mac"', {
329           'sources!': [
330             # TODO(port)
331             'browser/ui/views/bookmarks/bookmark_bar_view_test.cc',
332             'browser/ui/views/button_dropdown_test.cc',
333             'browser/ui/views/constrained_window_views_browsertest.cc',
334             'browser/ui/views/find_bar_host_interactive_uitest.cc',
335             'browser/ui/views/keyboard_access_browsertest.cc',
336             'browser/ui/views/menu_item_view_test.cc',
337             'browser/ui/views/menu_model_adapter_test.cc',
338             'browser/ui/views/tabs/tab_drag_controller_interactive_uitest.cc',
339             'test/base/view_event_test_base.cc',
340             'test/base/view_event_test_base.h',
341           ],
342           'dependencies': [
343             'chrome'
344           ],
345           # See comment about the same line in chrome/chrome_tests.gypi.
346           'xcode_settings': {'OTHER_LDFLAGS': ['-Wl,-ObjC']},
347         }],  # OS=="mac"
348         ['notifications==0', {
349           'sources/': [
350             ['exclude', '^browser/notifications/'],
351             ['exclude', '^browser/extensions/notifications_apitest.cc'],
352           ],
353         }],
354         ['toolkit_views==1', {
355           'dependencies': [
356             '../ui/views/views.gyp:views',
357             '../ui/views/views.gyp:views_test_support',
358           ],
359         }, { # else: toolkit_views == 0
360           'sources/': [
361             ['exclude', '^browser/ui/views/'],
362           ],
363         }],
364         ['use_ash==1', {
365           'dependencies': [
366             '../ash/ash.gyp:ash_test_support',
367           ],
368         }],
369         ['use_aura==1', {
370           'sources!': [
371             'browser/ui/views/tabs/tab_drag_controller_interactive_uitest_win.cc',
372             'test/base/ui_controls_win.cc',
373           ],
374         }],
375         ['chromeos==1', {
376           'dependencies': [
377             '../chromeos/chromeos.gyp:chromeos',
378           ],
379           'sources': [
380             'browser/chromeos/cros/cros_in_process_browser_test.cc',
381             'browser/chromeos/cros/cros_in_process_browser_test.h',
382             'browser/chromeos/cros/cros_mock.cc',
383             'browser/chromeos/cros/cros_mock.h',
384             'browser/chromeos/input_method/textinput_browsertest.cc',
385             'browser/chromeos/input_method/textinput_surroundingtext_browsertest.cc',
386             'browser/chromeos/input_method/textinput_test_helper.cc',
387             'browser/chromeos/input_method/textinput_test_helper.h',
388             'browser/chromeos/login/login_browsertest.cc',
389             'browser/chromeos/login/mock_authenticator.cc',
390             'browser/chromeos/login/mock_authenticator.h',
391             'browser/chromeos/login/oobe_browsertest.cc',
392             'browser/chromeos/login/screen_locker_browsertest.cc',
393             'browser/chromeos/login/screen_locker_tester.cc',
394             'browser/chromeos/login/screen_locker_tester.h',
395             'browser/chromeos/login/wallpaper_manager_browsertest.cc',
396             'test/data/chromeos/service_login.html',
397           ],
398           'sources!': [
399             # chromeos does not use cross-platform panels
400             'browser/ui/panels/detached_panel_browsertest.cc',
401             'browser/ui/panels/docked_panel_browsertest.cc',
402             'browser/ui/panels/panel_browsertest.cc',
403             'browser/ui/panels/panel_drag_browsertest.cc',
404             'browser/ui/panels/panel_resize_browsertest.cc',
405             'browser/ui/views/panels/panel_view_browsertest.cc',
406             'browser/notifications/desktop_notifications_unittest.cc',
407           ],
408         }],
409         ['OS=="win"', {
410           'include_dirs': [
411             '../third_party/wtl/include',
412           ],
413           'dependencies': [
414             'chrome.gyp:chrome_version_resources',
415             '../third_party/isimpledom/isimpledom.gyp:isimpledom',
416             '../ui/ui.gyp:ui_resources',
417           ],
418           'sources': [
419             '../ui/resources/cursors/aliasb.cur',
420             '../ui/resources/cursors/cell.cur',
421             '../ui/resources/cursors/col_resize.cur',
422             '../ui/resources/cursors/copy.cur',
423             '../ui/resources/cursors/none.cur',
424             '../ui/resources/cursors/row_resize.cur',
425             '../ui/resources/cursors/vertical_text.cur',
426             '../ui/resources/cursors/zoom_in.cur',
427             '../ui/resources/cursors/zoom_out.cur',
429             'app/chrome_dll.rc',
430             'test/data/resource.rc',
432             # TODO:  It would be nice to have these pulled in
433             # automatically from direct_dependent_settings in
434             # their various targets (net.gyp:net_resources, etc.),
435             # but that causes errors in other targets when
436             # resulting .res files get referenced multiple times.
437             '<(SHARED_INTERMEDIATE_DIR)/chrome/browser_resources.rc',
438             '<(SHARED_INTERMEDIATE_DIR)/chrome/chrome_unscaled_resources.rc',
439             '<(SHARED_INTERMEDIATE_DIR)/chrome/common_resources.rc',
440             '<(SHARED_INTERMEDIATE_DIR)/chrome/extensions_api_resources.rc',
441             '<(SHARED_INTERMEDIATE_DIR)/chrome_version/other_version.rc',
442             '<(SHARED_INTERMEDIATE_DIR)/content/content_resources.rc',
443             '<(SHARED_INTERMEDIATE_DIR)/net/net_resources.rc',
444             '<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources/ui_unscaled_resources.rc',
445             '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_chromium_resources.rc',
447             'browser/ui/views/accessibility/browser_views_accessibility_browsertest.cc',
448           ],
449           'conditions': [
450             ['win_use_allocator_shim==1', {
451               'dependencies': [
452                  '../base/allocator/allocator.gyp:allocator',
453               ],
454             }],
455             ['use_aura==1', {
456               'sources/': [
457                 ['exclude', '^browser/ui/views/accessibility/browser_views_accessibility_browsertest.cc'],
458                 ['exclude', '^browser/ui/views/native_widget_win_interactive_uitest.cc'],
459               ],
460             }],
461           ],
462           'msvs_settings': {
463             'VCLinkerTool': {
464               'conditions': [
465                 ['incremental_chrome_dll==1', {
466                   'UseLibraryDependencyInputs': "true",
467                 }],
468               ],
469             },
470           },
471           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
472           'msvs_disabled_warnings': [ 4267, ],
473         }, { # else: OS != "win"
474           'sources!': [
475             'browser/ui/views/ssl_client_certificate_selector_browsertest.cc',
476             'browser/ui/views/message_center/web_notification_tray_win_browsertest.cc',
477             'browser/ui/views/native_widget_win_interactive_uitest.cc',
478           ],
479         }],  # OS != "win"
480         ['enable_message_center==0', {
481           'sources!': [
482             'browser/ui/views/message_center/web_notification_tray_win_browsertest.cc',
483           ],
484         }],  # enable_message_center
485       ],  # conditions
486     },
487     {
488       # Third-party support sources for chromedriver_lib.
489       'target_name': 'chromedriver_support',
490       'type': 'static_library',
491       'sources': [
492         '../third_party/mongoose/mongoose.c',
493         '../third_party/mongoose/mongoose.h',
494         '../third_party/webdriver/atoms.cc',
495         '../third_party/webdriver/atoms.h',
496       ],
497       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
498       # Although this one is probably safe to ignore.
499       # Mongose casts -1 directly as HANDLE (definitely safe to ignore).
500       'msvs_disabled_warnings': [4267, 4306, ],
501    },
502     {
503       # chromedriver is the chromium implementation of WebDriver.
504       # See http://www.chromium.org/developers/testing/webdriver-for-chrome
505       'target_name': 'chromedriver_lib',
506       'type': 'static_library',
507       'dependencies': [
508         'browser',
509         'chrome',
510         'chrome_resources.gyp:chrome_resources',
511         'chrome_resources.gyp:chrome_strings',
512         'chromedriver_support',
513         'common',
514         'test_support_ui',
515         '../base/base.gyp:base',
516         '../build/temp_gyp/googleurl.gyp:googleurl',
517         '../net/net.gyp:net',
518         '../skia/skia.gyp:skia',
519         '../sync/sync.gyp:sync',
520         '../testing/gtest.gyp:gtest',
521         '../third_party/icu/icu.gyp:icui18n',
522         '../third_party/icu/icu.gyp:icuuc',
523         '../third_party/libxml/libxml.gyp:libxml',
524       ],
525       'include_dirs': [
526         '..',
527       ],
528       'sources': [
529         'test/webdriver/commands/alert_commands.cc',
530         'test/webdriver/commands/alert_commands.h',
531         'test/webdriver/commands/appcache_status_command.cc',
532         'test/webdriver/commands/appcache_status_command.h',
533         'test/webdriver/commands/browser_connection_commands.cc',
534         'test/webdriver/commands/browser_connection_commands.h',
535         'test/webdriver/commands/chrome_commands.cc',
536         'test/webdriver/commands/chrome_commands.h',
537         'test/webdriver/commands/command.cc',
538         'test/webdriver/commands/command.h',
539         'test/webdriver/commands/cookie_commands.cc',
540         'test/webdriver/commands/cookie_commands.h',
541         'test/webdriver/commands/create_session.cc',
542         'test/webdriver/commands/create_session.h',
543         'test/webdriver/commands/execute_async_script_command.cc',
544         'test/webdriver/commands/execute_async_script_command.h',
545         'test/webdriver/commands/execute_command.cc',
546         'test/webdriver/commands/execute_command.h',
547         'test/webdriver/commands/file_upload_command.cc',
548         'test/webdriver/commands/file_upload_command.h',
549         'test/webdriver/commands/find_element_commands.cc',
550         'test/webdriver/commands/find_element_commands.h',
551         'test/webdriver/commands/html5_location_commands.cc',
552         'test/webdriver/commands/html5_location_commands.h',
553         'test/webdriver/commands/html5_storage_commands.cc',
554         'test/webdriver/commands/html5_storage_commands.h',
555         'test/webdriver/commands/keys_command.cc',
556         'test/webdriver/commands/keys_command.h',
557         'test/webdriver/commands/log_command.cc',
558         'test/webdriver/commands/log_command.h',
559         'test/webdriver/commands/navigate_commands.cc',
560         'test/webdriver/commands/navigate_commands.h',
561         'test/webdriver/commands/mouse_commands.cc',
562         'test/webdriver/commands/mouse_commands.h',
563         'test/webdriver/commands/response.h',
564         'test/webdriver/commands/response.cc',
565         'test/webdriver/commands/screenshot_command.cc',
566         'test/webdriver/commands/screenshot_command.h',
567         'test/webdriver/commands/session_with_id.cc',
568         'test/webdriver/commands/session_with_id.h',
569         'test/webdriver/commands/set_timeout_commands.cc',
570         'test/webdriver/commands/set_timeout_commands.h',
571         'test/webdriver/commands/source_command.cc',
572         'test/webdriver/commands/source_command.h',
573         'test/webdriver/commands/target_locator_commands.cc',
574         'test/webdriver/commands/target_locator_commands.h',
575         'test/webdriver/commands/title_command.cc',
576         'test/webdriver/commands/title_command.h',
577         'test/webdriver/commands/url_command.cc',
578         'test/webdriver/commands/url_command.h',
579         'test/webdriver/commands/webdriver_command.cc',
580         'test/webdriver/commands/webdriver_command.h',
581         'test/webdriver/commands/webelement_commands.cc',
582         'test/webdriver/commands/webelement_commands.h',
583         'test/webdriver/commands/window_commands.cc',
584         'test/webdriver/commands/window_commands.h',
585         'test/webdriver/frame_path.cc',
586         'test/webdriver/frame_path.h',
587         'test/webdriver/http_response.cc',
588         'test/webdriver/http_response.h',
589         'test/webdriver/keycode_text_conversion.h',
590         'test/webdriver/keycode_text_conversion_gtk.cc',
591         'test/webdriver/keycode_text_conversion_mac.mm',
592         'test/webdriver/keycode_text_conversion_win.cc',
593         'test/webdriver/keycode_text_conversion_x.cc',
594         'test/webdriver/webdriver_automation.cc',
595         'test/webdriver/webdriver_automation.h',
596         'test/webdriver/webdriver_basic_types.cc',
597         'test/webdriver/webdriver_basic_types.h',
598         'test/webdriver/webdriver_capabilities_parser.cc',
599         'test/webdriver/webdriver_capabilities_parser.h',
600         'test/webdriver/webdriver_dispatch.cc',
601         'test/webdriver/webdriver_dispatch.h',
602         'test/webdriver/webdriver_element_id.cc',
603         'test/webdriver/webdriver_element_id.h',
604         'test/webdriver/webdriver_error.cc',
605         'test/webdriver/webdriver_error.h',
606         'test/webdriver/webdriver_key_converter.cc',
607         'test/webdriver/webdriver_key_converter.h',
608         'test/webdriver/webdriver_logging.cc',
609         'test/webdriver/webdriver_logging.h',
610         'test/webdriver/webdriver_session.cc',
611         'test/webdriver/webdriver_session.h',
612         'test/webdriver/webdriver_session_manager.cc',
613         'test/webdriver/webdriver_session_manager.h',
614         'test/webdriver/webdriver_switches.cc',
615         'test/webdriver/webdriver_switches.h',
616         'test/webdriver/webdriver_util.cc',
617         'test/webdriver/webdriver_util.h',
618         'test/webdriver/webdriver_util_mac.mm',
619       ],
620       'conditions': [
621         ['use_x11==1', {
622           'dependencies': [
623             '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
624           ],
625         }],
626         ['toolkit_uses_gtk == 1', {
627           'dependencies': [
628             '../build/linux/system.gyp:gtk',
629           ],
630           'sources!': [
631             'test/webdriver/keycode_text_conversion_x.cc',
632           ],
633         }],
634         ['toolkit_uses_gtk == 0', {
635           'sources!': [
636             'test/webdriver/keycode_text_conversion_gtk.cc',
637           ],
638         }],
639         ['OS=="linux" and toolkit_views==1', {
640           'dependencies': [
641             '../ui/views/views.gyp:views',
642           ],
643         }],
644         ['os_posix == 1 and OS != "mac" and OS != "android"', {
645           'conditions': [
646             ['linux_use_tcmalloc==1', {
647               'dependencies': [
648                 '../base/allocator/allocator.gyp:allocator',
649               ],
650             }],
651           ],
652         }],
653       ],
654     },
655     {
656       'target_name': 'chromedriver',
657       'type': 'executable',
658       'dependencies': [
659         'chromedriver_lib',
660         '../base/base.gyp:base',
661         '../skia/skia.gyp:skia',
662         '../testing/gtest.gyp:gtest',
663       ],
664       'include_dirs': [
665         '..',
666       ],
667       'sources': [
668         'test/webdriver/webdriver_server.cc',
669       ],
670       'conditions': [
671         ['OS=="win"', {
672           'conditions': [
673             ['win_use_allocator_shim==1', {
674               'dependencies': [
675                 '<(allocator_target)',
676               ],
677             }],
678           ],
679           'link_settings': {
680             'libraries': [
681               '-lOleAcc.lib',
682               '-lws2_32.lib',
683             ],
684           },
685           'configurations': {
686             'Debug': {
687               'msvs_settings': {
688                 'VCLinkerTool': {
689                   'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
690                 },
691               },
692             },
693           },
694         }],
695       ]
696     },
697     {
698       'target_name': 'chromedriver_unittests',
699       'type': 'executable',
700       'dependencies': [
701         'chromedriver_lib',
702         '../base/base.gyp:run_all_unittests',
703         '../base/base.gyp:test_support_base',
704         '../testing/gtest.gyp:gtest',
705         '../skia/skia.gyp:skia',
706       ],
707       'include_dirs': [
708         '..',
709       ],
710       'sources': [
711         'test/webdriver/commands/set_timeout_commands_unittest.cc',
712         'test/webdriver/frame_path_unittest.cc',
713         'test/webdriver/http_response_unittest.cc',
714         'test/webdriver/keycode_text_conversion_unittest.cc',
715         'test/webdriver/webdriver_capabilities_parser_unittest.cc',
716         'test/webdriver/webdriver_dispatch_unittest.cc',
717         'test/webdriver/webdriver_key_converter_unittest.cc',
718         'test/webdriver/webdriver_test_util.cc',
719         'test/webdriver/webdriver_test_util.h',
720         'test/webdriver/webdriver_util_unittest.cc',
721       ],
722       'conditions': [
723         ['OS=="win"', {
724           'conditions': [
725             ['win_use_allocator_shim==1', {
726               'dependencies': [
727                 '<(allocator_target)',
728               ],
729             }],
730           ],
731           'link_settings': {
732             'libraries': [
733               '-lOleAcc.lib',
734               '-lws2_32.lib',
735             ],
736           },
737           'configurations': {
738             'Debug': {
739               'msvs_settings': {
740                 'VCLinkerTool': {
741                   'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
742                 },
743               },
744             },
745           },
746           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
747           'msvs_disabled_warnings': [ 4267, ],
748         }],
749       ],
750     },
751     {
752       'target_name': 'chrome_devtools_lib',
753       'type': 'static_library',
754       'hard_dependency': 1,
755       'dependencies': [
756         '../base/base.gyp:base',
757         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
758         '../build/temp_gyp/googleurl.gyp:googleurl',
759         '../net/net.gyp:net',
760         '../third_party/zlib/zlib.gyp:minizip',
761         '../third_party/zlib/zlib.gyp:zlib',
762         '../ui/ui.gyp:ui',
763       ],
764       'include_dirs': [
765         '..',
766         '<(SHARED_INTERMEDIATE_DIR)',
767       ],
768       'direct_dependent_settings': {
769         'include_dirs': [
770           '<(SHARED_INTERMEDIATE_DIR)',
771         ],
772       },
773       'sources': [
774         '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/js.cc',
775         '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/js.h',
776         '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/user_data_dir.cc',
777         '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/user_data_dir.h',
778         '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/embedded_automation_extension.cc',
779         '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/embedded_automation_extension.h',
780         'test/chromedriver/chrome/automation_extension.cc',
781         'test/chromedriver/chrome/automation_extension.h',
782         'test/chromedriver/chrome/chrome.h',
783         'test/chromedriver/chrome/chrome_android_impl.cc',
784         'test/chromedriver/chrome/chrome_android_impl.h',
785         'test/chromedriver/chrome/chrome_desktop_impl.cc',
786         'test/chromedriver/chrome/chrome_desktop_impl.h',
787         'test/chromedriver/chrome/chrome_finder.cc',
788         'test/chromedriver/chrome/chrome_finder.h',
789         'test/chromedriver/chrome/chrome_finder_mac.mm',
790         'test/chromedriver/chrome/chrome_impl.cc',
791         'test/chromedriver/chrome/chrome_impl.h',
792         'test/chromedriver/chrome/console_logger.h',
793         'test/chromedriver/chrome/console_logger.cc',
794         'test/chromedriver/chrome/devtools_client.cc',
795         'test/chromedriver/chrome/devtools_client.h',
796         'test/chromedriver/chrome/devtools_client_impl.cc',
797         'test/chromedriver/chrome/devtools_client_impl.h',
798         'test/chromedriver/chrome/devtools_event_listener.h',
799         'test/chromedriver/chrome/devtools_http_client.cc',
800         'test/chromedriver/chrome/devtools_http_client.h',
801         'test/chromedriver/chrome/dom_tracker.cc',
802         'test/chromedriver/chrome/dom_tracker.h',
803         'test/chromedriver/chrome/frame_tracker.cc',
804         'test/chromedriver/chrome/frame_tracker.h',
805         'test/chromedriver/chrome/geolocation_override_manager.cc',
806         'test/chromedriver/chrome/geolocation_override_manager.h',
807         'test/chromedriver/chrome/geoposition.h',
808         'test/chromedriver/chrome/javascript_dialog_manager.cc',
809         'test/chromedriver/chrome/javascript_dialog_manager.h',
810         'test/chromedriver/chrome/log.h',
811         'test/chromedriver/chrome/log.cc',
812         'test/chromedriver/chrome/navigation_tracker.cc',
813         'test/chromedriver/chrome/navigation_tracker.h',
814         'test/chromedriver/chrome/performance_logger.h',
815         'test/chromedriver/chrome/performance_logger.cc',
816         'test/chromedriver/chrome/status.cc',
817         'test/chromedriver/chrome/status.h',
818         'test/chromedriver/chrome/ui_events.cc',
819         'test/chromedriver/chrome/ui_events.h',
820         'test/chromedriver/chrome/version.cc',
821         'test/chromedriver/chrome/version.h',
822         'test/chromedriver/chrome/web_view.h',
823         'test/chromedriver/chrome/web_view_impl.cc',
824         'test/chromedriver/chrome/web_view_impl.h',
825         'test/chromedriver/chrome/zip.cc',
826         'test/chromedriver/chrome/zip.h',
827         'test/chromedriver/chrome/zip_internal.cc',
828         'test/chromedriver/chrome/zip_internal.h',
829         'test/chromedriver/chrome/zip_reader.cc',
830         'test/chromedriver/chrome/zip_reader.h',
831         'test/chromedriver/net/net_util.cc',
832         'test/chromedriver/net/net_util.h',
833         'test/chromedriver/net/sync_websocket.h',
834         'test/chromedriver/net/sync_websocket_factory.cc',
835         'test/chromedriver/net/sync_websocket_factory.h',
836         'test/chromedriver/net/sync_websocket_impl.cc',
837         'test/chromedriver/net/sync_websocket_impl.h',
838         'test/chromedriver/net/url_request_context_getter.cc',
839         'test/chromedriver/net/url_request_context_getter.h',
840         'test/chromedriver/net/websocket.cc',
841         'test/chromedriver/net/websocket.h',
842       ],
843       'actions': [
844         {
845           'action_name': 'embed_js_in_cpp',
846           'inputs': [
847             'test/chromedriver/cpp_source.py',
848             'test/chromedriver/embed_js_in_cpp.py',
849             'test/chromedriver/js/add_cookie.js',
850             'test/chromedriver/js/call_function.js',
851             'test/chromedriver/js/execute_async_script.js',
852             'test/chromedriver/js/focus.js',
853             'test/chromedriver/js/get_element_region.js',
854             'test/chromedriver/js/is_option_element_toggleable.js',
855           ],
856           'outputs': [
857             '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/js.cc',
858             '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/js.h',
859           ],
860           'action': [ 'python',
861                       'test/chromedriver/embed_js_in_cpp.py',
862                       '--directory',
863                       '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome',
864                       'test/chromedriver/js/add_cookie.js',
865                       'test/chromedriver/js/call_function.js',
866                       'test/chromedriver/js/execute_async_script.js',
867                       'test/chromedriver/js/focus.js',
868                       'test/chromedriver/js/get_element_region.js',
869                       'test/chromedriver/js/is_option_element_toggleable.js',
870           ],
871           'message': 'Generating sources for embedding js in chromedriver',
872         },
873         {
874           'action_name': 'embed_user_data_dir_in_cpp',
875           'inputs': [
876             'test/chromedriver/cpp_source.py',
877             'test/chromedriver/embed_user_data_dir_in_cpp.py',
878             'test/chromedriver/chrome/preferences.txt',
879             'test/chromedriver/chrome/local_state.txt',
880           ],
881           'outputs': [
882             '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/user_data_dir.cc',
883             '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/user_data_dir.h',
884           ],
885           'action': [ 'python',
886                       'test/chromedriver/embed_user_data_dir_in_cpp.py',
887                       '--directory',
888                       '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome',
889                       'test/chromedriver/chrome/preferences.txt',
890                       'test/chromedriver/chrome/local_state.txt',
891           ],
892           'message': 'Generating sources for embedding user data dir in chromedriver',
893         },
894         {
895           'action_name': 'embed_extension_in_cpp',
896           'inputs': [
897             'test/chromedriver/cpp_source.py',
898             'test/chromedriver/embed_extension_in_cpp.py',
899             'test/chromedriver/extension/background.js',
900             'test/chromedriver/extension/manifest.json',
901           ],
902           'outputs': [
903             '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/embedded_automation_extension.cc',
904             '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome/embedded_automation_extension.h',
905           ],
906           'action': [ 'python',
907                       'test/chromedriver/embed_extension_in_cpp.py',
908                       '--directory',
909                       '<(SHARED_INTERMEDIATE_DIR)/chrome/test/chromedriver/chrome',
910                       'test/chromedriver/extension/background.js',
911                       'test/chromedriver/extension/manifest.json',
912           ],
913           'message': 'Generating sources for embedding automation extension',
914         },
915       ],
916       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
917       'msvs_disabled_warnings': [ 4267, ],
918     },
919     {
920       'target_name': 'chromedriver2_lib',
921       'type': 'static_library',
922       'dependencies': [
923         'chrome_devtools_lib',
924         '../base/base.gyp:base',
925         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
926         '../net/net.gyp:net',
927         '../ui/ui.gyp:ui',
928       ],
929       'include_dirs': [
930         '..',
931       ],
932       'sources': [
933         '../third_party/webdriver/atoms.cc',
934         '../third_party/webdriver/atoms.h',
935         'test/chromedriver/basic_types.cc',
936         'test/chromedriver/basic_types.h',
937         'test/chromedriver/capabilities.cc',
938         'test/chromedriver/capabilities.h',
939         'test/chromedriver/chrome_launcher.cc',
940         'test/chromedriver/chrome_launcher.h',
941         'test/chromedriver/chromedriver.cc',
942         'test/chromedriver/chromedriver.h',
943         'test/chromedriver/command.h',
944         'test/chromedriver/command_executor.h',
945         'test/chromedriver/command_executor_impl.cc',
946         'test/chromedriver/command_executor_impl.h',
947         'test/chromedriver/command_names.cc',
948         'test/chromedriver/command_names.h',
949         'test/chromedriver/commands.cc',
950         'test/chromedriver/commands.h',
951         'test/chromedriver/element_commands.cc',
952         'test/chromedriver/element_commands.h',
953         'test/chromedriver/element_util.cc',
954         'test/chromedriver/element_util.h',
955         'test/chromedriver/key_converter.cc',
956         'test/chromedriver/key_converter.h',
957         'test/chromedriver/keycode_text_conversion.h',
958         'test/chromedriver/keycode_text_conversion_mac.mm',
959         'test/chromedriver/keycode_text_conversion_win.cc',
960         'test/chromedriver/keycode_text_conversion_x.cc',
961         'test/chromedriver/logging.cc',
962         'test/chromedriver/logging.h',
963         'test/chromedriver/session.cc',
964         'test/chromedriver/session.h',
965         'test/chromedriver/session_commands.cc',
966         'test/chromedriver/session_commands.h',
967         'test/chromedriver/session_map.h',
968         'test/chromedriver/synchronized_map.h',
969         'test/chromedriver/util.cc',
970         'test/chromedriver/util.h',
971         'test/chromedriver/window_commands.cc',
972         'test/chromedriver/window_commands.h',
973       ],
974       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
975       'msvs_disabled_warnings': [ 4267, ],
976     },
977     # This is the new ChromeDriver based on DevTools.
978     {
979       'target_name': 'chromedriver2',
980       'type': 'loadable_module',
981       'dependencies': [
982         'chromedriver2_lib',
983         '../base/base.gyp:base',
984       ],
985       'include_dirs': [
986         '..',
987       ],
988       'sources': [
989         'test/chromedriver/chromedriver_shared_library.cc',
990       ],
991       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
992       'msvs_disabled_warnings': [ 4267, ],
993     },
994     {
995       'target_name': 'chromedriver2_server_lib',
996       'type': 'static_library',
997       'dependencies': [
998         'chromedriver2_lib',
999         '../base/base.gyp:base',
1000       ],
1001       'include_dirs': [
1002         '..',
1003       ],
1004       'sources': [
1005         'test/chromedriver/server/http_handler.cc',
1006         'test/chromedriver/server/http_handler.h',
1007         'test/chromedriver/server/http_response.cc',
1008         'test/chromedriver/server/http_response.h',
1009       ],
1010       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1011       'msvs_disabled_warnings': [ 4267, ],
1012     },
1013     {
1014       'target_name': 'chromedriver2_server',
1015       'type': 'executable',
1016       'dependencies': [
1017         'chromedriver2_server_lib',
1018       ],
1019       'include_dirs': [
1020         '..',
1021       ],
1022       'sources': [
1023         '../third_party/mongoose/mongoose.c',
1024         '../third_party/mongoose/mongoose.h',
1025         'test/chromedriver/server/chromedriver_server.cc',
1026       ],
1027       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1028       # c4306 is because Mongoose casts -1 directly to a handle type.
1029       'msvs_disabled_warnings': [ 4306, 4267, ],
1030     },
1031     {
1032       'target_name': 'chromedriver2_unittests',
1033       'type': 'executable',
1034       'dependencies': [
1035         'chromedriver2_lib',
1036         'chromedriver2_server_lib',
1037         '../base/base.gyp:base',
1038         '../base/base.gyp:run_all_unittests',
1039         '../testing/gtest.gyp:gtest',
1040         '../ui/ui.gyp:ui',
1041       ],
1042       'sources': [
1043         'test/chromedriver/capabilities_unittest.cc',
1044         'test/chromedriver/chrome/chrome_finder_unittest.cc',
1045         'test/chromedriver/chrome/console_logger_unittest.cc',
1046         'test/chromedriver/chrome/devtools_client_impl_unittest.cc',
1047         'test/chromedriver/chrome/devtools_http_client_unittest.cc',
1048         'test/chromedriver/chrome/dom_tracker_unittest.cc',
1049         'test/chromedriver/chrome/frame_tracker_unittest.cc',
1050         'test/chromedriver/chrome/geolocation_override_manager_unittest.cc',
1051         'test/chromedriver/chrome/javascript_dialog_manager_unittest.cc',
1052         'test/chromedriver/chrome/navigation_tracker_unittest.cc',
1053         'test/chromedriver/chrome/performance_logger_unittest.cc',
1054         'test/chromedriver/chrome/status_unittest.cc',
1055         'test/chromedriver/chrome/stub_chrome.cc',
1056         'test/chromedriver/chrome/stub_chrome.h',
1057         'test/chromedriver/chrome/stub_devtools_client.cc',
1058         'test/chromedriver/chrome/stub_devtools_client.h',
1059         'test/chromedriver/chrome/stub_web_view.cc',
1060         'test/chromedriver/chrome/stub_web_view.h',
1061         'test/chromedriver/chrome/web_view_impl_unittest.cc',
1062         'test/chromedriver/chrome_launcher_unittest.cc',
1063         'test/chromedriver/chromedriver_unittest.cc',
1064         'test/chromedriver/command_executor_impl_unittest.cc',
1065         'test/chromedriver/commands_unittest.cc',
1066         'test/chromedriver/fake_session_accessor.cc',
1067         'test/chromedriver/fake_session_accessor.h',
1068         'test/chromedriver/logging_unittest.cc',
1069         'test/chromedriver/server/http_handler_unittest.cc',
1070         'test/chromedriver/server/http_response_unittest.cc',
1071         'test/chromedriver/session_commands_unittest.cc',
1072         'test/chromedriver/session_unittest.cc',
1073         'test/chromedriver/synchronized_map_unittest.cc',
1074         'test/chromedriver/util_unittest.cc',
1075       ],
1076     },
1077     # ChromeDriver2 tests that aren't run on the main buildbot. Available
1078     # as an optional test type on trybots.
1079     {
1080       'target_name': 'chromedriver2_tests',
1081       'type': 'executable',
1082       'dependencies': [
1083         'chromedriver2_lib',
1084         '../base/base.gyp:base',
1085         '../base/base.gyp:run_all_unittests',
1086         '../build/temp_gyp/googleurl.gyp:googleurl',
1087         '../net/net.gyp:http_server',
1088         '../net/net.gyp:net',
1089         '../net/net.gyp:net_test_support',
1090         '../testing/gtest.gyp:gtest',
1091       ],
1092       'include_dirs': [
1093         '..,'
1094       ],
1095       'sources': [
1096         'test/chromedriver/key_converter_unittest.cc',
1097         'test/chromedriver/keycode_text_conversion_unittest.cc',
1098         'test/chromedriver/net/net_util_unittest.cc',
1099         'test/chromedriver/net/sync_websocket_impl_unittest.cc',
1100         'test/chromedriver/net/test_http_server.cc',
1101         'test/chromedriver/net/test_http_server.h',
1102         'test/chromedriver/net/websocket_unittest.cc',
1103         'test/chromedriver/test_util.cc',
1104         'test/chromedriver/test_util.h',
1105       ],
1106       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
1107       'msvs_disabled_warnings': [ 4267, ],
1108     },
1109     {
1110       # Executable that runs each browser test in a new process.
1111       'target_name': 'browser_tests',
1112       'type': 'executable',
1113       'msvs_cygwin_shell': 0,
1114       'msvs_cygwin_dirs': ['<(DEPTH)/third_party/cygwin'],
1115       'dependencies': [
1116         'browser',
1117         'chrome_resources.gyp:chrome_resources',
1118         'chrome_resources.gyp:chrome_strings',
1119         'chrome_resources.gyp:packed_extra_resources',
1120         'chrome_resources.gyp:packed_resources',
1121         'common/extensions/api/api.gyp:api',
1122         'renderer',
1123         'test_support_common',
1124         '../base/base.gyp:base',
1125         '../base/base.gyp:base_i18n',
1126         '../base/base.gyp:test_support_base',
1127         '../components/components.gyp:autofill_risk_proto',
1128         '../device/device.gyp:device_bluetooth_mocks',
1129         '../net/net.gyp:net',
1130         '../net/net.gyp:net_test_support',
1131         '../skia/skia.gyp:skia',
1132         '../sync/sync.gyp:sync',
1133         '../sync/sync.gyp:test_support_sync_api',
1134         '../testing/gmock.gyp:gmock',
1135         '../testing/gtest.gyp:gtest',
1136         '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation',
1137         '../third_party/cld/cld.gyp:cld',
1138         '../third_party/icu/icu.gyp:icui18n',
1139         '../third_party/icu/icu.gyp:icuuc',
1140         '../third_party/leveldatabase/leveldatabase.gyp:leveldatabase',
1141         '../third_party/safe_browsing/safe_browsing.gyp:safe_browsing',
1142         '../ui/web_dialogs/web_dialogs.gyp:web_dialogs_test_support',
1143         '../v8/tools/gyp/v8.gyp:v8',
1144         '../webkit/webkit.gyp:test_shell_test_support',
1145         # Runtime dependencies
1146         '../ppapi/ppapi_internal.gyp:ppapi_tests',
1147         '../third_party/mesa/mesa.gyp:osmesa',
1148       ],
1149       'include_dirs': [
1150         '..',
1151       ],
1152       'defines': [
1153         'HAS_OUT_OF_PROC_TEST_RUNNER',
1154       ],
1155       'sources': [
1156         '../apps/app_restore_service_browsertest.cc',
1157         'app/breakpad_mac_stubs.mm',
1158         'app/chrome_command_ids.h',
1159         'app/chrome_dll.rc',
1160         'app/chrome_dll_resource.h',
1161         'app/chrome_version.rc.version',
1162         'browser/accessibility/accessibility_extension_apitest.cc',
1163         'browser/accessibility/browser_accessibility_state_browsertest.cc',
1164         'browser/app_controller_mac_browsertest.mm',
1165         'browser/autocomplete/autocomplete_browsertest.cc',
1166         'browser/autofill/autofill_browsertest.cc',
1167         'browser/autofill/autofill_external_delegate_browsertest.cc',
1168         'browser/autofill/form_structure_browsertest.cc',
1169         'browser/autofill/risk/fingerprint_browsertest.cc',
1170         'browser/automation/automation_misc_browsertest.cc',
1171         'browser/automation/automation_tab_helper_browsertest.cc',
1172         'browser/browser_encoding_browsertest.cc',
1173         'browser/browsing_data/browsing_data_database_helper_browsertest.cc',
1174         'browser/browsing_data/browsing_data_helper_browsertest.h',
1175         'browser/browsing_data/browsing_data_indexed_db_helper_browsertest.cc',
1176         'browser/browsing_data/browsing_data_local_storage_helper_browsertest.cc',
1177         'browser/browsing_data/browsing_data_remover_browsertest.cc',
1178         'browser/captive_portal/captive_portal_browsertest.cc',
1179         'browser/chrome_content_browser_client_browsertest.cc',
1180         'browser/chrome_main_browsertest.cc',
1181         'browser/chrome_plugin_browsertest.cc',
1182         'browser/chrome_security_exploit_browsertest.cc',
1183         'browser/chrome_switches_browsertest.cc',
1184         'browser/chromeos/accessibility/magnification_manager_browsertest.cc',
1185         'browser/chromeos/app_mode/kiosk_app_manager_browsertest.cc',
1186         'browser/chromeos/cros/cros_in_process_browser_test.cc',
1187         'browser/chromeos/cros/cros_in_process_browser_test.h',
1188         'browser/chromeos/cros/cros_mock.cc',
1189         'browser/chromeos/cros/cros_mock.h',
1190         'browser/chromeos/drive/drive_system_service_browsertest.cc',
1191         'browser/chromeos/drive/test_util.cc',
1192         'browser/chromeos/drive/test_util.h',
1193         'browser/chromeos/extensions/echo_private_apitest.cc',
1194         'browser/chromeos/extensions/file_manager/drive_test_util.cc',
1195         'browser/chromeos/extensions/file_manager/drive_test_util.h',
1196         'browser/chromeos/extensions/file_manager/external_filesystem_apitest.cc',
1197         'browser/chromeos/extensions/file_manager/file_browser_handler_api_test.cc',
1198         'browser/chromeos/extensions/file_manager/file_browser_private_apitest.cc',
1199         'browser/chromeos/extensions/file_manager/file_manager_browsertest.cc',
1200         'browser/chromeos/extensions/file_manager/file_manager_event_router_browsertest.cc',
1201         'browser/chromeos/extensions/file_manager/file_manager_notifications_browsertest.cc',
1202         'browser/chromeos/extensions/info_private_apitest.cc',
1203         'browser/chromeos/extensions/input_method_apitest_chromeos.cc',
1204         'browser/chromeos/extensions/networking_private_apitest.cc',
1205         'browser/chromeos/extensions/wallpaper_private_apitest.cc',
1206         'browser/chromeos/input_method/input_method_engine_ibus_browserttests.cc',
1207         'browser/chromeos/kiosk_mode/mock_kiosk_mode_settings.cc',
1208         'browser/chromeos/kiosk_mode/mock_kiosk_mode_settings.h',
1209         'browser/chromeos/login/enrollment/enrollment_screen_browsertest.cc',
1210         'browser/chromeos/login/enrollment/mock_enrollment_screen.cc',
1211         'browser/chromeos/login/enrollment/mock_enrollment_screen.h',
1212         'browser/chromeos/login/existing_user_controller_browsertest.cc',
1213         'browser/chromeos/login/kiosk_browsertest.cc',
1214         'browser/chromeos/login/login_utils_browsertest.cc',
1215         'browser/chromeos/login/mock_authenticator.cc',
1216         'browser/chromeos/login/mock_authenticator.h',
1217         'browser/chromeos/login/screen_locker_tester.cc',
1218         'browser/chromeos/login/screen_locker_tester.h',
1219         'browser/chromeos/login/screens/mock_error_screen.cc',
1220         'browser/chromeos/login/screens/mock_error_screen.h',
1221         'browser/chromeos/login/screens/mock_eula_screen.cc',
1222         'browser/chromeos/login/screens/mock_eula_screen.h',
1223         'browser/chromeos/login/screens/mock_network_screen.cc',
1224         'browser/chromeos/login/screens/mock_network_screen.h',
1225         'browser/chromeos/login/screens/mock_screen_observer.cc',
1226         'browser/chromeos/login/screens/mock_screen_observer.h',
1227         'browser/chromeos/login/screens/mock_update_screen.cc',
1228         'browser/chromeos/login/screens/mock_update_screen.h',
1229         'browser/chromeos/login/screens/network_screen_browsertest.cc',
1230         'browser/chromeos/login/screens/update_screen_browsertest.cc',
1231         'browser/chromeos/login/test_login_utils.cc',
1232         'browser/chromeos/login/test_login_utils.h',
1233         'browser/chromeos/login/user_image_manager_browsertest.cc',
1234         'browser/chromeos/login/wizard_controller_browsertest.cc',
1235         'browser/chromeos/login/wizard_in_process_browser_test.cc',
1236         'browser/chromeos/login/wizard_in_process_browser_test.h',
1237         'browser/chromeos/media/media_player_browsertest.cc',
1238         'browser/chromeos/memory/oom_priority_manager_browsertest.cc',
1239         'browser/chromeos/policy/device_local_account_browsertest.cc',
1240         'browser/chromeos/policy/device_policy_cros_browser_test.cc',
1241         'browser/chromeos/policy/device_policy_cros_browser_test.h',
1242         'browser/chromeos/policy/device_status_collector_browsertest.cc',
1243         'browser/chromeos/policy/policy_cert_verifier_browsertest.cc',
1244         'browser/chromeos/policy/power_policy_browsertest.cc',
1245         'browser/chromeos/policy/variations_service_policy_browsertest.cc',
1246         'browser/chromeos/power/peripheral_battery_observer_browsertest.cc',
1247         'browser/chromeos/screensaver/screensaver_controller_browsertest.cc',
1248         'browser/chromeos/system/tray_accessibility_browsertest.cc',
1249         'browser/chromeos/ui/idle_logout_dialog_view_browsertest.cc',
1250         'browser/collected_cookies_browsertest.cc',
1251         'browser/content_settings/content_settings_browsertest.cc',
1252         'browser/crash_recovery_browsertest.cc',
1253         'browser/custom_handlers/protocol_handler_registry_browsertest.cc',
1254         'browser/devtools/devtools_sanity_browsertest.cc',
1255         'browser/do_not_track_browsertest.cc',
1256         'browser/download/download_browsertest.cc',
1257         'browser/download/download_danger_prompt_browsertest.cc',
1258         'browser/download/save_page_browsertest.cc',
1259         'browser/errorpage_browsertest.cc',
1260         'browser/extensions/active_tab_apitest.cc',
1261         'browser/extensions/activity_log_browsertest.cc',
1262         'browser/extensions/ad_view_browsertest.cc',
1263         'browser/extensions/alert_apitest.cc',
1264         'browser/extensions/all_urls_apitest.cc',
1265         'browser/extensions/api/app_window/app_window_apitest.cc',
1266         'browser/extensions/api/audio/audio_apitest.cc',
1267         'browser/extensions/api/autotest_private/autotest_private_apitest.cc',
1268         'browser/extensions/api/bluetooth/bluetooth_apitest.cc',
1269         'browser/extensions/api/bookmark_manager_private/bookmark_manager_private_apitest.cc',
1270         'browser/extensions/api/bookmarks/bookmark_apitest.cc',
1271         'browser/extensions/api/browsing_data/browsing_data_test.cc',
1272         'browser/extensions/api/cloud_print_private/cloud_print_private_apitest.cc',
1273         'browser/extensions/api/command_line_private/command_line_private_apitest.cc',
1274         'browser/extensions/api/commands/command_service_browsertest.cc',
1275         'browser/extensions/api/content_settings/content_settings_apitest.cc',
1276         'browser/extensions/api/context_menus/context_menu_apitest.cc',
1277         'browser/extensions/api/cookies/cookies_apitest.cc',
1278         'browser/extensions/api/debugger/debugger_apitest.cc',
1279         'browser/extensions/api/debugger/debugger_extension_apitest.cc',
1280         'browser/extensions/api/declarative/declarative_apitest.cc',
1281         'browser/extensions/api/declarative_content/declarative_content_apitest.cc',
1282         'browser/extensions/api/developer_private/developer_private_apitest.cc',
1283         'browser/extensions/api/dial/dial_apitest.cc',
1284         'browser/extensions/api/dns/dns_apitest.cc',
1285         'browser/extensions/api/dns/mock_host_resolver_creator.cc',
1286         'browser/extensions/api/dns/mock_host_resolver_creator.h',
1287         'browser/extensions/api/downloads/downloads_api_unittest.cc',
1288         'browser/extensions/api/extension_action/browser_action_apitest.cc',
1289         'browser/extensions/api/extension_action/page_action_apitest.cc',
1290         'browser/extensions/api/extension_action/page_as_browser_action_apitest.cc',
1291         'browser/extensions/api/extension_action/script_badge_apitest.cc',
1292         'browser/extensions/api/file_system/file_system_apitest.cc',
1293         'browser/extensions/api/font_settings/font_settings_apitest.cc',
1294         'browser/extensions/api/history/history_apitest.cc',
1295         'browser/extensions/api/i18n/i18n_apitest.cc',
1296         'browser/extensions/api/identity/experimental_identity_apitest.cc',
1297         'browser/extensions/api/identity/identity_apitest.cc',
1298         'browser/extensions/api/idle/idle_apitest.cc',
1299         'browser/extensions/api/idltest/idltest_apitest.cc',
1300         'browser/extensions/api/input/input_apitest.cc',
1301         'browser/extensions/api/input_ime/input_ime_apitest_chromeos.cc',
1302         'browser/extensions/api/managed_mode_private/managed_mode_apitest.cc',
1303         'browser/extensions/api/management/management_api_browsertest.cc',
1304         'browser/extensions/api/management/management_apitest.cc',
1305         'browser/extensions/api/management/management_browsertest.cc',
1306         'browser/extensions/api/media_galleries/media_galleries_apitest.cc',
1307         'browser/extensions/api/media_galleries_private/media_galleries_eject_apitest.cc',
1308         'browser/extensions/api/media_galleries_private/media_galleries_private_apitest.cc',
1309         'browser/extensions/api/media_galleries_private/media_galleries_watch_apitest.cc',
1310         'browser/extensions/api/messaging/native_messaging_apitest.cc',
1311         'browser/extensions/api/metrics_private/metrics_apitest.cc',
1312         'browser/extensions/api/module/module_apitest.cc',
1313         'browser/extensions/api/notifications/notifications_apitest.cc',
1314         'browser/extensions/api/omnibox/omnibox_api_browsertest.cc',
1315         'browser/extensions/api/page_capture/page_capture_apitest.cc',
1316         'browser/extensions/api/permissions/permissions_apitest.cc',
1317         'browser/extensions/api/preference/preference_apitest.cc',
1318         'browser/extensions/api/processes/processes_apitest.cc',
1319         'browser/extensions/api/proxy/proxy_apitest.cc',
1320         'browser/extensions/api/push_messaging/push_messaging_apitest.cc',
1321         'browser/extensions/api/push_messaging/push_messaging_canary_test.cc',
1322         'browser/extensions/api/push_messaging/sync_setup_helper.cc',
1323         'browser/extensions/api/record/record_api_test.cc',
1324         'browser/extensions/api/rtc_private/rtc_private_apitest.cc',
1325         'browser/extensions/api/runtime/runtime_apitest.cc',
1326         'browser/extensions/api/serial/serial_apitest.cc',
1327         'browser/extensions/api/session_restore/session_restore_apitest.cc',
1328         'browser/extensions/api/socket/socket_apitest.cc',
1329         'browser/extensions/api/storage/settings_apitest.cc',
1330         'browser/extensions/api/streams_private/streams_private_apitest.cc',
1331         'browser/extensions/api/sync_file_system/sync_file_system_apitest.cc',
1332         'browser/extensions/api/system_indicator/system_indicator_apitest.cc',
1333         'browser/extensions/api/system_info_cpu/system_info_cpu_apitest.cc',
1334         'browser/extensions/api/system_info_display/system_info_display_apitest.cc',
1335         'browser/extensions/api/system_info_memory/system_info_memory_apitest.cc',
1336         'browser/extensions/api/system_info_storage/system_info_storage_apitest.cc',
1337         'browser/extensions/api/tab_capture/tab_capture_apitest.cc',
1338         'browser/extensions/api/tabs/tabs_test.cc',
1339         'browser/extensions/api/terminal/terminal_private_apitest.cc',
1340         'browser/extensions/api/test/apitest_apitest.cc',
1341         'browser/extensions/api/top_sites/top_sites_apitest.cc',
1342         'browser/extensions/api/usb/usb_apitest.cc',
1343         'browser/extensions/api/web_navigation/web_navigation_apitest.cc',
1344         'browser/extensions/api/web_request/web_request_apitest.cc',
1345         'browser/extensions/api/web_socket_proxy_private/web_socket_proxy_private_apitest.cc',
1346         'browser/extensions/api/webstore_private/webstore_private_apitest.cc',
1347         'browser/extensions/app_background_page_apitest.cc',
1348         'browser/extensions/app_process_apitest.cc',
1349         'browser/extensions/background_page_apitest.cc',
1350         'browser/extensions/background_scripts_apitest.cc',
1351         'browser/extensions/chrome_app_api_browsertest.cc',
1352         'browser/extensions/content_script_apitest.cc',
1353         'browser/extensions/content_security_policy_apitest.cc',
1354         'browser/extensions/convert_web_app_browsertest.cc',
1355         'browser/extensions/crazy_extension_browsertest.cc',
1356         'browser/extensions/cross_origin_xhr_apitest.cc',
1357         'browser/extensions/crx_installer_browsertest.cc',
1358         'browser/extensions/docs/examples/apps/calculator_browsertest.cc',
1359         'browser/extensions/events_apitest.cc',
1360         'browser/extensions/execute_script_apitest.cc',
1361         'browser/extensions/extension_apitest.cc',
1362         'browser/extensions/extension_apitest.h',
1363         'browser/extensions/extension_bindings_apitest.cc',
1364         'browser/extensions/extension_blacklist_browsertest.cc',
1365         'browser/extensions/extension_browsertest.cc',
1366         'browser/extensions/extension_browsertest.h',
1367         'browser/extensions/extension_context_menu_browsertest.cc',
1368         'browser/extensions/extension_disabled_ui_browsertest.cc',
1369         'browser/extensions/extension_dom_clipboard_apitest.cc',
1370         'browser/extensions/extension_fileapi_apitest.cc',
1371         'browser/extensions/extension_functional_browsertest.cc',
1372         'browser/extensions/extension_function_test_utils.cc',
1373         'browser/extensions/extension_function_test_utils.h',
1374         'browser/extensions/extension_geolocation_apitest.cc',
1375         'browser/extensions/extension_get_views_apitest.cc',
1376         'browser/extensions/extension_icon_source_apitest.cc',
1377         'browser/extensions/extension_incognito_apitest.cc',
1378         'browser/extensions/extension_install_ui_browsertest.cc',
1379         'browser/extensions/extension_javascript_url_apitest.cc',
1380         'browser/extensions/extension_messages_apitest.cc',
1381         'browser/extensions/extension_override_apitest.cc',
1382         'browser/extensions/extension_resource_request_policy_apitest.cc',
1383         'browser/extensions/extension_startup_browsertest.cc',
1384         'browser/extensions/extension_storage_apitest.cc',
1385         'browser/extensions/extension_tabs_apitest.cc',
1386         'browser/extensions/extension_test_message_listener.cc',
1387         'browser/extensions/extension_test_message_listener.h',
1388         'browser/extensions/extension_toolbar_model_browsertest.cc',
1389         'browser/extensions/extension_url_rewrite_browsertest.cc',
1390         'browser/extensions/extension_websocket_apitest.cc',
1391         'browser/extensions/gpu_browsertest.cc',
1392         'browser/extensions/isolated_app_browsertest.cc',
1393         'browser/extensions/lazy_background_page_apitest.cc',
1394         'browser/extensions/lazy_background_page_test_util.h',
1395         'browser/extensions/load_and_launch_browsertest.cc',
1396         'browser/extensions/mutation_observers_apitest.cc',
1397         'browser/extensions/options_page_apitest.cc',
1398         'browser/extensions/page_action_browsertest.cc',
1399         'browser/extensions/platform_app_browsertest.cc',
1400         'browser/extensions/platform_app_browsertest_util.cc',
1401         'browser/extensions/platform_app_browsertest_util.h',
1402         'browser/extensions/plugin_apitest.cc',
1403         'browser/extensions/process_management_browsertest.cc',
1404         'browser/extensions/requirements_checker_browsertest.cc',
1405         'browser/extensions/sandboxed_pages_apitest.cc',
1406         'browser/extensions/shared_module_apitest.cc',
1407         'browser/extensions/startup_helper_browsertest.cc',
1408         'browser/extensions/stubs_apitest.cc',
1409         'browser/extensions/subscribe_page_action_browsertest.cc',
1410         'browser/extensions/api/system_private/system_private_apitest.cc',
1411         'browser/extensions/web_contents_browsertest.cc',
1412         'browser/extensions/web_view_browsertest.cc',
1413         'browser/extensions/webstore_startup_installer_browsertest.cc',
1414         'browser/extensions/window_open_apitest.cc',
1415         'browser/external_extension_browsertest.cc',
1416         'browser/fast_shutdown_browsertest.cc',
1417         'browser/first_run/first_run_browsertest.cc',
1418         'browser/first_run/try_chrome_dialog_view_browsertest.cc',
1419         'browser/geolocation/access_token_store_browsertest.cc',
1420         'browser/geolocation/geolocation_browsertest.cc',
1421         'browser/google_apis/fake_drive_service.cc',
1422         'browser/google_apis/fake_drive_service.h',
1423         'browser/history/history_browsertest.cc',
1424         'browser/history/multipart_browsertest.cc',
1425         'browser/history/redirect_browsertest.cc',
1426         'browser/iframe_browsertest.cc',
1427         'browser/importer/firefox_importer_browsertest.cc',
1428         'browser/importer/ie_importer_browsertest_win.cc',
1429         'browser/importer/importer_unittest_utils.cc',
1430         'browser/importer/importer_unittest_utils.h',
1431         'browser/importer/toolbar_importer_utils_browsertest.cc',
1432         'browser/infobars/infobar_extension_apitest.cc',
1433         'browser/infobars/infobars_browsertest.cc',
1434         'browser/loadtimes_extension_bindings_browsertest.cc',
1435         'browser/locale_tests_browsertest.cc',
1436         'browser/logging_chrome_browsertest.cc',
1437         'browser/managed_mode/managed_mode_browsertest.cc',
1438         'browser/managed_mode/managed_mode_resource_throttle_browsertest.cc',
1439         'browser/media/chrome_webrtc_browsertest.cc',
1440         'browser/media_galleries/media_galleries_dialog_controller_mock.cc',
1441         'browser/media_galleries/media_galleries_dialog_controller_mock.h',
1442         'browser/metrics/metrics_service_browsertest.cc',
1443         'browser/net/cookie_policy_browsertest.cc',
1444         'browser/net/ftp_browsertest.cc',
1445         'browser/net/load_timing_browsertest.cc',
1446         'browser/net/predictor_browsertest.cc',
1447         'browser/net/proxy_browsertest.cc',
1448         'browser/net/websocket_browsertest.cc',
1449         'browser/notifications/message_center_notifications_browsertest.cc',
1450         'browser/page_cycler/page_cycler_browsertest.cc',
1451         'browser/password_manager/password_manager_browsertest.cc',
1452         'browser/performance_monitor/performance_monitor_browsertest.cc',
1453         'browser/policy/cloud/cloud_policy_browsertest.cc',
1454         'browser/policy/cloud/cloud_policy_manager_browsertest.cc',
1455         'browser/policy/cloud/component_cloud_policy_browsertest.cc',
1456         'browser/policy/cloud/device_management_service_browsertest.cc',
1457         'browser/policy/cloud/test_request_interceptor.cc',
1458         'browser/policy/cloud/test_request_interceptor.h',
1459         'browser/policy/policy_browsertest.cc',
1460         'browser/policy/policy_prefs_browsertest.cc',
1461         'browser/policy/test_utils.cc',
1462         'browser/policy/test_utils.h',
1463         'browser/popup_blocker_browsertest.cc',
1464         'browser/prefs/pref_service_browsertest.cc',
1465         'browser/prerender/prefetch_browsertest.cc',
1466         'browser/prerender/prerender_browsertest.cc',
1467         'browser/printing/cloud_print/test/cloud_print_policy_browsertest.cc',
1468         'browser/printing/cloud_print/test/cloud_print_proxy_process_browsertest.cc',
1469         'browser/printing/print_preview_dialog_controller_browsertest.cc',
1470         'browser/printing/printing_layout_browsertest.cc',
1471         'browser/process_singleton_browsertest.cc',
1472         'browser/profiles/avatar_menu_model_browsertest.cc',
1473         'browser/profiles/profile_browsertest.cc',
1474         'browser/profiles/profile_manager_browsertest.cc',
1475         'browser/referrer_policy_browsertest.cc',
1476         'browser/renderer_host/render_process_host_chrome_browsertest.cc',
1477         'browser/renderer_host/web_cache_manager_browsertest.cc',
1478         'browser/repost_form_warning_browsertest.cc',
1479         'browser/rlz/rlz_extension_apitest.cc',
1480         'browser/safe_browsing/local_safebrowsing_test_server.cc',
1481         'browser/safe_browsing/safe_browsing_blocking_page_test.cc',
1482         'browser/safe_browsing/safe_browsing_service_browsertest.cc',
1483         'browser/safe_browsing/safe_browsing_test.cc',
1484         'browser/service/service_process_control_browsertest.cc',
1485         'browser/sessions/better_session_restore_browsertest.cc',
1486         'browser/sessions/persistent_tab_restore_service_browsertest.cc',
1487         'browser/sessions/session_restore_browsertest.cc',
1488         'browser/sessions/tab_restore_browsertest.cc',
1489         'browser/signin/signin_browsertest.cc',
1490         'browser/speech/extension_api/tts_extension_apitest.cc',
1491         'browser/speech/speech_recognition_bubble_browsertest.cc',
1492         'browser/spellchecker/spellcheck_service_browsertest.cc',
1493         'browser/ssl/ssl_browser_tests.cc',
1494         'browser/ssl/ssl_client_certificate_selector_test.cc',
1495         'browser/ssl/ssl_client_certificate_selector_test.h',
1496         'browser/sync_file_system/mock_local_change_processor.cc',
1497         'browser/sync_file_system/mock_local_change_processor.h',
1498         'browser/sync_file_system/mock_remote_file_sync_service.cc',
1499         'browser/sync_file_system/mock_remote_file_sync_service.h',
1500         'browser/tab_contents/render_view_context_menu_browsertest.cc',
1501         'browser/tab_contents/render_view_context_menu_browsertest_util.cc',
1502         'browser/tab_contents/render_view_context_menu_browsertest_util.h',
1503         'browser/tab_contents/render_view_context_menu_test_util.cc',
1504         'browser/tab_contents/render_view_context_menu_test_util.h',
1505         'browser/tab_contents/spellchecker_submenu_observer_browsertest.cc',
1506         'browser/tab_contents/spelling_menu_observer_browsertest.cc',
1507         'browser/tab_contents/view_source_browsertest.cc',
1508         'browser/task_manager/task_manager_browsertest.cc',
1509         'browser/task_manager/task_manager_browsertest_util.cc',
1510         'browser/task_manager/task_manager_browsertest_util.h',
1511         'browser/task_manager/task_manager_notification_browsertest.cc',
1512         'browser/themes/theme_service_browsertest.cc',
1513         'browser/translate/translate_browsertest.cc',
1514         'browser/translate/translate_manager_browsertest.cc',
1515         'browser/ui/app_list/app_list_controller_browsertest.cc',
1516         'browser/ui/ash/caps_lock_delegate_chromeos_browsertest.cc',
1517         'browser/ui/ash/chrome_shell_delegate_browsertest.cc',
1518         'browser/ui/ash/launcher/chrome_launcher_controller_browsertest.cc',
1519         'browser/ui/ash/launcher/chrome_launcher_controller_per_app_browsertest.cc',
1520         'browser/ui/ash/launcher/launcher_favicon_loader_browsertest.cc',
1521         'browser/ui/ash/shelf_browsertest.cc',
1522         'browser/ui/ash/volume_controller_browsertest_chromeos.cc',
1523         'browser/ui/autofill/autofill_dialog_controller_browsertest.cc',
1524         'browser/ui/autofill/autofill_popup_controller_browsertest.cc',
1525         'browser/ui/bookmarks/bookmark_browsertest.cc',
1526         'browser/ui/browser_browsertest.cc',
1527         'browser/ui/browser_close_browsertest.cc',
1528         'browser/ui/browser_command_controller_browsertest.cc',
1529         'browser/ui/browser_navigator_browsertest.cc',
1530         'browser/ui/browser_navigator_browsertest.h',
1531         'browser/ui/browser_navigator_browsertest_chromeos.cc',
1532         'browser/ui/cocoa/applescript/browsercrapplication+applescript_test.mm',
1533         'browser/ui/cocoa/applescript/window_applescript_test.mm',
1534         'browser/ui/cocoa//autofill/autofill_dialog_cocoa_browsertest.mm',
1535         'browser/ui/cocoa/browser_window_cocoa_browsertest.mm',
1536         'browser/ui/cocoa/browser_window_controller_browsertest.mm',
1537         'browser/ui/cocoa/certificate_viewer_mac_browsertest.mm',
1538         'browser/ui/cocoa/constrained_window/constrained_window_mac_browsertest.mm',
1539         'browser/ui/cocoa/content_settings/collected_cookies_mac_browsertest.mm',
1540         'browser/ui/cocoa/content_settings/content_setting_bubble_cocoa_unittest.mm',
1541         'browser/ui/cocoa/dev_tools_controller_browsertest.mm',
1542         'browser/ui/cocoa/extensions/extension_action_context_menu_browsertest.mm',
1543         'browser/ui/cocoa/extensions/extension_install_dialog_controller_browsertest.mm',
1544         'browser/ui/cocoa/extensions/extension_install_prompt_test_utils.h',
1545         'browser/ui/cocoa/extensions/extension_install_prompt_test_utils.mm',
1546         'browser/ui/cocoa/extensions/media_galleries_dialog_cocoa_browsertest.mm',
1547         'browser/ui/cocoa/find_bar/find_bar_browsertest.mm',
1548         'browser/ui/cocoa/location_bar/location_bar_view_mac_browsertest.mm',
1549         'browser/ui/cocoa/location_bar/zoom_decoration_browsertest.mm',
1550         'browser/ui/cocoa/omnibox/omnibox_view_mac_browsertest.mm',
1551         'browser/ui/cocoa/one_click_signin_bubble_controller_browsertest.mm',
1552         'browser/ui/cocoa/one_click_signin_dialog_controller_browsertest.mm',
1553         'browser/ui/cocoa/ssl_client_certificate_selector_cocoa_browsertest.mm',
1554         'browser/ui/cocoa/tab_contents/overlayable_contents_controller_browsertest.mm',
1555         'browser/ui/cocoa/view_id_util_browsertest.mm',
1556         'browser/ui/find_bar/find_bar_host_browsertest.cc',
1557         'browser/ui/fullscreen/fullscreen_controller_browsertest.cc',
1558         'browser/ui/global_error/global_error_service_browsertest.cc',
1559         'browser/ui/gtk/bubble/bubble_gtk_browsertest.cc',
1560         'browser/ui/gtk/confirm_bubble_gtk_browsertest.cc',
1561         'browser/ui/gtk/location_bar_view_gtk_browsertest.cc',
1562         'browser/ui/gtk/one_click_signin_bubble_gtk_browsertest.cc',
1563         'browser/ui/gtk/view_id_util_browsertest.cc',
1564         'browser/ui/login/login_prompt_browsertest.cc',
1565         'browser/ui/panels/panel_extension_browsertest.cc',
1566         'browser/ui/prefs/prefs_tab_helper_browsertest.cc',
1567         'browser/ui/startup/startup_browser_creator_browsertest.cc',
1568         'browser/ui/sync/profile_signin_confirmation_helper_browsertest.cc',
1569         'browser/ui/tab_modal_confirm_dialog_browsertest.cc',
1570         'browser/ui/tab_modal_confirm_dialog_browsertest.h',
1571         'browser/ui/toolbar/test_toolbar_model.cc',
1572         'browser/ui/toolbar/test_toolbar_model.h',
1573         'browser/ui/views/app_list/app_list_controller_win_browsertest.cc',
1574         'browser/ui/views/avatar_menu_button_browsertest.cc',
1575         'browser/ui/views/browser_actions_container_browsertest.cc',
1576         'browser/ui/views/frame/app_non_client_frame_view_ash_browsertest.cc',
1577         'browser/ui/views/frame/browser_non_client_frame_view_ash_browsertest.cc',
1578         'browser/ui/views/frame/immersive_mode_controller_ash_browsertest.cc',
1579         'browser/ui/views/select_file_dialog_extension_browsertest.cc',
1580         'browser/ui/views/sync/one_click_signin_bubble_view_browsertest.cc',
1581         'browser/ui/views/toolbar_view_browsertest.cc',
1582         'browser/ui/views/web_dialog_view_browsertest.cc',
1583         'browser/ui/webui/bidi_checker_web_ui_test.cc',
1584         'browser/ui/webui/bidi_checker_web_ui_test.h',
1585         'browser/ui/webui/bookmarks_ui_browsertest.cc',
1586         'browser/ui/webui/chrome_url_data_manager_browsertest.cc',
1587         'browser/ui/webui/constrained_web_dialog_ui_browsertest.cc',
1588         'browser/ui/webui/downloads_dom_handler_browsertest.cc',
1589         'browser/ui/webui/extensions/extension_settings_browsertest.js',
1590         'browser/ui/webui/help/help_browsertest.js',
1591         'browser/ui/webui/inspect_ui_browsertest.cc',
1592         'browser/ui/webui/net_internals/net_internals_ui_browsertest.cc',
1593         'browser/ui/webui/net_internals/net_internals_ui_browsertest.h',
1594         'browser/ui/webui/ntp/most_visited_browsertest.cc',
1595         'browser/ui/webui/ntp/new_tab_page_sync_handler_browsertest.cc',
1596         'browser/ui/webui/ntp/new_tab_ui_browsertest.cc',
1597         'browser/ui/webui/options/autofill_options_browsertest.js',
1598         'browser/ui/webui/options/browser_options_browsertest.js',
1599         'browser/ui/webui/options/certificate_manager_browsertest.js',
1600         'browser/ui/webui/options/chromeos/bluetooth_options_browsertest.js',
1601         'browser/ui/webui/options/chromeos/guest_mode_options_ui_browsertest.cc',
1602         'browser/ui/webui/options/chromeos/kiosk_apps_browsertest.js',
1603         'browser/ui/webui/options/content_options_browsertest.js',
1604         'browser/ui/webui/options/content_settings_exception_area_browsertest.js',
1605         'browser/ui/webui/options/cookies_view_browsertest.js',
1606         'browser/ui/webui/options/edit_dictionary_browsertest.js',
1607         'browser/ui/webui/options/font_settings_browsertest.js',
1608         'browser/ui/webui/options/language_options_browsertest.js',
1609         'browser/ui/webui/options/language_options_dictionary_download_browsertest.js',
1610         'browser/ui/webui/options/managed_user_set_passphrase_browsertest.js',
1611         'browser/ui/webui/options/managed_user_set_passphrase_test.cc',
1612         'browser/ui/webui/options/managed_user_set_passphrase_test.h',
1613         'browser/ui/webui/options/managed_user_settings_browsertest.js',
1614         'browser/ui/webui/options/managed_user_settings_test.cc',
1615         'browser/ui/webui/options/managed_user_settings_test.h',
1616         'browser/ui/webui/options/options_browsertest.js',
1617         'browser/ui/webui/options/options_ui_browsertest.cc',
1618         'browser/ui/webui/options/options_ui_browsertest.h',
1619         'browser/ui/webui/options/password_manager_browsertest.js',
1620         'browser/ui/webui/options/preferences_browsertest.cc',
1621         'browser/ui/webui/options/preferences_browsertest.h',
1622         'browser/ui/webui/options/search_engine_manager_browsertest.js',
1623         'browser/ui/webui/options/settings_format_browsertest.js',
1624         'browser/ui/webui/policy_ui_browsertest.cc',
1625         'browser/ui/webui/print_preview/print_preview_ui_browsertest.cc',
1626         'browser/ui/webui/sync_setup_browsertest.js',
1627         'browser/ui/webui/web_ui_test_handler.cc',
1628         'browser/ui/webui/web_ui_test_handler.h',
1629         'browser/user_data_dir_extractor_win_browsertest.cc',
1630         'browser/unload_browsertest.cc',
1631         'common/mac/mock_launchd.cc',
1632         'common/mac/mock_launchd.h',
1633         'common/time_format_browsertest.cc',
1634         'renderer/autofill/autofill_renderer_browsertest.cc',
1635         'renderer/autofill/form_autocomplete_browsertest.cc',
1636         'renderer/autofill/form_autofill_browsertest.cc',
1637         'renderer/autofill/page_click_tracker_browsertest.cc',
1638         'renderer/autofill/password_autofill_agent_browsertest.cc',
1639         'renderer/autofill/password_generation_manager_browsertest.cc',
1640         'renderer/automation/automation_renderer_helper_browsertest.cc',
1641         'renderer/content_settings_observer_browsertest.cc',
1642         'renderer/printing/print_web_view_helper_browsertest.cc',
1643         'renderer/safe_browsing/malware_dom_details_browsertest.cc',
1644         'renderer/safe_browsing/phishing_classifier_browsertest.cc',
1645         'renderer/safe_browsing/phishing_classifier_delegate_browsertest.cc',
1646         'renderer/safe_browsing/phishing_dom_feature_extractor_browsertest.cc',
1647         'renderer/safe_browsing/phishing_thumbnailer_browsertest.cc',
1648         'renderer/translate/translate_helper_browsertest.cc',
1649         'test/base/chrome_render_view_test.cc',
1650         'test/base/chrome_render_view_test.h',
1651         'test/base/chrome_test_launcher.cc',
1652         'test/base/empty_browser_test.cc',
1653         'test/base/web_ui_browsertest.cc',
1654         'test/base/web_ui_browsertest.h',
1655         'test/data/chromeos/oobe_webui_browsertest.js',
1656         'test/base/in_process_browser_test_browsertest.cc',
1657         'test/base/tracing_browsertest.cc',
1658         'test/base/test_chrome_web_ui_controller_factory.cc',
1659         'test/base/test_chrome_web_ui_controller_factory.h',
1660         'test/base/test_chrome_web_ui_controller_factory_browsertest.cc',
1661         'test/data/webui/accessibility_audit_browsertest.js',
1662         'test/data/webui/assertions.js',
1663         'test/data/webui/async_gen.cc',
1664         'test/data/webui/async_gen.h',
1665         'test/data/webui/async_gen.js',
1666         'test/data/webui/certificate_viewer_dialog_test.js',
1667         'test/data/webui/certificate_viewer_ui_test-inl.h',
1668         'test/data/webui/chrome_send_browsertest.cc',
1669         'test/data/webui/chrome_send_browsertest.h',
1670         'test/data/webui/chrome_send_browsertest.js',
1671         'test/data/webui/history_browsertest.js',
1672         'test/data/webui/history_ui_browsertest.cc',
1673         'test/data/webui/history_ui_browsertest.h',
1674         'test/data/webui/mock4js_browsertest.js',
1675         'test/data/webui/net_internals/bandwidth_view.js',
1676         'test/data/webui/net_internals/dns_view.js',
1677         'test/data/webui/net_internals/events_view.js',
1678         'test/data/webui/net_internals/hsts_view.js',
1679         'test/data/webui/net_internals/http_pipeline_view.js',
1680         'test/data/webui/net_internals/log_util.js',
1681         'test/data/webui/net_internals/log_view_painter.js',
1682         'test/data/webui/net_internals/main.js',
1683         'test/data/webui/net_internals/net_internals_test.js',
1684         'test/data/webui/net_internals/prerender_view.js',
1685         'test/data/webui/net_internals/test_view.js',
1686         'test/data/webui/net_internals/timeline_view.js',
1687         'test/data/webui/ntp4.js',
1688         'test/data/webui/ntp4_browsertest.cc',
1689         'test/data/webui/ntp4_browsertest.h',
1690         'test/data/webui/print_preview.cc',
1691         'test/data/webui/print_preview.h',
1692         'test/data/webui/print_preview.js',
1693         'test/data/webui/sandboxstatus_browsertest.js',
1694         'test/gpu/gpu_feature_browsertest.cc',
1695         'test/gpu/webgl_infobar_browsertest.cc',
1696         'test/ppapi/ppapi_browsertest.cc',
1697         'test/security_tests/sandbox_browsertest.cc',
1698         # TODO(craig): Rename this and run from base_unittests when the test
1699         # is safe to run there. See http://crbug.com/78722 for details.
1700         '../base/files/file_path_watcher_browsertest.cc',
1701       ],
1702       'rules': [
1703         {
1704           'rule_name': 'js2webui',
1705           'extension': 'js',
1706           'msvs_external_rule': 1,
1707           'inputs': [
1708             '<(gypv8sh)',
1709             '<(PRODUCT_DIR)/v8_shell<(EXECUTABLE_SUFFIX)',
1710             '<(mock_js)',
1711             '<(accessibility_audit_js)',
1712             '<(test_api_js)',
1713             '<(js2gtest)',
1714           ],
1715           'outputs': [
1716             '<(INTERMEDIATE_DIR)/chrome/<(RULE_INPUT_DIRNAME)/<(RULE_INPUT_ROOT)-gen.cc',
1717             '<(PRODUCT_DIR)/test_data/chrome/<(RULE_INPUT_DIRNAME)/<(RULE_INPUT_ROOT).js',
1718           ],
1719           'process_outputs_as_sources': 1,
1720           'action': [
1721             'python',
1722             '<@(_inputs)',
1723             'webui',
1724             '<(RULE_INPUT_PATH)',
1725             'chrome/<(RULE_INPUT_DIRNAME)/<(RULE_INPUT_ROOT).js',
1726             '<@(_outputs)',
1727           ],
1728         },
1729       ],
1730       'conditions': [
1731         ['enable_one_click_signin==0', {
1732           'sources!': [
1733             'browser/ui/gtk/one_click_signin_bubble_gtk_browsertest.cc',
1734             'browser/ui/views/sync/one_click_signin_bubble_view_browsertest.cc',
1735           ]
1736         }],
1737         ['disable_nacl==0', {
1738           'sources':[
1739             'browser/extensions/extension_nacl_browsertest.cc',
1740             'browser/nacl_host/test/gdb_debug_stub_browsertest.cc',
1741           ],
1742           'dependencies': [
1743             # Runtime dependency.
1744             '../ppapi/native_client/src/trusted/plugin/plugin.gyp:ppGoogleNaClPluginChrome',
1745           ],
1746           'conditions': [
1747             ['disable_nacl_untrusted==0', {
1748               'sources': [
1749                 'test/nacl/nacl_browsertest.cc',
1750                 'test/nacl/nacl_browsertest_uma.cc',
1751                 'test/nacl/nacl_browsertest_util.cc',
1752                 'test/nacl/nacl_browsertest_util.h',
1753               ],
1754               'dependencies': [
1755                 'test/data/nacl/nacl_test_data.gyp:*',
1756                 '../ppapi/native_client/native_client.gyp:nacl_irt',
1757                 '../ppapi/ppapi_untrusted.gyp:ppapi_nacl_tests',
1758               ],
1759             }],
1760             ['OS=="win" or OS=="linux"', {
1761               'sources': [
1762                 'browser/nacl_host/test/nacl_gdb_browsertest.cc',
1763               ],
1764               'dependencies': [
1765                 'browser/nacl_host/test/mock_nacl_gdb.gyp:mock_nacl_gdb',
1766               ],
1767             }],
1768             ['OS=="win"', {
1769               # TODO(halyavin) NaCl on Windows can't open debug stub socket
1770               # in browser process as needed by this test.
1771               # See http://crbug.com/157312.
1772               'sources!': [
1773                 'browser/nacl_host/test/gdb_debug_stub_browsertest.cc',
1774               ],
1775               'dependencies': [
1776                 'chrome.gyp:chrome_nacl_win64',
1777               ],
1778             }],
1779             ['chromeos==0', {
1780               'sources!': [
1781                 'test/data/chromeos/oobe_webui_browsertest.js',
1782               ],
1783             }],
1784           ],
1785         }],
1786         ['use_ash==1', {
1787           'dependencies': [
1788             '../ash/ash.gyp:ash_test_support',
1789           ],
1790         }],
1791         ['chromeos==0', {
1792           'sources/': [
1793             ['exclude', '^browser/chromeos'],
1794             ['exclude', '^browser/ui/webui/options/chromeos/'],
1795           ],
1796           'sources!': [
1797             'browser/extensions/api/rtc_private/rtc_private_apitest.cc',
1798             'browser/extensions/api/terminal/terminal_private_apitest.cc',
1799             'browser/ui/ash/caps_lock_delegate_chromeos_browsertest.cc',
1800             'test/data/webui/certificate_viewer_dialog_test.js',
1801             'test/data/webui/certificate_viewer_ui_test-inl.h',
1802           ],
1803         }, { # chromeos==1
1804           'sources!': [
1805             'browser/extensions/load_and_launch_browsertest.cc',
1806             'browser/printing/cloud_print/test/cloud_print_policy_browsertest.cc',
1807             'browser/printing/cloud_print/test/cloud_print_proxy_process_browsertest.cc',
1808             'browser/service/service_process_control_browsertest.cc',
1809             'browser/signin/signin_browsertest.cc',
1810             # chromeos does not use cross-platform panels
1811             'browser/ui/panels/panel_extension_browsertest.cc',
1812           ],
1813           'dependencies': [
1814             '../dbus/dbus.gyp:dbus_test_support',
1815             '../build/linux/system.gyp:dbus',
1816           ],
1817         }],
1818         ['file_manager_extension==0', {
1819           'sources!': [
1820             'browser/ui/views/select_file_dialog_extension_browsertest.cc',
1821           ],
1822         }],
1823         ['configuration_policy==0', {
1824           'sources/': [
1825             ['exclude', '^browser/policy/'],
1826           ],
1827           'sources!': [
1828             'browser/ui/webui/policy_ui_browsertest.cc',
1829             'browser/ui/webui/options/preferences_browsertest.cc',
1830           ],
1831         }],
1832         ['input_speech==0', {
1833           'sources/': [
1834             ['exclude', '^browser/speech/'],
1835             ['exclude', '^../content/browser/speech/'],
1836           ],
1837         }],
1838         ['safe_browsing==1', {
1839           'defines': [
1840             'FULL_SAFE_BROWSING',
1841           ],
1842         }],
1843         # TODO(sgurun) enable tests.
1844         ['safe_browsing==2', {
1845           'sources/': [
1846             ['exclude', '^browser/safe_browsing/'],
1847             ['exclude', '^renderer/safe_browsing/'],
1848           ],
1849         }],
1850         ['safe_browsing==0', {
1851           'sources/': [
1852             ['exclude', '^browser/safe_browsing/'],
1853             ['exclude', '^renderer/safe_browsing/'],
1854           ],
1855         }],
1856         ['enable_captive_portal_detection!=1', {
1857           'sources/': [
1858             ['exclude', '^browser/captive_portal/'],
1859           ],
1860         }],
1861         ['internal_pdf', {
1862           'dependencies': [
1863             '../pdf/pdf.gyp:pdf',
1864           ],
1865           'sources': [
1866             'browser/ui/pdf/pdf_browsertest.cc',
1867           ],
1868         }],
1869         ['OS!="linux" or toolkit_views==1', {
1870           'sources!': [
1871             'browser/ui/gtk/view_id_util_browsertest.cc',
1872           ],
1873         }],
1874         ['enable_rlz==0', {
1875           'sources!': [
1876             'browser/rlz/rlz_extension_apitest.cc',
1877           ],
1878         }],
1879         ['enable_webrtc==0', {
1880           'sources!': [
1881             'browser/media/chrome_webrtc_browsertest.cc',
1882           ],
1883         }],
1884         ['OS=="win"', {
1885           'sources': [
1886             '<(SHARED_INTERMEDIATE_DIR)/chrome/browser_resources.rc',
1887             '<(SHARED_INTERMEDIATE_DIR)/chrome/chrome_unscaled_resources.rc',
1888             '<(SHARED_INTERMEDIATE_DIR)/chrome/common_resources.rc',
1889             '<(SHARED_INTERMEDIATE_DIR)/chrome/extensions_api_resources.rc',
1890             '<(SHARED_INTERMEDIATE_DIR)/chrome_version/other_version.rc',
1891             '<(SHARED_INTERMEDIATE_DIR)/content/content_resources.rc',
1892             '<(SHARED_INTERMEDIATE_DIR)/net/net_resources.rc',
1893             '<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources/ui_unscaled_resources.rc',
1894             '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_chromium_resources.rc',
1895           ],
1896           'include_dirs': [
1897             '<(DEPTH)/third_party/wtl/include',
1898           ],
1899           'dependencies': [
1900             'app_host',
1901             'browser_tests_exe_pdb_workaround',
1902             'chrome_version_resources',
1903             'security_tests',  # run time dependency
1904           ],
1905           'conditions': [
1906             ['win_use_allocator_shim==1', {
1907               'dependencies': [
1908                 '<(allocator_target)',
1909               ],
1910             }],
1911           ],
1912           'sources!': [
1913             # use_aura currently sets use_ash on Windows. So take these tests out
1914             # for win aura builds.
1915             # TODO: enable these for win_ash browser tests.
1916             'browser/chromeos/system/tray_accessibility_browsertest.cc',
1917             'browser/ui/ash/caps_lock_delegate_chromeos_browsertest.cc',
1918             'browser/ui/ash/chrome_shell_delegate_browsertest.cc',
1919             'browser/ui/ash/launcher/chrome_launcher_controller_per_app_browsertest.cc',
1920             'browser/ui/ash/launcher/chrome_launcher_controller_browsertest.cc',
1921             'browser/ui/ash/launcher/launcher_favicon_loader_browsertest.cc',
1922             'browser/ui/ash/shelf_browsertest.cc',
1923             'browser/ui/views/frame/app_non_client_frame_view_ash_browsertest.cc',
1924             'browser/ui/views/frame/browser_non_client_frame_view_ash_browsertest.cc',
1925             'browser/ui/views/frame/immersive_mode_controller_ash_browsertest.cc',
1926           ],
1927         }, { # else: OS != "win"
1928           'sources!': [
1929             'app/chrome_command_ids.h',
1930             'app/chrome_dll.rc',
1931             'app/chrome_dll_resource.h',
1932             'app/chrome_version.rc.version',
1933             # TODO(port): http://crbug.com/45770
1934             'browser/printing/printing_layout_browsertest.cc',
1935             'browser/ui/views/app_list/app_list_controller_win_browsertest.cc',
1936             'browser/user_data_dir_extractor_win_browsertest.cc',
1937           ],
1938         }],
1939         ['toolkit_uses_gtk == 1', {
1940           'dependencies': [
1941             '../build/linux/system.gyp:gtk',
1942           ],
1943         }],
1944         ['toolkit_uses_gtk == 1 or chromeos==1 or (OS=="linux" and use_aura==1)', {
1945           'dependencies': [
1946             '../build/linux/system.gyp:ssl',
1947           ],
1948         }],
1949         ['OS=="mac"', {
1950           'include_dirs': [
1951             '../third_party/GTM',
1952           ],
1953           # TODO(mark): We really want this for all non-static library
1954           # targets, but when we tried to pull it up to the common.gypi
1955           # level, it broke other things like the ui, startup, and
1956           # page_cycler tests. *shrug*
1957           'xcode_settings': {
1958             'OTHER_LDFLAGS': [
1959               '-Wl,-ObjC',
1960             ],
1961           },
1962           # Other platforms only need
1963           # chrome_resources.gyp:{packed_extra_resources,packed_resources},
1964           # and can build this target standalone much faster.
1965           'dependencies': [
1966             'chrome'
1967           ],
1968           'sources': [
1969             'browser/spellchecker/spellcheck_message_filter_mac_browsertest.cc',
1970           ],
1971           'sources!': [
1972             # TODO(groby): This test depends on hunspell and we cannot run it on
1973             # Mac, which does not use hunspell by default.
1974             'browser/spellchecker/spellcheck_service_browsertest.cc',
1975             # TODO(rouslan): This test depends on the custom dictionary UI,
1976             # which is disabled on Mac.
1977             'browser/ui/webui/options/edit_dictionary_browsertest.js',
1978             # TODO(rouslan): This test depends on hunspell and we cannot run it
1979             # on Mac, which does use hunspell by default.
1980             'browser/ui/webui/options/language_options_dictionary_download_browsertest.js',
1981             # ProcessSingletonMac doesn't do anything.
1982             'browser/process_singleton_browsertest.cc',
1983             # This test depends on GetCommandLineForRelaunch, which is not
1984             # available on Mac.
1985             'browser/printing/cloud_print/test/cloud_print_policy_browsertest.cc',
1986           ],
1987         }],
1988         ['os_posix == 0 or chromeos == 1', {
1989           'sources!': [
1990             'common/time_format_browsertest.cc',
1991           ],
1992         }],
1993         ['os_posix == 1 and OS != "mac" and OS != "android"', {
1994           'conditions': [
1995             ['linux_use_tcmalloc==1', {
1996               'dependencies': [
1997                 '../base/allocator/allocator.gyp:allocator',
1998               ],
1999             }],
2000           ],
2001         }],
2002         ['toolkit_views==1', {
2003           'dependencies': [
2004             '../ui/views/views.gyp:views',
2005           ],
2006           'sources!': [
2007             # TODO(estade): port to views.
2008             'browser/ui/webui/constrained_web_dialog_ui_browsertest.cc',
2009           ],
2010         }, { # else: toolkit_views == 0
2011           'sources/': [
2012             ['exclude', '^../ui/views/'],
2013             ['exclude', '^browser/extensions/api/input/input_apitest.cc'],
2014             ['exclude', '^browser/ui/views/'],
2015           ],
2016         }],
2017         ['OS!="android" and OS!="ios"', {
2018           # npapi test plugin doesn't build on android or ios
2019           'dependencies': [
2020             # build time dependency.
2021             '../v8/tools/gyp/v8.gyp:v8_shell#host',
2022             '../webkit/webkit.gyp:copy_npapi_test_plugin',
2023           ],
2024         }],
2025         ['enable_app_list==0', {
2026           'sources/': [
2027             ['exclude', '^browser/ui/app_list/'],
2028           ],
2029         }],
2030         ['enable_message_center==0', {
2031           'sources!': [
2032             'browser/notifications/message_center_notifications_browsertest.cc',
2033           ],
2034         }],
2035         ['enable_plugins==1', {
2036           'dependencies': [
2037             # Runtime dependency.
2038             '../third_party/widevine/cdm/widevine_cdm.gyp:widevinecdmadapter',
2039             '../webkit/support/webkit_support.gyp:clearkeycdmadapter',
2040           ],
2041         }],
2042         ['chromeos==1', {
2043           'sources!': [
2044             'browser/ui/webui/options/managed_user_set_passphrase_browsertest.js',
2045             'browser/ui/webui/options/managed_user_set_passphrase_test.cc',
2046             'browser/ui/webui/options/managed_user_set_passphrase_test.h',
2047             'browser/ui/webui/options/managed_user_settings_browsertest.js',
2048             'browser/ui/webui/options/managed_user_settings_test.cc',
2049             'browser/ui/webui/options/managed_user_settings_test.h',
2050           ],
2051         }],
2052       ],  # conditions
2053     },  # target browser_tests
2054     {
2055       # Executable that runs each perf browser test in a new process.
2056       'target_name': 'performance_browser_tests',
2057       'type': 'executable',
2058       'msvs_cygwin_shell': 0,
2059       'msvs_cygwin_dirs': ['<(DEPTH)/third_party/cygwin'],
2060       'dependencies': [
2061         'browser',
2062         'chrome_resources.gyp:chrome_resources',
2063         'chrome_resources.gyp:chrome_strings',
2064         'chrome_resources.gyp:packed_extra_resources',
2065         'chrome_resources.gyp:packed_resources',
2066         'renderer',
2067         'test_support_common',
2068         '../base/base.gyp:base',
2069         '../base/base.gyp:base_i18n',
2070         '../base/base.gyp:test_support_base',
2071         '../net/net.gyp:net',
2072         '../net/net.gyp:net_test_support',
2073         '../skia/skia.gyp:skia',
2074         '../sync/sync.gyp:sync',
2075         '../testing/gmock.gyp:gmock',
2076         '../testing/gtest.gyp:gtest',
2077         '../third_party/cld/cld.gyp:cld',
2078         '../third_party/icu/icu.gyp:icui18n',
2079         '../third_party/icu/icu.gyp:icuuc',
2080         '../third_party/leveldatabase/leveldatabase.gyp:leveldatabase',
2081         '../v8/tools/gyp/v8.gyp:v8',
2082         # Runtime dependencies
2083         '../third_party/mesa/mesa.gyp:osmesa',
2084       ],
2085       'include_dirs': [
2086         '..',
2087       ],
2088       'defines': [
2089         'HAS_OUT_OF_PROC_TEST_RUNNER',
2090       ],
2091       'sources': [
2092         'app/breakpad_mac_stubs.mm',
2093         'app/chrome_command_ids.h',
2094         'app/chrome_dll.rc',
2095         'app/chrome_dll_resource.h',
2096         'app/chrome_version.rc.version',
2097         'test/base/chrome_render_view_test.cc',
2098         'test/base/chrome_render_view_test.h',
2099         'test/base/chrome_test_launcher.cc',
2100         'test/perf/browser_perf_test.cc',
2101         'test/perf/browser_perf_test.h',
2102         'test/perf/rendering/latency_tests.cc',
2103         'test/perf/rendering/throughput_tests.cc',
2104       ],
2105       'rules': [
2106         {
2107           'rule_name': 'js2webui',
2108           'extension': 'js',
2109           'msvs_external_rule': 1,
2110           'inputs': [
2111             '<(gypv8sh)',
2112             '<(PRODUCT_DIR)/v8_shell<(EXECUTABLE_SUFFIX)',
2113             '<(mock_js)',
2114             '<(accessibility_audit_js)',
2115             '<(test_api_js)',
2116             '<(js2gtest)',
2117           ],
2118           'outputs': [
2119             '<(INTERMEDIATE_DIR)/chrome/<(RULE_INPUT_DIRNAME)/<(RULE_INPUT_ROOT)-gen.cc',
2120             '<(PRODUCT_DIR)/test_data/chrome/<(RULE_INPUT_DIRNAME)/<(RULE_INPUT_ROOT).js',
2121           ],
2122           'process_outputs_as_sources': 1,
2123           'action': [
2124             'python',
2125             '<@(_inputs)',
2126             'webui',
2127             '<(RULE_INPUT_PATH)',
2128             'chrome/<(RULE_INPUT_DIRNAME)/<(RULE_INPUT_ROOT).js',
2129             '<@(_outputs)',
2130           ],
2131         },
2132       ],
2133       'conditions': [
2134         ['OS=="win"', {
2135           'sources': [
2136             '<(SHARED_INTERMEDIATE_DIR)/chrome/browser_resources.rc',
2137             '<(SHARED_INTERMEDIATE_DIR)/chrome/chrome_unscaled_resources.rc',
2138             '<(SHARED_INTERMEDIATE_DIR)/chrome/common_resources.rc',
2139             '<(SHARED_INTERMEDIATE_DIR)/chrome/extensions_api_resources.rc',
2140             '<(SHARED_INTERMEDIATE_DIR)/chrome_version/other_version.rc',
2141             '<(SHARED_INTERMEDIATE_DIR)/content/content_resources.rc',
2142             '<(SHARED_INTERMEDIATE_DIR)/net/net_resources.rc',
2143             '<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources/ui_unscaled_resources.rc',
2144             '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_chromium_resources.rc',
2145           ],
2146           'include_dirs': [
2147             '<(DEPTH)/third_party/wtl/include',
2148           ],
2149           'dependencies': [
2150             'chrome_version_resources',
2151           ],
2152           'conditions': [
2153             ['win_use_allocator_shim==1', {
2154               'dependencies': [
2155                 '<(allocator_target)',
2156               ],
2157             }],
2158           ],
2159           'configurations': {
2160             'Debug_Base': {
2161               'msvs_settings': {
2162                 'VCLinkerTool': {
2163                   'LinkIncremental': '<(msvs_debug_link_nonincremental)',
2164                 },
2165               },
2166             },
2167           }
2168         }, { # else: OS != "win"
2169           'sources!': [
2170             'app/chrome_command_ids.h',
2171             'app/chrome_dll.rc',
2172             'app/chrome_dll_resource.h',
2173             'app/chrome_version.rc.version',
2174           ],
2175         }],
2176         ['use_x11==1', {
2177           'dependencies': [
2178             '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
2179           ],
2180         }],
2181         ['toolkit_uses_gtk == 1', {
2182           'dependencies': [
2183             '../build/linux/system.gyp:gtk',
2184           ],
2185         }],
2186         ['toolkit_uses_gtk == 1 or chromeos==1 or (OS=="linux" and use_aura==1)', {
2187           'dependencies': [
2188             '../build/linux/system.gyp:ssl',
2189           ],
2190         }],
2191         ['OS=="mac"', {
2192           'include_dirs': [
2193             '../third_party/GTM',
2194           ],
2195           # TODO(mark): We really want this for all non-static library
2196           # targets, but when we tried to pull it up to the common.gypi
2197           # level, it broke other things like the ui, startup, and
2198           # page_cycler tests. *shrug*
2199           'xcode_settings': {
2200             'OTHER_LDFLAGS': [
2201               '-Wl,-ObjC',
2202             ],
2203           },
2204           # Other platforms only need
2205           # chrome_resources.gyp:{packed_extra_resources,packed_resources},
2206           # and can build this target standalone much faster.
2207           'dependencies': [
2208             'chrome'
2209           ],
2210         }],
2211         ['os_posix == 1 and OS != "mac" and OS != "android"', {
2212           'conditions': [
2213             ['linux_use_tcmalloc==1', {
2214               'dependencies': [
2215                 '../base/allocator/allocator.gyp:allocator',
2216               ],
2217             }],
2218           ],
2219         }],
2220       ],  # conditions
2221     },  # target performance_browser_tests
2222     {
2223       # To run the tests from page_load_test.cc on Linux, we need to:
2224       #
2225       #   a) Build with Breakpad (GYP_DEFINES="linux_chromium_breakpad=1")
2226       #   b) Run with CHROME_HEADLESS=1 to generate crash dumps.
2227       #   c) Strip the binary if it's a debug build. (binary may be over 2GB)
2228       'target_name': 'reliability_tests',
2229       'type': 'executable',
2230       'dependencies': [
2231         'browser',
2232         'chrome',
2233         'chrome_resources.gyp:theme_resources',
2234         'test_support_common',
2235         'test_support_ui',
2236         '../skia/skia.gyp:skia',
2237         '../testing/gtest.gyp:gtest',
2238         '../third_party/WebKit/Source/WebKit/chromium/WebKit.gyp:webkit',
2239       ],
2240       'include_dirs': [
2241         '..',
2242       ],
2243       'sources': [
2244         'test/reliability/page_load_test.cc',
2245       ],
2246       'conditions': [
2247         ['OS=="win" and buildtype=="Official"', {
2248           'configurations': {
2249             'Release': {
2250               'msvs_settings': {
2251                 'VCCLCompilerTool': {
2252                   'WholeProgramOptimization': 'false',
2253                 },
2254               },
2255             },
2256           },
2257         },],
2258         ['OS=="win" and win_use_allocator_shim==1', {
2259           'dependencies': [
2260             '<(allocator_target)',
2261           ],
2262           'configurations': {
2263             'Debug': {
2264               'msvs_settings': {
2265                 'VCLinkerTool': {
2266                   'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
2267                 },
2268               },
2269             },
2270           },
2271         },],
2272         ['toolkit_uses_gtk == 1', {
2273           'dependencies': [
2274             '../build/linux/system.gyp:gtk',
2275           ],
2276         },],
2277         ['OS=="linux" and enable_webrtc==1', {
2278           'dependencies': [
2279             # TODO(tommi): Figure out why the 32bit lucid builder fails to
2280             # find this dependency for this target (other builders pick it up
2281             # correctly).  crbug.com/231068.
2282             '../third_party/libjingle/libjingle.gyp:libpeerconnection',
2283           ],
2284         }],
2285       ],
2286     },
2287     {
2288       'target_name': 'performance_ui_tests',
2289       'type': 'executable',
2290       'dependencies': [
2291         'chrome',
2292         'chrome_resources.gyp:chrome_resources',
2293         'chrome_resources.gyp:chrome_strings',
2294         'debugger',
2295         'test_support_common',
2296         'test_support_ui',
2297         '../base/base.gyp:base',
2298         '../skia/skia.gyp:skia',
2299         '../testing/gtest.gyp:gtest',
2300       ],
2301       'sources': [
2302         # TODO(darin): Move other UIPerfTests here.
2303         'test/perf/dom_checker_uitest.cc',
2304         'test/perf/feature_startup_test.cc',
2305         'test/perf/frame_rate/frame_rate_tests.cc',
2306         'test/perf/indexeddb_uitest.cc',
2307         'test/perf/memory_test.cc',
2308         'test/perf/page_cycler_test.cc',
2309         'test/perf/shutdown_test.cc',
2310         'test/perf/startup_test.cc',
2311         'test/perf/tab_switching_test.cc',
2312         'test/perf/url_fetch_test.cc',
2313       ],
2314       'conditions': [
2315         ['OS=="win" and buildtype=="Official"', {
2316           'configurations': {
2317             'Release': {
2318               'msvs_settings': {
2319                 'VCCLCompilerTool': {
2320                   'WholeProgramOptimization': 'false',
2321                 },
2322               },
2323             },
2324           },
2325         }],
2326         ['OS=="win"', {
2327           'conditions': [
2328             ['win_use_allocator_shim==1', {
2329               'dependencies': [
2330                 '<(allocator_target)',
2331               ],
2332             }],
2333           ],
2334           'configurations': {
2335             'Debug_Base': {
2336               'msvs_settings': {
2337                 'VCLinkerTool': {
2338                   'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
2339                 },
2340               },
2341             },
2342           },
2343           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
2344           'msvs_disabled_warnings': [ 4267, ],
2345         }],
2346         ['OS=="mac"', {
2347           'sources': [
2348             'test/perf/mach_ports_test.cc',
2349           ],
2350         }],
2351         ['use_x11==1', {
2352           'dependencies': [
2353             '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
2354           ],
2355         }],
2356         ['toolkit_uses_gtk == 1', {
2357           'dependencies': [
2358             '../build/linux/system.gyp:gtk',
2359           ],
2360         }],
2361         ['os_posix == 1 and OS != "mac" and OS != "android"', {
2362           'conditions': [
2363             ['linux_use_tcmalloc==1', {
2364               'dependencies': [
2365                 '../base/allocator/allocator.gyp:allocator',
2366               ],
2367             }],
2368           ],
2369         }],
2370         ['toolkit_views==1', {
2371           'dependencies': [
2372             '../ui/views/views.gyp:views',
2373           ],
2374         }],
2375       ],
2376     },
2377     {
2378       'target_name': 'sync_integration_tests',
2379       'type': 'executable',
2380       'dependencies': [
2381         'browser',
2382         'chrome',
2383         'chrome_resources.gyp:chrome_resources',
2384         'chrome_resources.gyp:chrome_strings',
2385         'chrome_resources.gyp:packed_extra_resources',
2386         'chrome_resources.gyp:packed_resources',
2387         'common',
2388         'common/extensions/api/api.gyp:api',
2389         'renderer',
2390         'test_support_common',
2391         '../net/net.gyp:net',
2392         '../printing/printing.gyp:printing',
2393         '../skia/skia.gyp:skia',
2394         '../sync/sync.gyp:sync',
2395         '../sync/sync.gyp:test_support_sync_testserver',
2396         '../testing/gmock.gyp:gmock',
2397         '../testing/gtest.gyp:gtest',
2398         '../third_party/icu/icu.gyp:icui18n',
2399         '../third_party/icu/icu.gyp:icuuc',
2400         '../third_party/leveldatabase/leveldatabase.gyp:leveldatabase',
2401         '../third_party/npapi/npapi.gyp:npapi',
2402         '../third_party/WebKit/Source/WebKit/chromium/WebKit.gyp:webkit',
2403       ],
2404       'include_dirs': [
2405         '..',
2406         '<(INTERMEDIATE_DIR)',
2407         '<(protoc_out_dir)',
2408       ],
2409       # TODO(phajdan.jr): Only temporary, to make transition easier.
2410       'defines': [
2411         'HAS_OUT_OF_PROC_TEST_RUNNER',
2412       ],
2413       'sources': [
2414         'app/chrome_command_ids.h',
2415         'app/chrome_dll.rc',
2416         'app/chrome_dll_resource.h',
2417         'app/chrome_version.rc.version',
2418         'test/base/chrome_test_launcher.cc',
2419         'test/data/resource.rc',
2420         'browser/sync/test/integration/apps_helper.cc',
2421         'browser/sync/test/integration/apps_helper.h',
2422         'browser/sync/test/integration/autofill_helper.cc',
2423         'browser/sync/test/integration/autofill_helper.h',
2424         'browser/sync/test/integration/bookmarks_helper.cc',
2425         'browser/sync/test/integration/bookmarks_helper.h',
2426         'browser/sync/test/integration/cross_platform_sync_test.cc',
2427         'browser/sync/test/integration/dictionary_helper.cc',
2428         'browser/sync/test/integration/dictionary_helper.h',
2429         'browser/sync/test/integration/dictionary_load_observer.cc',
2430         'browser/sync/test/integration/dictionary_load_observer.h',
2431         'browser/sync/test/integration/enable_disable_test.cc',
2432         'browser/sync/test/integration/extension_settings_helper.cc',
2433         'browser/sync/test/integration/extension_settings_helper.h',
2434         'browser/sync/test/integration/extensions_helper.cc',
2435         'browser/sync/test/integration/extensions_helper.h',
2436         'browser/sync/test/integration/migration_errors_test.cc',
2437         'browser/sync/test/integration/multiple_client_bookmarks_sync_test.cc',
2438         'browser/sync/test/integration/multiple_client_dictionary_sync_test.cc',
2439         'browser/sync/test/integration/multiple_client_passwords_sync_test.cc',
2440         'browser/sync/test/integration/multiple_client_preferences_sync_test.cc',
2441         'browser/sync/test/integration/multiple_client_sessions_sync_test.cc',
2442         'browser/sync/test/integration/multiple_client_typed_urls_sync_test.cc',
2443         'browser/sync/test/integration/passwords_helper.cc',
2444         'browser/sync/test/integration/passwords_helper.h',
2445         'browser/sync/test/integration/preferences_helper.cc',
2446         'browser/sync/test/integration/preferences_helper.h',
2447         'browser/sync/test/integration/search_engines_helper.cc',
2448         'browser/sync/test/integration/search_engines_helper.h',
2449         'browser/sync/test/integration/sessions_helper.cc',
2450         'browser/sync/test/integration/sessions_helper.h',
2451         'browser/sync/test/integration/single_client_apps_sync_test.cc',
2452         'browser/sync/test/integration/single_client_bookmarks_sync_test.cc',
2453         'browser/sync/test/integration/single_client_dictionary_sync_test.cc',
2454         'browser/sync/test/integration/single_client_extensions_sync_test.cc',
2455         'browser/sync/test/integration/single_client_managed_user_settings_sync_test.cc',
2456         'browser/sync/test/integration/single_client_passwords_sync_test.cc',
2457         'browser/sync/test/integration/single_client_preferences_sync_test.cc',
2458         'browser/sync/test/integration/single_client_search_engines_sync_test.cc',
2459         'browser/sync/test/integration/single_client_sessions_sync_test.cc',
2460         'browser/sync/test/integration/single_client_themes_sync_test.cc',
2461         'browser/sync/test/integration/single_client_typed_urls_sync_test.cc',
2462         'browser/sync/test/integration/sync_app_helper.cc',
2463         'browser/sync/test/integration/sync_app_helper.h',
2464         'browser/sync/test/integration/sync_datatype_helper.cc',
2465         'browser/sync/test/integration/sync_datatype_helper.h',
2466         'browser/sync/test/integration/sync_errors_test.cc',
2467         'browser/sync/test/integration/sync_extension_helper.cc',
2468         'browser/sync/test/integration/sync_extension_helper.h',
2469         'browser/sync/test/integration/sync_test.cc',
2470         'browser/sync/test/integration/sync_test.h',
2471         'browser/sync/test/integration/themes_helper.cc',
2472         'browser/sync/test/integration/themes_helper.h',
2473         'browser/sync/test/integration/two_client_apps_sync_test.cc',
2474         'browser/sync/test/integration/two_client_autofill_sync_test.cc',
2475         'browser/sync/test/integration/two_client_bookmarks_sync_test.cc',
2476         'browser/sync/test/integration/two_client_dictionary_sync_test.cc',
2477         'browser/sync/test/integration/two_client_extension_settings_and_app_settings_sync_test.cc',
2478         'browser/sync/test/integration/two_client_extensions_sync_test.cc',
2479         'browser/sync/test/integration/two_client_passwords_sync_test.cc',
2480         'browser/sync/test/integration/two_client_preferences_sync_test.cc',
2481         'browser/sync/test/integration/two_client_search_engines_sync_test.cc',
2482         'browser/sync/test/integration/two_client_sessions_sync_test.cc',
2483         'browser/sync/test/integration/two_client_themes_sync_test.cc',
2484         'browser/sync/test/integration/two_client_typed_urls_sync_test.cc',
2485         'browser/sync/test/integration/typed_urls_helper.cc',
2486         'browser/sync/test/integration/typed_urls_helper.h',
2487       ],
2488       'conditions': [
2489         ['toolkit_uses_gtk == 1', {
2490            'dependencies': [
2491              '../build/linux/system.gyp:gtk',
2492            ],
2493         }],
2494         ['toolkit_uses_gtk == 1 or chromeos==1 or (OS=="linux" and use_aura==1)', {
2495           'dependencies': [
2496             '../build/linux/system.gyp:ssl',
2497           ],
2498         }],
2499         ['OS=="mac"', {
2500           # The sync_integration_tests do not run on mac without this flag.
2501           # Search for comments about "xcode_settings" elsewhere in this file.
2502           'xcode_settings': {'OTHER_LDFLAGS': ['-Wl,-ObjC']},
2503           # Dictionary sync is disabled on Mac.
2504           'sources!': [
2505             'browser/sync/test/integration/dictionary_helper.cc',
2506             'browser/sync/test/integration/dictionary_helper.h',
2507             'browser/sync/test/integration/dictionary_load_observer.cc',
2508             'browser/sync/test/integration/dictionary_load_observer.h',
2509             'browser/sync/test/integration/multiple_client_dictionary_sync_test.cc',
2510             'browser/sync/test/integration/single_client_dictionary_sync_test.cc',
2511             'browser/sync/test/integration/two_client_dictionary_sync_test.cc',
2512           ],
2513         }],
2514         ['OS=="win"', {
2515           'sources': [
2516             '<(SHARED_INTERMEDIATE_DIR)/chrome/browser_resources.rc',
2517             '<(SHARED_INTERMEDIATE_DIR)/chrome/chrome_unscaled_resources.rc',
2518             '<(SHARED_INTERMEDIATE_DIR)/chrome/common_resources.rc',
2519             '<(SHARED_INTERMEDIATE_DIR)/chrome/extensions_api_resources.rc',
2520             '<(SHARED_INTERMEDIATE_DIR)/chrome_version/other_version.rc',
2521             '<(SHARED_INTERMEDIATE_DIR)/content/content_resources.rc',
2522             '<(SHARED_INTERMEDIATE_DIR)/net/net_resources.rc',
2523             '<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources/ui_unscaled_resources.rc',
2524             '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_chromium_resources.rc',
2525           ],
2526           'include_dirs': [
2527             '<(DEPTH)/third_party/wtl/include',
2528           ],
2529           'dependencies': [
2530             'chrome_version_resources',
2531           ],
2532           'conditions': [
2533             ['win_use_allocator_shim==1', {
2534               'dependencies': [
2535                 '<(allocator_target)',
2536               ],
2537             }],
2538           ],
2539           'configurations': {
2540             'Debug': {
2541               'msvs_settings': {
2542                 'VCLinkerTool': {
2543                   'LinkIncremental': '<(msvs_debug_link_nonincremental)',
2544                 },
2545               },
2546             },
2547           },
2548         }, { # else: OS != "win"
2549           'sources!': [
2550             'app/chrome_dll.rc',
2551             'app/chrome_version.rc.version',
2552             'test/data/resource.rc',
2553           ],
2554         }],
2555         ['toolkit_views==1', {
2556           'dependencies': [
2557             '../ui/views/views.gyp:views',
2558           ],
2559         }],
2560       ],
2561     },
2562     {
2563       'target_name': 'sync_performance_tests',
2564       'type': 'executable',
2565       'dependencies': [
2566         'browser',
2567         'chrome',
2568         'common/extensions/api/api.gyp:api',
2569         'test_support_common',
2570         '../skia/skia.gyp:skia',
2571         '../sync/sync.gyp:sync',
2572         '../sync/sync.gyp:test_support_sync_testserver',
2573         '../testing/gmock.gyp:gmock',
2574         '../testing/gtest.gyp:gtest',
2575       ],
2576       'include_dirs': [
2577         '..',
2578         '<(INTERMEDIATE_DIR)',
2579         '<(protoc_out_dir)',
2580       ],
2581       'defines': [
2582         'HAS_OUT_OF_PROC_TEST_RUNNER',
2583       ],
2584       'sources': [
2585         'app/chrome_command_ids.h',
2586         'app/chrome_dll.rc',
2587         'app/chrome_dll_resource.h',
2588         'app/chrome_version.rc.version',
2589         'browser/sync/test/integration/autofill_helper.cc',
2590         'browser/sync/test/integration/autofill_helper.h',
2591         'browser/sync/test/integration/bookmarks_helper.cc',
2592         'browser/sync/test/integration/bookmarks_helper.h',
2593         'browser/sync/test/integration/dictionary_helper.cc',
2594         'browser/sync/test/integration/dictionary_helper.h',
2595         'browser/sync/test/integration/dictionary_load_observer.cc',
2596         'browser/sync/test/integration/dictionary_load_observer.h',
2597         'browser/sync/test/integration/extensions_helper.cc',
2598         'browser/sync/test/integration/extensions_helper.h',
2599         'browser/sync/test/integration/passwords_helper.cc',
2600         'browser/sync/test/integration/passwords_helper.h',
2601         'browser/sync/test/integration/performance/autofill_sync_perf_test.cc',
2602         'browser/sync/test/integration/performance/bookmarks_sync_perf_test.cc',
2603         'browser/sync/test/integration/performance/dictionary_sync_perf_test.cc',
2604         'browser/sync/test/integration/performance/extensions_sync_perf_test.cc',
2605         'browser/sync/test/integration/performance/sync_timing_helper.cc',
2606         'browser/sync/test/integration/performance/sync_timing_helper.h',
2607         'browser/sync/test/integration/performance/passwords_sync_perf_test.cc',
2608         'browser/sync/test/integration/performance/sessions_sync_perf_test.cc',
2609         'browser/sync/test/integration/performance/typed_urls_sync_perf_test.cc',
2610         'browser/sync/test/integration/sessions_helper.cc',
2611         'browser/sync/test/integration/sessions_helper.h',
2612         'browser/sync/test/integration/sync_datatype_helper.cc',
2613         'browser/sync/test/integration/sync_datatype_helper.h',
2614         'browser/sync/test/integration/sync_extension_helper.cc',
2615         'browser/sync/test/integration/sync_extension_helper.h',
2616         'browser/sync/test/integration/sync_test.cc',
2617         'browser/sync/test/integration/sync_test.h',
2618         'browser/sync/test/integration/typed_urls_helper.cc',
2619         'browser/sync/test/integration/typed_urls_helper.h',
2620         'test/base/chrome_test_launcher.cc',
2621         'test/data/resource.rc',
2622       ],
2623       'conditions': [
2624         ['toolkit_uses_gtk == 1', {
2625            'dependencies': [
2626              '../build/linux/system.gyp:gtk',
2627            ],
2628         }],
2629         ['toolkit_uses_gtk == 1 or chromeos==1 or (OS=="linux" and use_aura==1)', {
2630           'dependencies': [
2631             '../build/linux/system.gyp:ssl',
2632           ],
2633         }],
2634         ['OS=="mac"', {
2635           # The sync_performance_tests do not run on mac without this flag.
2636           # Search for comments about "xcode_settings" elsewhere in this file.
2637           'xcode_settings': {'OTHER_LDFLAGS': ['-Wl,-ObjC']},
2638           # Dictionary sync is disabled on Mac.
2639           'sources!': [
2640             'browser/sync/test/integration/dictionary_helper.cc',
2641             'browser/sync/test/integration/dictionary_helper.h',
2642             'browser/sync/test/integration/dictionary_load_observer.cc',
2643             'browser/sync/test/integration/dictionary_load_observer.h',
2644             'browser/sync/test/integration/performance/dictionary_sync_perf_test.cc',
2645           ],
2646         }],
2647         ['OS=="win"', {
2648           'sources': [
2649             '<(SHARED_INTERMEDIATE_DIR)/chrome/browser_resources.rc',
2650             '<(SHARED_INTERMEDIATE_DIR)/chrome/chrome_unscaled_resources.rc',
2651             '<(SHARED_INTERMEDIATE_DIR)/chrome/common_resources.rc',
2652             '<(SHARED_INTERMEDIATE_DIR)/chrome/extensions_api_resources.rc',
2653             '<(SHARED_INTERMEDIATE_DIR)/chrome_version/other_version.rc',
2654           ],
2655           'include_dirs': [
2656             '<(DEPTH)/third_party/wtl/include',
2657           ],
2658           'dependencies': [
2659             'chrome_version_resources',
2660           ],
2661           'conditions': [
2662             ['win_use_allocator_shim==1', {
2663               'dependencies': [
2664                 '<(allocator_target)',
2665               ],
2666             }],
2667           ],
2668           'configurations': {
2669             'Debug': {
2670               'msvs_settings': {
2671                 'VCLinkerTool': {
2672                   'LinkIncremental': '<(msvs_debug_link_nonincremental)',
2673                 },
2674               },
2675             },
2676           },
2677         }, { # else: OS != "win"
2678           'sources!': [
2679             'app/chrome_dll.rc',
2680             'app/chrome_version.rc.version',
2681             'test/data/resource.rc',
2682           ],
2683         }],
2684         ['toolkit_views==1', {
2685           'dependencies': [
2686             '../ui/views/views.gyp:views',
2687           ],
2688         }],
2689       ],
2690     },
2691     {
2692       # Executable that contains all the tests to be run on the GPU bots.
2693       'target_name': 'gpu_tests',
2694       'type': 'executable',
2695       'dependencies': [
2696         # Runtime dependencies
2697         '../third_party/mesa/mesa.gyp:osmesa',
2698       ],
2699       'includes': [
2700         'test/gpu/test_support_gpu.gypi'
2701       ],
2702       'sources': [
2703         'test/gpu/gpu_feature_browsertest.cc',
2704       ],
2705     },
2706     {
2707       # Executable that contains a subset of the gpu tests which are run with a
2708       # software rasterizer.
2709       'target_name': 'soft_gpu_tests',
2710       'type': 'executable',
2711       'includes': [
2712         'test/gpu/test_support_gpu.gypi'
2713       ],
2714       'sources': [
2715         'test/gpu/gpu_pixel_browsertest.cc',
2716       ],
2717     },
2718   ],
2719   'conditions': [
2720     ['OS=="mac"', {
2721       'targets': [
2722         {
2723           # This is the mac equivalent of the security_tests target below. It
2724           # generates a framework bundle which bundles tests to be run in a
2725           # renderer process. The test code is built as a framework so it can be
2726           # run in the context of a renderer without shipping the code to end
2727           # users.
2728           'target_name': 'renderer_sandbox_tests',
2729           'type': 'shared_library',
2730           'product_name': 'Renderer Sandbox Tests',
2731           'mac_bundle': 1,
2732           'xcode_settings': {
2733             'INFOPLIST_FILE': 'test/security_tests/sandbox_tests_mac-Info.plist',
2734           },
2735           'sources': [
2736             'test/security_tests/renderer_sandbox_tests_mac.mm',
2737           ],
2738           'include_dirs': [
2739             '..',
2740           ],
2741           'link_settings': {
2742             'libraries': [
2743               '$(SDKROOT)/System/Library/Frameworks/Cocoa.framework',
2744             ],
2745           },
2746         },  # target renderer_sandbox_tests
2747         {
2748           # Tests for Mac app launcher.
2749           'target_name': 'app_mode_app_tests',
2750           'type': 'executable',
2751           'product_name': 'app_mode_app_tests',
2752           'dependencies': [
2753             '../base/base.gyp:test_support_base',
2754             '../chrome/common_constants.gyp:common_constants',
2755             '../testing/gtest.gyp:gtest',
2756             'chrome.gyp:chrome',  # run time dependency
2757             'app_mode_app_support',
2758           ],
2759           'sources': [
2760             'common/mac/app_mode_chrome_locator_unittest.mm',
2761             'test/base/app_mode_app_tests.cc',
2762           ],
2763           'include_dirs': [
2764             '..',
2765           ],
2766           'link_settings': {
2767             'libraries': [
2768               '$(SDKROOT)/System/Library/Frameworks/CoreFoundation.framework',
2769               '$(SDKROOT)/System/Library/Frameworks/Foundation.framework',
2770             ],
2771           },
2772         },  # target app_mode_app_tests
2773       ],
2774     }],
2775     ['OS!="mac"', {
2776       'targets': [
2777         {
2778           'target_name': 'perf_tests',
2779           'type': 'executable',
2780           'include_dirs': [
2781             '<(SHARED_INTERMEDIATE_DIR)',  # Needed by key_systems.cc.
2782           ],
2783           'dependencies': [
2784             'browser',
2785             'chrome_resources.gyp:chrome_resources',
2786             'chrome_resources.gyp:chrome_strings',
2787             'common',
2788             'renderer',
2789             '../content/content.gyp:content_gpu',
2790             '../content/content.gyp:test_support_content',
2791             '../base/base.gyp:base',
2792             '../base/base.gyp:test_support_base',
2793             '../base/base.gyp:test_support_perf',
2794             '../skia/skia.gyp:skia',
2795             '../testing/gtest.gyp:gtest',
2796             '../webkit/support/webkit_support.gyp:glue',
2797             '../third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
2798           ],
2799           'sources': [
2800             'test/perf/perftests.cc',
2801             'test/perf/url_parse_perftest.cc',
2802             '../content/browser/net/sqlite_persistent_cookie_store_perftest.cc',
2804             # TODO(boliu): Move this to a separate components_perftest target
2805             # under components/.
2806             '../components/visitedlink/test/visitedlink_perftest.cc',
2807           ],
2808           'conditions': [
2809             ['use_x11==1', {
2810               'dependencies': [
2811                 '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
2812               ],
2813             }],
2814             ['toolkit_uses_gtk == 1', {
2815               'dependencies': [
2816                 '../build/linux/system.gyp:gtk',
2817               ],
2818             }],
2819             ['OS=="win"', {
2820               'configurations': {
2821                 'Debug_Base': {
2822                   'msvs_settings': {
2823                     'VCLinkerTool': {
2824                       'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
2825                     },
2826                   },
2827                 },
2828               },
2829               'conditions': [
2830                 ['win_use_allocator_shim==1', {
2831                   'dependencies': [
2832                     '<(allocator_target)',
2833                   ],
2834                 }],
2835               ],
2836             }],
2837             ['toolkit_views==1', {
2838               'dependencies': [
2839                 '../ui/views/views.gyp:views',
2840               ],
2841             }],
2842             ['os_posix == 1 and OS != "mac" and OS != "android"', {
2843               'conditions': [
2844                 ['linux_use_tcmalloc==1', {
2845                   'dependencies': [
2846                     '../base/allocator/allocator.gyp:allocator',
2847                   ],
2848                 }],
2849               ],
2850             }],
2851             ['OS=="linux" and enable_webrtc==1', {
2852               'dependencies': [
2853                 # TODO(tommi): Figure out why the 32bit lucid builder fails to
2854                 # find this dependency for this target (other builders pick it up
2855                 # correctly).  crbug.com/231068.
2856                 '../third_party/libjingle/libjingle.gyp:libpeerconnection',
2857               ],
2858             }],
2859           ],
2860         },
2861       ],
2862     },],  # OS!="mac"
2863     ['OS=="win"', {
2864       'targets': [
2865         {
2866           'target_name': 'security_tests',
2867           'type': 'shared_library',
2868           'include_dirs': [
2869             '..',
2870           ],
2871           'sources': [
2872             'test/security_tests/ipc_security_tests.cc',
2873             'test/security_tests/ipc_security_tests.h',
2874             'test/security_tests/security_tests.cc',
2875             '../sandbox/win/tests/validation_tests/commands.cc',
2876             '../sandbox/win/tests/validation_tests/commands.h',
2877           ],
2878         },
2879       ]},  # 'targets'
2880     ],  # OS=="win"
2881     ['OS=="linux" or OS=="win"', {
2882       'targets': [
2883         {
2884           'target_name': 'generate_profile',
2885           'type': 'executable',
2886           'dependencies': [
2887             'test_support_common',
2888             'browser',
2889             'renderer',
2890             'chrome_resources.gyp:packed_resources',
2891             '../base/base.gyp:base',
2892             '../net/net.gyp:net_test_support',
2893             '../skia/skia.gyp:skia',
2894             '../sync/sync.gyp:sync',
2895           ],
2896           'include_dirs': [
2897             '..',
2898           ],
2899           'sources': [
2900             'tools/profiles/generate_profile.cc',
2901             'tools/profiles/thumbnail-inl.h',
2902           ],
2903           'conditions': [
2904             ['OS=="win"', {
2905               'conditions': [
2906                 ['win_use_allocator_shim==1', {
2907                   'dependencies': [
2908                     '<(allocator_target)',
2909                   ],
2910                 }],
2911               ],
2912               'configurations': {
2913                 'Debug_Base': {
2914                   'msvs_settings': {
2915                     'VCLinkerTool': {
2916                       'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
2917                     },
2918                   },
2919                 },
2920               },
2921             }],
2922           ],
2923         },
2924       ]},  # 'targets'
2925     ],
2926     # If you change this condition, make sure you also change it in all.gyp
2927     # for the chromium_builder_qa target.
2928     ['enable_automation==1 and (OS=="mac" or ((OS=="win" or os_posix==1) and target_arch==python_arch))', {
2929       'targets': [
2930         {
2931           # Documentation: http://dev.chromium.org/developers/testing/pyauto
2932           'target_name': 'pyautolib',
2933           'type': 'loadable_module',
2934           'product_prefix': '_',
2935           'dependencies': [
2936             'chrome',
2937             'chrome_resources.gyp:chrome_resources',
2938             'chrome_resources.gyp:chrome_strings',
2939             'chrome_resources.gyp:theme_resources',
2940             'debugger',
2941             'test_support_common',
2942             '../skia/skia.gyp:skia',
2943             '../sync/sync.gyp:sync',
2944             '../testing/gtest.gyp:gtest',
2945           ],
2946           'export_dependent_settings': [
2947             'test_support_common',
2948           ],
2949           'include_dirs': [
2950             '..',
2951           ],
2952           'cflags': [
2953              '-Wno-uninitialized',
2954              '-Wno-self-assign',  # to keep clang happy for generated code.
2955           ],
2956           'sources': [
2957             'test/automation/proxy_launcher.cc',
2958             'test/automation/proxy_launcher.h',
2959             'test/pyautolib/pyautolib.cc',
2960             'test/pyautolib/pyautolib.h',
2961             'test/ui/ui_test.cc',
2962             'test/ui/ui_test.h',
2963             'test/ui/ui_test_suite.cc',
2964             'test/ui/ui_test_suite.h',
2965             '<(INTERMEDIATE_DIR)/pyautolib_wrap.cc',
2966             '<@(pyautolib_sources)',
2967           ],
2968           'xcode_settings': {
2969             # Link with python2.6. Using -L/usr/lib and -lpython2.6 does not
2970             # work with the -isysroot argument passed in. Even if it did,
2971             # the linker shouldn't use any other lib not in the 10.5 sdk.
2972             'OTHER_LDFLAGS': [
2973               '/usr/lib/libpython2.6.dylib'
2974             ],
2975           },
2976           'msvs_disabled_warnings': [4211],
2977           'conditions': [
2978             # Disable the type profiler. _POSIX_C_SOURCE and _XOPEN_SOURCE
2979             # conflict between <Python.h> and <typeinfo>.
2980             ['OS=="linux" and clang_type_profiler==1', {
2981               'cflags_cc!': [
2982                 '-fintercept-allocation-functions',
2983               ],
2984             }],
2985             ['os_posix == 1 and OS!="mac"', {
2986               'include_dirs': [
2987                 '..',
2988                 '<(sysroot)/usr/include/python<(python_ver)',
2989               ],
2990               'link_settings': {
2991                 'libraries': [
2992                   '-lpython<(python_ver)',
2993                 ],
2994               },
2995             }],
2996             ['toolkit_uses_gtk == 1', {
2997               'dependencies': [
2998                 '../build/linux/system.gyp:gtk',
2999               ],
3000             }],
3001             ['OS=="mac"', {
3002               'include_dirs': [
3003                 '..',
3004                 '/usr/include/python2.6',
3005               ],
3006             }],
3007             ['OS=="win"', {
3008               'product_extension': 'pyd',
3009               'include_dirs': [
3010                 '..',
3011                 '../third_party/python_26/include',
3012               ],
3013               'msvs_settings': {
3014                 'VCLinkerTool': {
3015                   'AdditionalLibraryDirectories': [
3016                     '<(DEPTH)/third_party/python_26/libs',
3017                   ],
3018                   'AdditionalDependencies': [
3019                     'python26.lib',
3020                   ],
3021                 },
3022               }
3023             }],
3024             ['clang == 1', {
3025               'xcode_settings': {
3026                 'WARNING_CFLAGS': [
3027                   # swig creates code with self assignments.
3028                   '-Wno-self-assign',
3029                 ],
3030               },
3031               'cflags': [
3032                 '-Wno-self-assign',
3033               ],
3034             }],
3035             ['asan==1', {
3036               'cflags!': [ '-fsanitize=address' ],
3037               'xcode_settings': { 'OTHER_CFLAGS!': [ '-fsanitize=address' ] },
3038             }],
3039           ],
3040           'actions': [
3041             {
3042               'variables' : {
3043                 'swig_args': [ '-I..',
3044                                '-python',
3045                                '-c++',
3046                                '-threads',
3047                                '-outdir',
3048                                '<(PRODUCT_DIR)',
3049                                '-o',
3050                                '<(INTERMEDIATE_DIR)/pyautolib_wrap.cc',
3051                 ],
3052                 'conditions': [
3053                   ['chromeos==1', {
3054                     'swig_args': [
3055                       '-DOS_CHROMEOS',
3056                     ]
3057                   }],
3058                 ],
3059               },
3060               'action_name': 'pyautolib_swig',
3061               'inputs': [
3062                 'test/pyautolib/argc_argv.i',
3063                 'test/pyautolib/pyautolib.i',
3064                 '<@(pyautolib_sources)',
3065               ],
3066               'outputs': [
3067                 '<(INTERMEDIATE_DIR)/pyautolib_wrap.cc',
3068                 '<(PRODUCT_DIR)/pyautolib.py',
3069               ],
3070               'action': [ 'python',
3071                           '../tools/swig/swig.py',
3072                           '<@(swig_args)',
3073                           'test/pyautolib/pyautolib.i',
3074               ],
3075               'message': 'Generating swig wrappers for pyautolib.',
3076               'msvs_cygwin_shell': 1,
3077             },
3078           ],  # actions
3079         },  # target 'pyautolib'
3080         {
3081           # Required for WebRTC PyAuto tests.
3082           'target_name': 'webrtc_test_tools',
3083           'type': 'none',
3084           'dependencies': [
3085             'pyautolib',
3086             '../third_party/libjingle/libjingle.gyp:peerconnection_server',
3087             '../third_party/webrtc/tools/tools.gyp:frame_analyzer',
3088             '../third_party/webrtc/tools/tools.gyp:rgba_to_i420_converter',
3089           ],
3090         },  # target 'webrtc_test_tools'
3091       ]  # targets
3092     }],
3093     # To enable the coverage targets, do
3094     #    GYP_DEFINES='coverage=1' gclient sync
3095     # To match the coverage buildbot more closely, do this:
3096     #    GYP_DEFINES='coverage=1 enable_svg=0 fastbuild=1' gclient sync
3097     # (and, on MacOS, be sure to switch your SDK from "Base SDK" to "Mac OS X
3098     # 10.6")
3099     # (but on Windows, don't set the fastbuild=1 because it removes the PDB
3100     # generation which is necessary for code coverage.)
3101     ['coverage!=0',
3102       { 'targets': [
3103         {
3104           ### Coverage BUILD AND RUN.
3105           ### Not named coverage_build_and_run for historical reasons.
3106           'target_name': 'coverage',
3107           'dependencies': [ 'coverage_build', 'coverage_run' ],
3108           # do NOT place this in the 'all' list; most won't want it.
3109           # In gyp, booleans are 0/1 not True/False.
3110           'suppress_wildcard': 1,
3111           'type': 'none',
3112           'actions': [
3113             {
3114               'message': 'Coverage is now complete.',
3115               # MSVS must have an input file and an output file.
3116               'inputs': [ '<(PRODUCT_DIR)/coverage.info' ],
3117               'outputs': [ '<(PRODUCT_DIR)/coverage-build-and-run.stamp' ],
3118               'action_name': 'coverage',
3119               # Wish gyp had some basic builtin commands (e.g. 'touch').
3120               'action': [ 'python', '-c',
3121                           'import os; ' \
3122                           'open(' \
3123                           '\'<(PRODUCT_DIR)\' + os.path.sep + ' \
3124                           '\'coverage-build-and-run.stamp\'' \
3125                           ', \'w\').close()' ],
3126               # Use outputs of this action as inputs for the main target build.
3127               # Seems as a misnomer but makes this happy on Linux (scons).
3128               'process_outputs_as_sources': 1,
3129             },
3130           ],  # 'actions'
3131         },
3132         ### Coverage BUILD.  Compile only; does not run the bundles.
3133         ### Intended as the build phase for our coverage bots.
3134         ###
3135         ### Builds unit test bundles needed for coverage.
3136         ### Outputs this list of bundles into coverage_bundles.py.
3137         ###
3138         ### If you want to both build and run coverage from your IDE,
3139         ### use the 'coverage' target.
3140         {
3141           'target_name': 'coverage_build',
3142           # do NOT place this in the 'all' list; most won't want it.
3143           # In gyp, booleans are 0/1 not True/False.
3144           'suppress_wildcard': 1,
3145           'type': 'none',
3146           'dependencies': [
3147             'automated_ui_tests',
3148             '../base/base.gyp:base_unittests',
3149             # browser_tests's use of subprocesses chokes gcov on 10.6?
3150             # Disabling for now (enabled on linux/windows below).
3151             # 'browser_tests',
3152             '../ipc/ipc.gyp:ipc_tests',
3153             '../media/media.gyp:media_unittests',
3154             '../net/net.gyp:net_unittests',
3155             '../printing/printing.gyp:printing_unittests',
3156             '../remoting/remoting.gyp:remoting_unittests',
3157             '../sql/sql.gyp:sql_unittests',
3158             '../content/content.gyp:content_unittests',
3159             'unit_tests',
3160             '../sync/sync.gyp:sync_unit_tests',
3161           ],  # 'dependencies'
3162           'conditions': [
3163             ['OS=="win"', {
3164               'dependencies': [
3165                 # Courgette has not been ported from Windows.
3166                 # Note build/win/chrome_win.croc uniquely has the
3167                 # courgette source directory in an include path.
3168                 '../courgette/courgette.gyp:courgette_unittests',
3169                 'browser_tests',
3170                 ]}],
3171             ['OS=="linux"', {
3172               'dependencies': [
3173                 # Win bot needs to be turned into an interactive bot.
3174                 'interactive_ui_tests',
3175                 # Disabled from running in coverage_posix.py.
3176                 # We need to build this during compile step, so enabling here.
3177                 '../content/content.gyp:content_browsertests',
3178                 '../courgette/courgette.gyp:courgette_unittests',
3179                 '../crypto/crypto.gyp:crypto_unittests',
3180                 '../jingle/jingle.gyp:jingle_unittests',
3181                 '../net/net.gyp:net_perftests',
3182                 '../third_party/WebKit/Source/WebKit/chromium/WebKitUnitTests.gyp:webkit_unit_tests',
3183                 '../url/url.gyp:googleurl_unittests',
3184                 'browser_tests',
3185                 'chromedriver_unittests',
3186                 'gpu_tests',
3187                 'performance_ui_tests',
3188                 'pyautolib',
3189                 'reliability_tests',
3190                 'sync_integration_tests',
3191               ]}],
3192             ['OS=="mac"', {
3193               'dependencies': [
3194               # Placeholder; empty for now.
3195               ]}],
3196           ],  # 'conditions'
3197           'actions': [
3198             {
3199               # 'message' for Linux/scons in particular.  Scons
3200               # requires the 'coverage' target be run from within
3201               # src/chrome.
3202               'message': 'Compiling coverage bundles.',
3203               # MSVS must have an input file and an output file.
3204               #
3205               # TODO(jrg):
3206               # Technically I want inputs to be the list of
3207               # executables created in <@(_dependencies) but use of
3208               # that variable lists the dep by dep name, not their
3209               # output executable name.
3210               # Is there a better way to force this action to run, always?
3211               #
3212               # If a test bundle is added to this coverage_build target it
3213               # necessarily means this file (chrome_tests.gypi) is changed,
3214               # so the action is run (coverage_bundles.py is generated).
3215               # Exceptions to that rule are theoretically possible
3216               # (e.g. re-gyp with a GYP_DEFINES set).
3217               # Else it's the same list of bundles as last time.  They are
3218               # built (since on the deps list) but the action may not run.
3219               # For now, things work, but it's less than ideal.
3220               'inputs': [ 'chrome_tests.gypi' ],
3221               'outputs': [ '<(PRODUCT_DIR)/coverage_bundles.py' ],
3222               'action_name': 'coverage_build',
3223               'action': [ 'python', '-c',
3224                           'import os; '
3225                           'f = open(' \
3226                           '\'<(PRODUCT_DIR)\' + os.path.sep + ' \
3227                           '\'coverage_bundles.py\'' \
3228                           ', \'w\'); ' \
3229                           'deplist = \'' \
3230                           '<@(_dependencies)' \
3231                           '\'.split(\' \'); ' \
3232                           'f.write(str(deplist)); ' \
3233                           'f.close()'],
3234               # Use outputs of this action as inputs for the main target build.
3235               # Seems as a misnomer but makes this happy on Linux (scons).
3236               'process_outputs_as_sources': 1,
3237             },
3238           ],  # 'actions'
3239         },
3240         ### Coverage RUN.  Does not compile the bundles.  Mirrors the
3241         ### run_coverage_bundles buildbot phase.  If you update this
3242         ### command update the mirror in
3243         ### $BUILDBOT/scripts/master/factory/chromium_commands.py.
3244         ### If you want both build and run, use the 'coverage' target.
3245         {
3246           'target_name': 'coverage_run',
3247           # do NOT place this in the 'all' list; most won't want it.
3248           # In gyp, booleans are 0/1 not True/False.
3249           'suppress_wildcard': 1,
3250           'type': 'none',
3251           'actions': [
3252             {
3253               # 'message' for Linux/scons in particular.  Scons
3254               # requires the 'coverage' target be run from within
3255               # src/chrome.
3256               'message': 'Running the coverage script.  NOT building anything.',
3257               # MSVS must have an input file and an output file.
3258               'inputs': [ '<(PRODUCT_DIR)/coverage_bundles.py' ],
3259               'outputs': [ '<(PRODUCT_DIR)/coverage.info' ],
3260               'action_name': 'coverage_run',
3261               'action': [ 'python',
3262                           '../tools/code_coverage/coverage_posix.py',
3263                           '--directory',
3264                           '<(PRODUCT_DIR)',
3265                           '--src_root',
3266                           '..',
3267                           '--bundles',
3268                           '<(PRODUCT_DIR)/coverage_bundles.py'],
3269               # Use outputs of this action as inputs for the main target build.
3270               # Seems as a misnomer but makes this happy on Linux (scons).
3271               'process_outputs_as_sources': 1,
3272             },
3273           ],  # 'actions'
3274         },
3275       ]
3276     }],  # 'coverage!=0'
3277     ['OS == "android"', {
3278       'targets': [
3279         {
3280           'target_name': 'chromium_testshell_test_apk',
3281           'type': 'none',
3282           'dependencies': [
3283             'chrome_java',
3284             'chromium_testshell_java',
3285             '../base/base.gyp:base',
3286             '../base/base.gyp:base_java_test_support',
3287             '../content/content.gyp:content_java_test_support',
3288             '../sync/sync.gyp:sync_javatests',
3289             '../tools/android/forwarder/forwarder.gyp:forwarder',
3290           ],
3291           'variables': {
3292             'apk_name': 'ChromiumTestShellTest',
3293             'java_in_dir': 'android/testshell/javatests',
3294             'resource_dir': 'android/testshell/res',
3295             'additional_src_dirs': ['android/javatests/src'],
3296             'is_test_apk': 1,
3297           },
3298           'includes': [ '../build/java_apk.gypi' ],
3299         },
3300         {
3301           'target_name': 'chromium_testshell_uiautomator_tests_java',
3302           'type': 'none',
3303           'variables': {
3304             'java_in_dir': 'android/uiautomator_tests',
3305           },
3306           'dependencies': [
3307             '../base/base.gyp:base_java_test_support',
3308             '../third_party/android_tools/android_tools.gyp:uiautomator_jar',
3309           ],
3310           'includes': [ '../build/java.gypi' ],
3311         },
3312         {
3313           'target_name': 'chromium_testshell_uiautomator_tests',
3314           'type': 'none',
3315           'dependencies': [
3316             'chromium_testshell_uiautomator_tests_java',
3317           ],
3318           'includes': [ '../build/uiautomator_test.gypi' ],
3319         },
3320       ],
3321     }],
3322     ['test_isolation_mode != "noop"', {
3323       'targets': [
3324         {
3325           'target_name': 'browser_tests_run',
3326           'type': 'none',
3327           'dependencies': [
3328             'browser_tests',
3329             'chrome',
3330             '../webkit/webkit.gyp:pull_in_DumpRenderTree',
3331           ],
3332           'includes': [
3333             '../build/isolate.gypi',
3334             'browser_tests.isolate',
3335           ],
3336           'sources': [
3337             'browser_tests.isolate',
3338           ],
3339         },
3340         {
3341           'target_name': 'interactive_ui_tests_run',
3342           'type': 'none',
3343           'dependencies': [
3344             'interactive_ui_tests',
3345           ],
3346           'conditions': [
3347             ['use_x11 == 1', {
3348               'dependencies': [
3349                 '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
3350               ],
3351             }],
3352           ],
3353           'includes': [
3354             '../build/isolate.gypi',
3355             'interactive_ui_tests.isolate',
3356           ],
3357           'sources': [
3358             'interactive_ui_tests.isolate',
3359           ],
3360         },
3361         {
3362           'target_name': 'sync_integration_tests_run',
3363           'type': 'none',
3364           'dependencies': [
3365             'sync_integration_tests',
3366           ],
3367           'conditions': [
3368             ['use_x11 == 1', {
3369               'dependencies': [
3370                 '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
3371               ],
3372             }],
3373           ],
3374           'includes': [
3375             '../build/isolate.gypi',
3376             'sync_integration_tests.isolate',
3377           ],
3378           'sources': [
3379             'sync_integration_tests.isolate',
3380           ],
3381         },
3382       ],
3383     }],
3384     ['OS=="win"', {
3385       'targets' : [
3386         {
3387           # This target is only depended upon in Windows.
3388           'target_name': 'automated_ui_tests_exe_pdb_workaround',
3389           'type': 'static_library',
3390           'sources': [ 'empty_pdb_workaround.cc' ],
3391           'msvs_settings': {
3392             'VCCLCompilerTool': {
3393               # This *in the compile phase* must match the pdb name that's
3394               # output by the final link. See empty_pdb_workaround.cc for
3395               # more details.
3396               'DebugInformationFormat': '3',
3397               'ProgramDataBaseFileName': '<(PRODUCT_DIR)/automated_ui_tests.exe.pdb',
3398             },
3399           },
3400         },
3401         {
3402           # This target is only depended upon in Windows.
3403           'target_name': 'browser_tests_exe_pdb_workaround',
3404           'type': 'static_library',
3405           'sources': [ 'empty_pdb_workaround.cc' ],
3406           'msvs_settings': {
3407             'VCCLCompilerTool': {
3408               # This *in the compile phase* must match the pdb name that's
3409               # output by the final link. See empty_pdb_workaround.cc for
3410               # more details.
3411               'DebugInformationFormat': '3',
3412               'ProgramDataBaseFileName': '<(PRODUCT_DIR)/browser_tests.exe.pdb',
3413             },
3414           },
3415         },
3416       ],
3417     }],
3418   ],  # 'conditions'