OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/config/features.gni") | 5 import("//build/config/features.gni") |
6 import("//build/config/ui.gni") | 6 import("//build/config/ui.gni") |
7 import("//testing/test.gni") | 7 import("//testing/test.gni") |
8 | 8 |
9 gypi_values = exec_script("//build/gypi_to_gn.py", | 9 gypi_values = exec_script("//build/gypi_to_gn.py", |
10 [ rebase_path("views.gyp") ], | 10 [ rebase_path("views.gyp") ], |
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 deps += [ "//ui/aura:test_support" ] | 151 deps += [ "//ui/aura:test_support" ] |
152 } | 152 } |
153 if (use_x11) { | 153 if (use_x11) { |
154 deps += [ "//ui/gfx/x" ] | 154 deps += [ "//ui/gfx/x" ] |
155 } | 155 } |
156 if (use_ozone || !use_x11) { | 156 if (use_ozone || !use_x11) { |
157 sources -= [ "test/x11_property_change_waiter.cc" ] | 157 sources -= [ "test/x11_property_change_waiter.cc" ] |
158 } | 158 } |
159 } | 159 } |
160 | 160 |
161 test("views_unittests") { | 161 if (!is_win || link_chrome_on_windows) { |
162 sources = gypi_values.views_unittests_sources | 162 test("views_unittests") { |
| 163 sources = gypi_values.views_unittests_sources |
163 | 164 |
164 deps = [ | 165 deps = [ |
165 ":test_support", | 166 ":test_support", |
166 "//base", | 167 "//base", |
167 "//base:i18n", | 168 "//base:i18n", |
168 "//base/allocator", | 169 "//base/allocator", |
169 "//base/test:test_support", | 170 "//base/test:test_support", |
170 "//skia", | 171 "//skia", |
171 "//testing/gtest", | 172 "//testing/gtest", |
172 "//third_party/icu", | 173 "//third_party/icu", |
173 "//ui/accessibility", | 174 "//ui/accessibility", |
174 "//ui/aura", | 175 "//ui/aura", |
175 "//ui/base", | 176 "//ui/base", |
176 "//ui/base:test_support", | 177 "//ui/base:test_support", |
177 "//ui/compositor:test_support", | 178 "//ui/compositor:test_support", |
178 "//ui/events:test_support", | 179 "//ui/events:test_support", |
179 "//ui/events:events_base", | 180 "//ui/events:events_base", |
180 "//ui/events/platform", | 181 "//ui/events/platform", |
181 "//ui/gfx", | 182 "//ui/gfx", |
182 "//ui/gfx/geometry", | 183 "//ui/gfx/geometry", |
183 "//ui/gl", | 184 "//ui/gl", |
184 "//ui/resources", | 185 "//ui/resources", |
185 "//ui/strings", | 186 "//ui/strings", |
186 "//ui/wm", | 187 "//ui/wm", |
187 "//url", | 188 "//url", |
188 ] | |
189 | |
190 if (is_chromeos) { | |
191 sources -= [ "ime/input_method_bridge_unittest.cc" ] | |
192 } | |
193 | |
194 if (is_win) { | |
195 deps += [ | |
196 "//third_party/iaccessible2", | |
197 "//third_party/wtl", | |
198 ] | |
199 libs = [ | |
200 "imm32.lib", | |
201 "oleacc.lib", | |
202 "comctl32.lib", | |
203 ] | 189 ] |
204 | 190 |
205 # TOOD(GYP) | 191 if (is_chromeos) { |
206 #'msvs_settings': { | 192 sources -= [ "ime/input_method_bridge_unittest.cc" ] |
207 # 'VCManifestTool': { | 193 } |
208 # 'AdditionalManifestFiles': [ | |
209 # '$(ProjectDir)\\test\\views_unittest.manifest', | |
210 # ], | |
211 # }, | |
212 #}, | |
213 } | |
214 | 194 |
215 if (use_x11) { | 195 if (is_win) { |
216 configs += [ | 196 deps += [ |
217 "//build/config/linux:x11", | 197 "//third_party/iaccessible2", |
218 "//build/config/linux:xext", | 198 "//third_party/wtl", |
219 ] | 199 ] |
220 deps += [ | 200 libs = [ |
221 "//ui/events/devices", | 201 "imm32.lib", |
222 "//ui/events/platform/x11", | 202 "oleacc.lib", |
223 "//ui/gfx/x", | 203 "comctl32.lib", |
224 ] | 204 ] |
225 } | |
226 | 205 |
227 if (use_aura) { | 206 # TOOD(GYP) |
228 sources += gypi_values.views_unittests_aura_sources | 207 #'msvs_settings': { |
229 deps += [ "//ui/aura:test_support" ] | 208 # 'VCManifestTool': { |
230 if (!is_chromeos) { | 209 # 'AdditionalManifestFiles': [ |
231 sources += gypi_values.views_unittests_desktop_aura_sources | 210 # '$(ProjectDir)\\test\\views_unittest.manifest', |
232 if (use_x11) { | 211 # ], |
233 sources += gypi_values.views_unittests_desktop_aurax11_sources | 212 # }, |
| 213 #}, |
| 214 } |
| 215 |
| 216 if (use_x11) { |
| 217 configs += [ |
| 218 "//build/config/linux:x11", |
| 219 "//build/config/linux:xext", |
| 220 ] |
| 221 deps += [ |
| 222 "//ui/events/devices", |
| 223 "//ui/events/platform/x11", |
| 224 "//ui/gfx/x", |
| 225 ] |
| 226 } |
| 227 |
| 228 if (use_aura) { |
| 229 sources += gypi_values.views_unittests_aura_sources |
| 230 deps += [ "//ui/aura:test_support" ] |
| 231 if (!is_chromeos) { |
| 232 sources += gypi_values.views_unittests_desktop_aura_sources |
| 233 if (use_x11) { |
| 234 sources += gypi_values.views_unittests_desktop_aurax11_sources |
| 235 } |
234 } | 236 } |
235 } | 237 } |
236 } | 238 if (use_x11) { |
237 if (use_x11) { | 239 deps += [ |
238 deps += [ | 240 "//ui/events/platform/x11", |
239 "//ui/events/platform/x11", | 241 "//ui/gfx/x", |
240 "//ui/gfx/x", | 242 ] |
241 ] | 243 } |
242 } | |
243 | 244 |
244 if (is_mac) { | 245 if (is_mac) { |
245 # views_unittests not yet compiling on Mac. http://crbug.com/378134 | 246 # views_unittests not yet compiling on Mac. http://crbug.com/378134 |
246 sources -= [ | 247 sources -= [ |
247 "bubble/bubble_window_targeter_unittest.cc", | 248 "bubble/bubble_window_targeter_unittest.cc", |
248 "controls/button/custom_button_unittest.cc", | 249 "controls/button/custom_button_unittest.cc", |
249 "controls/button/menu_button_unittest.cc", | 250 "controls/button/menu_button_unittest.cc", |
250 "controls/native/native_view_host_unittest.cc", | 251 "controls/native/native_view_host_unittest.cc", |
251 "controls/menu/menu_controller_unittest.cc", | 252 "controls/menu/menu_controller_unittest.cc", |
252 "ime/input_method_bridge_unittest.cc", | 253 "ime/input_method_bridge_unittest.cc", |
253 "focus/focus_manager_unittest.cc", | 254 "focus/focus_manager_unittest.cc", |
254 "widget/window_reorderer_unittest.cc", | 255 "widget/window_reorderer_unittest.cc", |
255 "widget/widget_unittest.cc", | 256 "widget/widget_unittest.cc", |
256 ] | 257 ] |
| 258 } |
257 } | 259 } |
258 } | 260 } |
259 | 261 |
260 if (is_mac) { | 262 if (is_mac) { |
261 test("macviews_interactive_ui_tests") { | 263 test("macviews_interactive_ui_tests") { |
262 sources = [ | 264 sources = [ |
263 "cocoa/bridged_native_widget_interactive_uitest.mm", | 265 "cocoa/bridged_native_widget_interactive_uitest.mm", |
264 "run_all_unittests.cc", | 266 "run_all_unittests.cc", |
265 "widget/native_widget_mac_interactive_uitest.mm", | 267 "widget/native_widget_mac_interactive_uitest.mm", |
266 ] | 268 ] |
267 deps = [ | 269 deps = [ |
268 ":test_support", | 270 ":test_support", |
269 ":views", | 271 ":views", |
270 "//base", | 272 "//base", |
271 "//base/test:test_support", | 273 "//base/test:test_support", |
272 "//skia", | 274 "//skia", |
273 "//testing/gtest", | 275 "//testing/gtest", |
274 "//ui/aura", | 276 "//ui/aura", |
275 "//ui/compositor", | 277 "//ui/compositor", |
276 "//ui/resources", | 278 "//ui/resources", |
277 "//ui/resources:ui_test_pak", | 279 "//ui/resources:ui_test_pak", |
278 "//ui/strings", | 280 "//ui/strings", |
279 "//ui/wm", | 281 "//ui/wm", |
280 ] | 282 ] |
281 } | 283 } |
282 } | 284 } |
OLD | NEW |