Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(26)

Unified Diff: ui/ui_unittests.gypi

Issue 10224004: Use Android API for GetDisplayNameForLocale(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: For landing Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/base/l10n/l10n_util_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ui_unittests.gypi
diff --git a/ui/ui_unittests.gypi b/ui/ui_unittests.gypi
index 77965dcaed11bd78505a09e9ff684c040d7932c6..1b68db7f127a1452b737af8f8a915583b5b9ff52 100644
--- a/ui/ui_unittests.gypi
+++ b/ui/ui_unittests.gypi
@@ -29,7 +29,7 @@
},
{
'target_name': 'ui_unittests',
- 'type': 'executable',
+ 'type': '<(gtest_target_type)',
'includes': [
'base/ime/ime_unittests.gypi',
],
@@ -154,6 +154,11 @@
'gfx/interpolated_transform_unittest.cc',
],
}],
+ ['OS=="android" and "<(gtest_target_type)"=="shared_library"', {
+ 'dependencies': [
+ '../testing/android/native_test.gyp:native_test_native_code',
+ ],
+ }],
['use_glib == 1', {
'dependencies': [
'../build/linux/system.gyp:pangocairo',
@@ -206,4 +211,49 @@
],
},
],
+ 'conditions': [
+ # Special target to wrap a <(gtest_target_type)==shared_library
+ # ui_unittests into an android apk for execution.
+ # See base.gyp for TODO(jrg)s about this strategy.
+ ['OS=="android" and "<(gtest_target_type)"=="shared_library"', {
+ 'targets': [
+ {
+ 'target_name': 'ui_unittests_apk',
+ 'type': 'none',
+ 'dependencies': [
+ 'ui_unittests',
+ ],
+ 'actions': [
+ {
+ # Generate apk files (including source and antfile) from
+ # a template, and builds them.
+ 'action_name': 'generate_and_build',
+ 'inputs': [
+ '../testing/android/generate_native_test.py',
+ '<(PRODUCT_DIR)/lib.target/libui_unittests.so',
+ '<(PRODUCT_DIR)/chromium_base.jar',
+ ],
+ 'outputs': [
+ '<(PRODUCT_DIR)/ChromeNativeTests_ui_unittests-debug.apk',
+ ],
+ 'action': [
+ '../testing/android/generate_native_test.py',
+ '--native_library',
+ '<(PRODUCT_DIR)/lib.target/libui_unittests.so',
+ # TODO(jrg): find a better way to specify jar
+ # dependencies. Hard coding seems fragile.
+ '--jar',
+ '<(PRODUCT_DIR)/chromium_base.jar',
+ '--output',
+ '<(PRODUCT_DIR)/ui_unittests_apk',
+ '--ant-args',
+ '-DPRODUCT_DIR=<(PRODUCT_DIR)',
+ '--ant-compile'
+ ],
+ },
+ ]
+ },
+ ],
+ }],
+ ],
}
« no previous file with comments | « ui/base/l10n/l10n_util_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698