Update .DEPS.git
[chromium-blink-merge.git] / cc / cc_tests.gyp
blob4ecb8e77030beca3d3e5226cd525dd27ffcdc9ee
1 # Copyright (c) 2012 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.
6   'variables': {
7     'chromium_code': 1,
8     'cc_unit_tests_source_files': [
9       'animation/animation_unittest.cc',
10       'animation/keyframed_animation_curve_unittest.cc',
11       'animation/layer_animation_controller_unittest.cc',
12       'animation/scrollbar_animation_controller_linear_fade_unittest.cc',
13       'animation/scrollbar_animation_controller_thinning_unittest.cc',
14       'animation/timing_function_unittest.cc',
15       'animation/transform_operations_unittest.cc',
16       'base/float_quad_unittest.cc',
17       'base/math_util_unittest.cc',
18       'base/region_unittest.cc',
19       'base/scoped_ptr_vector_unittest.cc',
20       'base/tiling_data_unittest.cc',
21       'base/util_unittest.cc',
22       'input/top_controls_manager_unittest.cc',
23       'layers/content_layer_unittest.cc',
24       'layers/contents_scaling_layer_unittest.cc',
25       'layers/delegated_renderer_layer_impl_unittest.cc',
26       'layers/heads_up_display_unittest.cc',
27       'layers/layer_impl_unittest.cc',
28       'layers/layer_iterator_unittest.cc',
29       'layers/layer_position_constraint_unittest.cc',
30       'layers/layer_unittest.cc',
31       'layers/nine_patch_layer_impl_unittest.cc',
32       'layers/nine_patch_layer_unittest.cc',
33       'layers/picture_image_layer_impl_unittest.cc',
34       'layers/picture_layer_impl_unittest.cc',
35       'layers/render_surface_unittest.cc',
36       'layers/scrollbar_layer_unittest.cc',
37       'layers/solid_color_layer_impl_unittest.cc',
38       'layers/texture_layer_unittest.cc',
39       'layers/tiled_layer_impl_unittest.cc',
40       'layers/tiled_layer_unittest.cc',
41       'output/delegating_renderer_unittest.cc',
42       'output/filter_operations_unittest.cc',
43       'output/gl_renderer_unittest.cc',
44       'output/output_surface_unittest.cc',
45       'output/renderer_pixeltest.cc',
46       'output/render_surface_filters_unittest.cc',
47       'output/shader_unittest.cc',
48       'output/software_renderer_unittest.cc',
49       'quads/draw_quad_unittest.cc',
50       'quads/render_pass_unittest.cc',
51       'resources/layer_quad_unittest.cc',
52       'resources/picture_layer_tiling_set_unittest.cc',
53       'resources/picture_layer_tiling_unittest.cc',
54       'resources/picture_pile_impl_unittest.cc',
55       'resources/picture_pile_unittest.cc',
56       'resources/picture_unittest.cc',
57       'resources/prioritized_resource_unittest.cc',
58       'resources/prioritized_tile_set_unittest.cc',
59       'resources/raster_worker_pool_unittest.cc',
60       'resources/resource_provider_unittest.cc',
61       'resources/resource_update_controller_unittest.cc',
62       'resources/scoped_resource_unittest.cc',
63       'resources/texture_mailbox_deleter_unittest.cc',
64       'resources/tile_manager_unittest.cc',
65       'resources/tile_priority_unittest.cc',
66       'resources/video_resource_updater_unittest.cc',
67       'resources/worker_pool_unittest.cc',
68       'scheduler/delay_based_time_source_unittest.cc',
69       'scheduler/frame_rate_controller_unittest.cc',
70       'scheduler/rolling_time_delta_history_unittest.cc',
71       'scheduler/scheduler_state_machine_unittest.cc',
72       'scheduler/scheduler_unittest.cc',
73       'scheduler/texture_uploader_unittest.cc',
74       'test/fake_web_graphics_context_3d_unittest.cc',
75       'trees/damage_tracker_unittest.cc',
76       'trees/layer_sorter_unittest.cc',
77       'trees/layer_tree_host_common_unittest.cc',
78       'trees/layer_tree_host_impl_unittest.cc',
79       'trees/layer_tree_host_pixeltest_filters.cc',
80       'trees/layer_tree_host_pixeltest_masks.cc',
81       'trees/layer_tree_host_pixeltest_on_demand_raster.cc',
82       'trees/layer_tree_host_pixeltest_readback.cc',
83       'trees/layer_tree_host_unittest_animation.cc',
84       'trees/layer_tree_host_unittest.cc',
85       'trees/layer_tree_host_unittest_context.cc',
86       'trees/layer_tree_host_unittest_damage.cc',
87       'trees/layer_tree_host_unittest_delegated.cc',
88       'trees/layer_tree_host_unittest_occlusion.cc',
89       'trees/layer_tree_host_unittest_picture.cc',
90       'trees/layer_tree_host_unittest_scroll.cc',
91       'trees/layer_tree_host_unittest_video.cc',
92       'trees/occlusion_tracker_unittest.cc',
93       'trees/quad_culler_unittest.cc',
94       'trees/tree_synchronizer_unittest.cc',
95     ],
96     'cc_tests_support_files': [
97       'test/animation_test_common.cc',
98       'test/animation_test_common.h',
99       'test/fake_content_layer.cc',
100       'test/fake_content_layer.h',
101       'test/fake_content_layer_client.cc',
102       'test/fake_content_layer_client.h',
103       'test/fake_content_layer_impl.cc',
104       'test/fake_content_layer_impl.h',
105       'test/fake_delegated_renderer_layer.cc',
106       'test/fake_delegated_renderer_layer.h',
107       'test/fake_delegated_renderer_layer_impl.cc',
108       'test/fake_delegated_renderer_layer_impl.h',
109       'test/fake_impl_proxy.h',
110       'test/fake_layer_tree_host_client.cc',
111       'test/fake_layer_tree_host_client.h',
112       'test/fake_layer_tree_host_impl.cc',
113       'test/fake_layer_tree_host_impl_client.cc',
114       'test/fake_layer_tree_host_impl_client.h',
115       'test/fake_layer_tree_host_impl.h',
116       'test/fake_painted_scrollbar_layer.cc',
117       'test/fake_painted_scrollbar_layer.h',
118       'test/fake_picture_layer.cc',
119       'test/fake_picture_layer.h',
120       'test/fake_picture_layer_impl.cc',
121       'test/fake_picture_layer_impl.h',
122       'test/fake_picture_layer_tiling_client.cc',
123       'test/fake_picture_layer_tiling_client.h',
124       'test/fake_picture_pile_impl.cc',
125       'test/fake_picture_pile_impl.h',
126       'test/fake_proxy.cc',
127       'test/fake_proxy.h',
128       'test/fake_rendering_stats_instrumentation.h',
129       'test/fake_scrollbar.cc',
130       'test/fake_scrollbar.h',
131       'test/fake_tile_manager.cc',
132       'test/fake_tile_manager.h',
133       'test/fake_tile_manager_client.h',
134       'test/fake_tile_manager_client.cc',
135       'test/fake_output_surface.cc',
136       'test/fake_output_surface.h',
137       'test/fake_output_surface_client.cc',
138       'test/fake_output_surface_client.h',
139       'test/fake_scoped_ui_resource.cc',
140       'test/fake_scoped_ui_resource.h',
141       'test/fake_video_frame_provider.cc',
142       'test/fake_video_frame_provider.h',
143       'test/geometry_test_utils.cc',
144       'test/geometry_test_utils.h',
145       'test/impl_side_painting_settings.h',
146       'test/layer_test_common.cc',
147       'test/layer_test_common.h',
148       'test/layer_tree_pixel_test.cc',
149       'test/layer_tree_pixel_test.h',
150       'test/layer_tree_test.cc',
151       'test/layer_tree_test.h',
152       'test/layer_tree_json_parser.cc',
153       'test/layer_tree_json_parser.h',
154       'test/mock_quad_culler.cc',
155       'test/mock_quad_culler.h',
156       'test/occlusion_tracker_test_common.h',
157       'test/paths.cc',
158       'test/paths.h',
159       'test/pixel_test.cc',
160       'test/pixel_test.h',
161       'test/pixel_test_output_surface.cc',
162       'test/pixel_test_output_surface.h',
163       'test/pixel_test_software_output_device.cc',
164       'test/pixel_test_software_output_device.h',
165       'test/render_pass_test_common.cc',
166       'test/render_pass_test_common.h',
167       'test/render_pass_test_utils.cc',
168       'test/render_pass_test_utils.h',
169       'test/scheduler_test_common.cc',
170       'test/scheduler_test_common.h',
171       'test/solid_color_content_layer_client.h',
172       'test/solid_color_content_layer_client.cc',
173       'test/skia_common.cc',
174       'test/skia_common.h',
175       'test/test_tile_priorities.cc',
176       'test/test_tile_priorities.h',
177       'test/tiled_layer_test_common.cc',
178       'test/tiled_layer_test_common.h',
179     ],
180   },
181   'targets': [
182     {
183       'target_name': 'cc_unittests',
184       'type': '<(gtest_target_type)',
185       'dependencies': [
186         '../base/base.gyp:test_support_base',
187         '../gpu/gpu.gyp:gpu',
188         '../media/media.gyp:media',
189         '../skia/skia.gyp:skia',
190         '../testing/gmock.gyp:gmock',
191         '../testing/gtest.gyp:gtest',
192         '../ui/ui.gyp:ui',
193         '../webkit/common/gpu/webkit_gpu.gyp:webkit_gpu',
194         'cc.gyp:cc',
195         'cc_test_support',
196         'cc_test_utils',
197       ],
198       'sources': [
199         'test/run_all_unittests.cc',
200         'test/cc_test_suite.cc',
201         '<@(cc_unit_tests_source_files)',
202       ],
203       'include_dirs': [
204         'test',
205         '.',
206       ],
207       'conditions': [
208         ['OS == "android" and gtest_target_type == "shared_library"',
209           {
210             'dependencies': [
211               '../testing/android/native_test.gyp:native_test_native_code',
212             ],
213           }
214         ],
215         [ 'os_posix == 1 and OS != "mac" and OS != "android" and OS != "ios"',
216           {
217             'conditions': [
218               [ 'linux_use_tcmalloc==1',
219                 {
220                   'dependencies': [
221                     '../base/allocator/allocator.gyp:allocator',
222                   ],
223                 }
224               ],
225             ],
226           }
227         ],
228       ],
229       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
230       'msvs_disabled_warnings': [ 4267, ],
231     },
232     {
233       'target_name': 'cc_perftests',
234       'type': '<(gtest_target_type)',
235       'dependencies': [
236         '../base/base.gyp:test_support_base',
237         '../media/media.gyp:media',
238         '../skia/skia.gyp:skia',
239         '../testing/gmock.gyp:gmock',
240         '../testing/gtest.gyp:gtest',
241         '../testing/perf/perf_test.gyp:*',
242         '../ui/ui.gyp:ui',
243         'cc.gyp:cc',
244         'cc_test_support',
245       ],
246       'sources': [
247         'resources/picture_layer_tiling_perftest.cc',
248         'resources/raster_worker_pool_perftest.cc',
249         'resources/tile_manager_perftest.cc',
250         'resources/worker_pool_perftest.cc',
251         'test/cc_test_suite.cc',
252         'test/lap_timer.cc',
253         'test/run_all_unittests.cc',
254         'trees/layer_tree_host_perftest.cc',
255       ],
256       'include_dirs': [
257         'test',
258         '.',
259       ],
260       'conditions': [
261         ['OS == "android" and gtest_target_type == "shared_library"',
262           {
263             'dependencies': [
264               '../testing/android/native_test.gyp:native_test_native_code',
265             ],
266           }
267         ],
268         # See http://crbug.com/162998#c4 for why this is needed.
269         ['OS=="linux" and linux_use_tcmalloc==1',
270           {
271             'dependencies': [
272               '../base/allocator/allocator.gyp:allocator',
273             ],
274           }
275         ],
276       ],
277       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
278       'msvs_disabled_warnings': [ 4267, ],
279     },
280     {
281       'target_name': 'cc_test_support',
282       'type': 'static_library',
283       'include_dirs': [
284         'test',
285         '.',
286         '..',
287       ],
288       'dependencies': [
289         '../skia/skia.gyp:skia',
290         '../testing/gmock.gyp:gmock',
291         '../testing/gtest.gyp:gtest',
292         '../third_party/WebKit/public/blink.gyp:blink_minimal',
293         '../third_party/mesa/mesa.gyp:osmesa',
294         '../ui/gl/gl.gyp:gl',
295         '../ui/ui.gyp:ui',
296       ],
297       'sources': [
298         '<@(cc_tests_support_files)',
299       ],
300       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
301       'msvs_disabled_warnings': [ 4267, ],
302     },
303     {
304       'target_name': 'cc_test_utils',
305       'type': 'static_library',
306       'include_dirs': [
307         '..'
308       ],
309       'sources': [
310         'test/pixel_comparator.cc',
311         'test/pixel_comparator.h',
312         'test/pixel_test_utils.cc',
313         'test/pixel_test_utils.h',
314       ],
315       'dependencies': [
316         '../skia/skia.gyp:skia',
317         '../ui/ui.gyp:ui',  # for png_codec
318       ],
319     },
320   ],
321   'conditions': [
322     # Special target to wrap a gtest_target_type==shared_library
323     # cc_unittests into an android apk for execution.
324     ['OS == "android" and gtest_target_type == "shared_library"',
325       {
326         'targets': [
327           {
328             'target_name': 'cc_unittests_apk',
329             'type': 'none',
330             'dependencies': [
331               'cc_unittests',
332             ],
333             'variables': {
334               'test_suite_name': 'cc_unittests',
335               'input_shlib_path': '<(SHARED_LIB_DIR)/<(SHARED_LIB_PREFIX)cc_unittests<(SHARED_LIB_SUFFIX)',
336             },
337             'includes': [ '../build/apk_test.gypi' ],
338           },
339           {
340             'target_name': 'cc_perftests_apk',
341             'type': 'none',
342             'dependencies': [
343               'cc_perftests',
344             ],
345             'variables': {
346               'test_suite_name': 'cc_perftests',
347               'input_shlib_path': '<(SHARED_LIB_DIR)/<(SHARED_LIB_PREFIX)cc_perftests<(SHARED_LIB_SUFFIX)',
348             },
349             'includes': [ '../build/apk_test.gypi' ],
350           },
351         ],
352       }
353     ]
354   ],