Roll libjpeg_turbo to git hash feec46f80444b8eed4126a86a2c0e2cffe1c9673
[chromium-blink-merge.git] / android_webview / android_webview_tests.gypi
blob9fe47b1fced865b70c899f8c7c51a032d394c641
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.
5   'targets': [
6     {
7       'target_name': 'android_webview_apk',
8       'type': 'none',
9       'dependencies': [
10         'libstandalonelibwebviewchromium',
11         'android_webview_java',
12         'android_webview_pak',
13         'libdrawgl',
14       ],
15       'variables': {
16         'apk_name': 'AndroidWebView',
17         'java_in_dir': 'test/shell',
18         'native_lib_target': 'libstandalonelibwebviewchromium',
19         'resource_dir': 'test/shell/res',
20         'extensions_to_not_compress': '.lpak,.pak,.dat,.bin',
21         'asset_location': '<(PRODUCT_DIR)/android_webview_apk/assets',
22         'extra_native_libs': ['<(SHARED_LIB_DIR)/libdrawgl.>(android_product_extension)'],
23         'snapshot_copy_files': '<(snapshot_copy_files)',
24         'additional_input_paths': [
25           '<(asset_location)/webviewchromium.pak',
26           '<(asset_location)/asset_file.html',
27           '<(asset_location)/cookie_test.html',
28           '<(asset_location)/asset_icon.png',
29           '<(asset_location)/full_screen_video.js',
30           '<(asset_location)/full_screen_video_test.html',
31           '<(asset_location)/full_screen_video_inside_div_test.html',
32           '<(asset_location)/multiple_videos_test.html',
33           '<(asset_location)/video.mp4',
34           '<(asset_location)/visual_state_during_fullscreen_test.html',
35           '<(asset_location)/visual_state_waits_for_js_test.html',
36           '<(asset_location)/visual_state_on_page_commit_visible_test.html',
37           '<@(snapshot_additional_input_paths)',
38         ],
39         'conditions': [
40           ['icu_use_data_file_flag==1', {
41             'additional_input_paths': [
42               '<(asset_location)/icudtl.dat',
43             ],
44           }],
45         ],
46         'includes': [ 'snapshot_copying.gypi' ],
47       },
48       'copies': [
49         {
50           'destination': '<(asset_location)',
51           'files': [
52             '<(PRODUCT_DIR)/android_webview_assets/webviewchromium.pak',
53             '<(java_in_dir)/assets/asset_file.html',
54             '<(java_in_dir)/assets/asset_icon.png',
55             '<(java_in_dir)/assets/cookie_test.html',
56             '<(java_in_dir)/assets/full_screen_video.js',
57             '<(java_in_dir)/assets/full_screen_video_test.html',
58             '<(java_in_dir)/assets/full_screen_video_inside_div_test.html',
59             '<(java_in_dir)/assets/multiple_videos_test.html',
60             '<(java_in_dir)/assets/video.mp4',
61             '<(java_in_dir)/assets/visual_state_during_fullscreen_test.html',
62             '<(java_in_dir)/assets/visual_state_waits_for_js_test.html',
63             '<(java_in_dir)/assets/visual_state_on_page_commit_visible_test.html',
64             '<@(snapshot_copy_files)',
65           ],
66           'conditions': [
67             ['icu_use_data_file_flag==1', {
68               'files': [
69                 '<(PRODUCT_DIR)/icudtl.dat',
70               ],
71             }],
72           ],
73         },
74       ],
75       'includes': [ '../build/java_apk.gypi' ],
76     },
77     {
78       # android_webview_apk creates a .jar as a side effect. Any java
79       # targets that need that .jar in their classpath should depend on this
80       # target. For more details see the chrome_shell_apk_java target.
81       'target_name': 'android_webview_apk_java',
82       'type': 'none',
83       'dependencies': [
84         'android_webview_apk',
85       ],
86       'includes': [ '../build/apk_fake_jar.gypi' ],
87     },
88     {
89       'target_name': 'android_webview_test_apk',
90       'type': 'none',
91       'dependencies': [
92         '../base/base.gyp:base_java_test_support',
93         '../content/content_shell_and_tests.gyp:content_java_test_support',
94         '../net/net.gyp:net_java_test_support',
95         '../testing/android/on_device_instrumentation.gyp:broker_java',
96         '../testing/android/on_device_instrumentation.gyp:require_driver_apk',
97         'android_webview_apk_java',
98       ],
99       'variables': {
100         'apk_name': 'AndroidWebViewTest',
101         'java_in_dir': '../android_webview/javatests',
102         'is_test_apk': 1,
103         'test_type': 'instrumentation',
104         'isolate_file': 'android_webview_test_apk.isolate',
105       },
106       'includes': [
107         '../build/java_apk.gypi',
108         '../build/android/test_runner.gypi',
109       ],
110     },
111     {
112       'target_name': 'android_webview_unittests',
113       'type': '<(gtest_target_type)',
114       'dependencies': [
115         '../base/base.gyp:test_support_base',
116         '../content/content_shell_and_tests.gyp:test_support_content',
117         '../net/net.gyp:net_test_support',
118         '../testing/android/native_test.gyp:native_test_native_code',
119         '../testing/gmock.gyp:gmock',
120         '../testing/gtest.gyp:gtest',
121         '../ui/base/ui_base.gyp:ui_base_jni_headers',
122         '../ui/gl/gl.gyp:gl',
123         '../ui/gl/gl.gyp:gl_test_support',
124         'android_webview_common',
125         'android_webview_unittests_jni',
126       ],
127       'include_dirs': [
128         '..',
129         '../skia/config',
130         '<(SHARED_INTERMEDIATE_DIR)/android_webview_unittests',
131       ],
132       'sources': [
133         'browser/aw_static_cookie_policy_unittest.cc',
134         'browser/aw_form_database_service_unittest.cc',
135         'browser/browser_view_renderer_unittest.cc',
136         'browser/net/android_stream_reader_url_request_job_unittest.cc',
137         'browser/net/input_stream_reader_unittest.cc',
138         'browser/test/fake_window.cc',
139         'browser/test/fake_window.h',
140         'browser/test/rendering_test.cc',
141         'browser/test/rendering_test.h',
142         'lib/main/webview_tests.cc',
143         'native/aw_contents_client_bridge_unittest.cc',
144         'native/aw_media_url_interceptor_unittest.cc',
145         'native/input_stream_unittest.cc',
146         'native/permission/media_access_permission_request_unittest.cc',
147         'native/permission/permission_request_handler_unittest.cc',
148         'native/state_serializer_unittest.cc',
149       ],
150     },
151     {
152       'target_name': 'android_webview_unittest_java',
153       'type': 'none',
154       'dependencies': [
155         '../base/base.gyp:base_java_test_support',
156         '../content/content_shell_and_tests.gyp:content_java_test_support',
157         'android_webview_java',
158       ],
159       'variables': {
160         'java_in_dir': '../android_webview/unittestjava',
161       },
162       'includes': [ '../build/java.gypi' ],
163     },
164     {
165       'target_name': 'android_webview_unittests_jni',
166       'type': 'none',
167       'sources': [
168           '../android_webview/unittestjava/src/org/chromium/android_webview/unittest/InputStreamUnittest.java',
169           '../android_webview/unittestjava/src/org/chromium/android_webview/unittest/MockAwContentsClientBridge.java',
170       ],
171       'variables': {
172         'jni_gen_package': 'android_webview_unittests',
173       },
174       'includes': [ '../build/jni_generator.gypi' ],
175     },
176     {
177       'target_name': 'android_webview_unittests_apk',
178       'type': 'none',
179       'dependencies': [
180         'android_webview_unittest_java',
181         'android_webview_unittests',
182       ],
183       'variables': {
184         'test_suite_name': 'android_webview_unittests',
185         'additional_input_paths': [
186           '<(PRODUCT_DIR)/android_webview_unittests_apk/assets/asset_file.ogg',
187         ],
188       },
189       'copies': [
190         {
191           'destination': '<(PRODUCT_DIR)/android_webview_unittests_apk/assets',
192           'files': [
193             'test/unittest/assets/asset_file.ogg',
194           ],
195         },
196       ],
197       'includes': [ '../build/apk_test.gypi' ],
198     },
199     {
200       'target_name': 'libdrawgl',
201       'type': 'shared_library',
202       # Do not depend on any other component here, since this target
203       # builds a separate shared library!
204       'include_dirs': [
205         '..',
206       ],
207       'variables': {
208         # This library uses native JNI exports; tell gyp so that the required
209         # symbols will be kept.
210         'use_native_jni_exports': 1,
211       },
212       'sources': [
213           '../android_webview/test/shell/src/draw_gl/draw_gl.cc',
214       ],
215     },
216     {
217       'target_name': 'libstandalonelibwebviewchromium',
218       'includes': [
219         'libwebviewchromium.gypi',
220       ],
221     },
222   ],