Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / extensions / extensions_tests.gyp
blob31e6caaec8d5dfbcf46ad3ef6d9bc9f6cab3796b
2   'includes': [
3     'extensions_tests.gypi',
4   ],
5   'variables': {
6     # Product name is used for Mac bundle.
7     'app_shell_product_name': 'App Shell',
8     # The version is high enough to be supported by Omaha (at least 31)
9     # but fake enough to be obviously not a Chrome release.
10     'app_shell_version': '38.1234.5678.9',
11     'chromium_code': 1,
12   },
13   'targets': [
14     {
15       'target_name': 'extensions_unittests',
16       'type': 'executable',
17       'dependencies': [
18         '../base/base.gyp:base',
19         '../base/base.gyp:test_support_base',
20         '../components/components.gyp:keyed_service_content',
21         '../components/components.gyp:pref_registry_test_support',
22         '../components/components.gyp:user_prefs',
23         '../content/content_shell_and_tests.gyp:test_support_content',
24         '../device/bluetooth/bluetooth.gyp:device_bluetooth_mocks',
25         '../device/core/core.gyp:device_core',
26         '../device/hid/hid.gyp:device_hid',
27         '../device/serial/serial.gyp:device_serial',
28         '../device/serial/serial.gyp:device_serial_test_util',
29         '../mojo/mojo_base.gyp:mojo_application_bindings',
30         '../mojo/mojo_base.gyp:mojo_environment_chromium',
31         '../testing/gmock.gyp:gmock',
32         '../testing/gtest.gyp:gtest',
33         '../third_party/leveldatabase/leveldatabase.gyp:leveldatabase',
34         '../third_party/mojo/mojo_edk.gyp:mojo_js_lib',
35         '../third_party/mojo/mojo_edk.gyp:mojo_system_impl',
36         '../third_party/mojo/mojo_public.gyp:mojo_cpp_bindings',
37         'common/api/api.gyp:cast_channel_proto',
38         'extensions.gyp:extensions_browser',
39         'extensions.gyp:extensions_common',
40         'extensions.gyp:extensions_renderer',
41         'extensions.gyp:extensions_shell_and_test_pak',
42         'extensions.gyp:extensions_test_support',
43         'extensions.gyp:extensions_utility',
44         'extensions_resources.gyp:extensions_resources',
45         'extensions_strings.gyp:extensions_strings',
46       ],
47       # Needed for third_party libraries like leveldb.
48       'include_dirs': [
49         '..',
50       ],
51       'sources': [
52         '<@(extensions_unittests_sources)',
53       ],
54       # Disable c4267 warnings until we fix size_t to int truncations.
55       'msvs_disabled_warnings': [ 4267, ],
56       'conditions': [
57         ['OS=="win" and win_use_allocator_shim==1', {
58           'dependencies': [
59             '../base/allocator/allocator.gyp:allocator',
60           ],
61         }],
62         ['chromeos==1', {
63           'dependencies': [
64             '<(DEPTH)/chromeos/chromeos.gyp:chromeos_test_support',
65           ],
66         }],
67       ],
68     },
69     {
70       # GN version: //extensions:extensions_browsertests
71       'target_name': 'extensions_browsertests',
72       'type': '<(gtest_target_type)',
73       'dependencies': [
74         'extensions.gyp:extensions_test_support',
75         'shell/app_shell.gyp:app_shell_lib',
76         # TODO(yoz): find the right deps
77         '<(DEPTH)/base/base.gyp:test_support_base',
78         '<(DEPTH)/components/components.gyp:guest_view_browser',
79         '<(DEPTH)/components/components.gyp:guest_view_renderer',
80         '<(DEPTH)/components/components.gyp:guest_view_test_support',
81         '<(DEPTH)/content/content.gyp:content_app_both',
82         '<(DEPTH)/content/content_shell_and_tests.gyp:content_browser_test_support',
83         '<(DEPTH)/content/content_shell_and_tests.gyp:test_support_content',
84         '<(DEPTH)/device/bluetooth/bluetooth.gyp:device_bluetooth_mocks',
85         '<(DEPTH)/device/usb/usb.gyp:device_usb_mocks',
86         '<(DEPTH)/testing/gmock.gyp:gmock',
87         '<(DEPTH)/testing/gtest.gyp:gtest',
88       ],
89       'defines': [
90         'HAS_OUT_OF_PROC_TEST_RUNNER',
91       ],
92       'sources': [
93         '<@(extensions_browsertests_sources)',
94       ],
95       'conditions': [
96         ['OS=="win" and win_use_allocator_shim==1', {
97           'dependencies': [
98             '<(DEPTH)/base/allocator/allocator.gyp:allocator',
99           ],
100         }],
101         ['OS=="mac"', {
102           'dependencies': [
103             'shell/app_shell.gyp:app_shell',  # Needed for App Shell.app's Helper.
104           ],
105         }],
106         # This is only here to keep gyp happy. This target never builds on
107         # mobile platforms.
108         ['OS != "ios" and OS != "android"', {
109           'dependencies': [
110             '<(DEPTH)/components/components.gyp:storage_monitor_test_support',
111           ],
112         }],
113       ]
114     },
115   ],
116   'conditions': [
117     ['test_isolation_mode != "noop"', {
118       'targets': [
119         {
120           'target_name': 'extensions_browsertests_run',
121           'type': 'none',
122           'dependencies': [
123             'extensions_browsertests',
124           ],
125           'includes': [
126             '../build/isolate.gypi',
127           ],
128           'sources': [
129             'extensions_browsertests.isolate',
130           ],
131         },
132         {
133           'target_name': 'extensions_unittests_run',
134           'type': 'none',
135           'dependencies': [
136             'extensions_unittests',
137           ],
138           'includes': [
139             '../build/isolate.gypi',
140           ],
141           'sources': [
142             'extensions_unittests.isolate',
143           ],
144           'conditions': [
145             ['use_x11 == 1', {
146               'dependencies': [
147                 '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
148               ],
149             }],
150           ],
151         }
152       ],
153     }],
154   ],