Revert of Remove deprecated methods from Pickle. (patchset #10 id:180001 of https...
[chromium-blink-merge.git] / chromecast / chromecast_tests.gypi
bloba6339304a432a517aeb2cd673776ef0af4eb322a
1 # Copyright (c) 2014 Google Inc. 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   'targets': [
7     {
8       'target_name': 'cast_tests',
9       'type': 'none',
10       'dependencies': [
11         'cast_test_generator',
12       ],
13       'conditions': [
14         ['chromecast_branding=="Chrome"', {
15           'dependencies': [
16             '<(cast_internal_gyp):cast_tests_internal',
17           ],
18         }],
19       ],
20     },
21     # This target only depends on targets that generate test binaries.
22     {
23       'target_name': 'cast_test_generator',
24       'type': 'none',
25       'dependencies': [
26         'media/media.gyp:cast_media_unittests',
27         '../base/base.gyp:base_unittests',
28         '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation_unittests',
29         '../content/content_shell_and_tests.gyp:content_unittests',
30         '../crypto/crypto.gyp:crypto_unittests',
31         '../ipc/ipc.gyp:ipc_tests',
32         '../jingle/jingle.gyp:jingle_unittests',
33         '../media/media.gyp:media_unittests',
34         '../net/net.gyp:net_unittests',
35         '../sandbox/sandbox.gyp:sandbox_linux_unittests',
36         '../sql/sql.gyp:sql_unittests',
37         '../sync/sync.gyp:sync_unit_tests',
38         '../ui/base/ui_base_tests.gyp:ui_base_unittests',
39         '../url/url.gyp:url_unittests',
40       ],
41       'variables': {
42         'filters': [
43           # Disable OutOfMemoryDeathTest.ViaSharedLibraries due to gTrusty eglibc incompatibility
44           # See: crbug/428211
45           'base_unittests --gtest_filter=-OutOfMemoryDeathTest.ViaSharedLibraries',
46         ],
47       },
48       'conditions': [
49         ['OS!="android"', {
50           'dependencies': [
51             'cast_shell_browser_test',
52           ],
53           'variables': {
54             'filters': [
55               'cast_shell_browser_test --no-sandbox',
56             ],
57           },
58         }],
59       ],
60       'includes': ['build/tests/test_list.gypi'],
61     },
62     # Builds all tests and the output lists of build/run targets for those tests.
63     # Note: producing a predetermined list of dependent inputs on which to
64     # regenerate this output is difficult with GYP. This file is not
65     # guaranteed to be regenerated outside of a clean build.
66     {
67       'target_name': 'cast_test_lists',
68       'type': 'none',
69       'dependencies': [
70         'cast_tests',
71       ],
72       'variables': {
73         'test_generator_py': '<(DEPTH)/chromecast/tools/build/generate_test_lists.py',
74         'test_inputs_dir': '<(SHARED_INTERMEDIATE_DIR)/chromecast/tests',
75         'test_additional_options': '--ozone-platform=test'
76       },
77       'actions': [
78         {
79           'action_name': 'generate_combined_test_build_list',
80           'message': 'Generating combined test build list',
81           'inputs': ['<(test_generator_py)'],
82           'outputs': ['<(PRODUCT_DIR)/tests/build_test_list.txt'],
83           'action': [
84             'python', '<(test_generator_py)',
85             '-t', '<(test_inputs_dir)',
86             '-o', '<@(_outputs)',
87             'pack_build',
88           ],
89         },
90         {
91           'action_name': 'generate_combined_test_run_list',
92           'message': 'Generating combined test run list',
93           'inputs': ['<(test_generator_py)'],
94           'outputs': ['<(PRODUCT_DIR)/tests/run_test_list.txt'],
95           'action': [
96             'python', '<(test_generator_py)',
97             '-t', '<(test_inputs_dir)',
98             '-o', '<@(_outputs)',
99             '-a', '<(test_additional_options)',
100             'pack_run',
101           ],
102         }
103       ],
104     },
105     {
106       'target_name': 'cast_metrics_test_support',
107       'type': '<(component)',
108       'dependencies': [
109         'cast_base',
110       ],
111       'sources': [
112         'base/metrics/cast_metrics_test_helper.cc',
113         'base/metrics/cast_metrics_test_helper.h',
114       ],
115     },  # end of target 'cast_metrics_test_support'
116   ],  # end of targets
117   'conditions': [
118     ['OS=="android"', {
119       'targets': [
120         {
121           'target_name': 'cast_android_tests',
122           'type': 'none',
123           'dependencies': [
124             '../base/base.gyp:base_unittests_apk',
125             '../cc/cc_tests.gyp:cc_unittests_apk',
126             '../ipc/ipc.gyp:ipc_tests_apk',
127             '../media/media.gyp:media_unittests_apk',
128             '../net/net.gyp:net_unittests_apk',
129             '../sandbox/sandbox.gyp:sandbox_linux_jni_unittests_apk',
130             '../sql/sql.gyp:sql_unittests_apk',
131             '../sync/sync.gyp:sync_unit_tests_apk',
132             '../ui/events/events.gyp:events_unittests_apk',
133             '../ui/gfx/gfx_tests.gyp:gfx_unittests_apk',
134           ],
135           'includes': ['build/tests/test_list.gypi'],
136         },
137         {
138           'target_name': 'cast_android_test_lists',
139           'type': 'none',
140           'dependencies': [
141             'cast_android_tests',
142           ],
143           'variables': {
144             'test_generator_py': '<(DEPTH)/chromecast/tools/build/generate_test_lists.py',
145             'test_inputs_dir': '<(SHARED_INTERMEDIATE_DIR)/chromecast/tests',
146           },
147           'actions': [
148             {
149               'action_name': 'generate_combined_test_build_list',
150               'message': 'Generating combined test build list',
151               'inputs': ['<(test_generator_py)'],
152               'outputs': ['<(PRODUCT_DIR)/tests/build_test_list_android.txt'],
153               'action': [
154                 'python', '<(test_generator_py)',
155                 '-t', '<(test_inputs_dir)',
156                 '-o', '<@(_outputs)',
157                 'pack_build',
158               ],
159             },
160           ],
161         },
162       ],  # end of targets
163     }, {  # OS!="android"
164       'targets': [
165         {
166           'target_name': 'cast_shell_test_support',
167           'type': '<(component)',
168           'defines': [
169             'HAS_OUT_OF_PROC_TEST_RUNNER',
170           ],
171           'dependencies': [
172             'cast_shell_core',
173             '../content/content_shell_and_tests.gyp:content_browser_test_support',
174             '../testing/gtest.gyp:gtest',
175           ],
176           'sources': [
177             'browser/test/chromecast_browser_test.cc',
178             'browser/test/chromecast_browser_test.h',
179             'browser/test/chromecast_browser_test_runner.cc',
180           ],
181         },  # end of target 'cast_shell_test_support'
182         {
183           'target_name': 'cast_shell_browser_test',
184           'type': '<(gtest_target_type)',
185           'dependencies': [
186             'cast_shell_test_support',
187             '../testing/gtest.gyp:gtest',
188           ],
189           'defines': [
190             'HAS_OUT_OF_PROC_TEST_RUNNER',
191           ],
192           'sources': [
193             'browser/test/chromecast_shell_browser_test.cc',
194           ],
195         },
196       ],  # end of targets
197     }],
198   ],  # end of conditions