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

Unified Diff: testing/test.gni

Issue 1611363003: Add support for iOS application bundle to GN. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@gn-bundles
Patch Set: Created 4 years, 11 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
« build/config/ios/ios_gen_plist.py ('K') | « build/toolchain/mac/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: testing/test.gni
diff --git a/testing/test.gni b/testing/test.gni
index 6739bfebb21ce85f18903e934fe9822658d2f109..912648eb52c1bf6e25dba751d3a4ef8a066e2510 100644
--- a/testing/test.gni
+++ b/testing/test.gni
@@ -123,51 +123,84 @@ template("test") {
]
}
} else if (is_ios) {
- if (is_ios) {
- import("//build/config/ios/rules.gni")
- }
-
- ios_app(target_name) {
- # TODO(GYP): Make this configurable and only provide a default
- # that can be overridden.
- info_plist = "//testing/gtest_ios/unittest-Info.plist"
- app_name = target_name
- entitlements_path = "//testing/gtest_ios"
- code_signing_identity = ""
- testonly = true
-
- # See above call.
- set_sources_assignment_filter([])
+ import("//build/config/ios/ios_sdk.gni")
+ import("//build/config/ios/rules.gni")
+ ios_test_app(target_name) {
forward_variables_from(invoker,
[
+ # Arguments specific to ios_test_app target.
+ "app_name",
+ "code_signing_identity",
+ "entitlements_path",
+ "extra_substitutions",
+ "info_plist",
+ "test_data_files",
+
+ # Arguments supported by executable target.
"all_dependent_configs",
"allow_circular_includes_from",
+ "asmflags",
+ "bundle_data",
"cflags",
"cflags_c",
"cflags_cc",
- "cflags_objc",
"cflags_objcc",
"check_includes",
"configs",
"data",
"data_deps",
"defines",
+ "deps",
"include_dirs",
+ "inputs",
"ldflags",
+ "lib_dirs",
"libs",
"output_extension",
"output_name",
+ "precompiled_header",
+ "precompiled_source",
"public",
"public_configs",
"public_deps",
"sources",
"visibility",
])
+ testonly = true
- if (defined(invoker.deps)) {
- deps = invoker.deps
- } else {
+ _app_name = target_name
+ if (defined(invoker.app_name)) {
+ _app_name = invoker.app_name
+ }
+ _bundle_test_name = _app_name
+ if (defined(invoker.bundle_test_name)) {
+ _bundle_test_name = invoker.bundle_test_name
+ }
+
+ if (!defined(invoker.extra_substitutions)) {
+ extra_substitutions = []
+ }
+ extra_substitutions += [ "BUNDLE_ID_TEST_NAME=$_bundle_test_name" ]
+
+ if (!defined(invoker.bundle_data)) {
+ bundle_data = []
+ }
+ bundle_data += [ "//testing/gtest_ios/Default.png" ]
+
+ if (!defined(invoker.info_plist)) {
+ info_plist = "//testing/gtest_ios/unittest-Info.plist"
+ }
+
+ if (!defined(invoker.entitlements_path)) {
+ entitlements_path = ""
+ }
+
+ if (!defined(invoker.code_signing_identity)) {
+ code_signing_identity = ios_code_signing_identity
+ }
+
+ if (!defined(invoker.deps)) {
brettw 2016/01/22 19:00:12 I'd make this: if (!defined(deps)) { now.
sdefresne 2016/01/25 14:01:22 Done.
deps = []
}
deps += [
« build/config/ios/ios_gen_plist.py ('K') | « build/toolchain/mac/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698