Index: build/config/android/rules.gni |
diff --git a/build/config/android/rules.gni b/build/config/android/rules.gni |
index e66d9280c38d6484951727b35a3d9022a459aa7b..2746f18fc67544572cae1f33d05042d3a5a76a63 100644 |
--- a/build/config/android/rules.gni |
+++ b/build/config/android/rules.gni |
@@ -1084,11 +1084,26 @@ if (enable_java_templates) { |
_java_binary_target_name = "${target_name}__java_binary" |
_test_runner_target_name = "${target_name}__test_runner_script" |
+ _build_config = "$target_gen_dir/$target_name.build_config" |
+ _build_config_target_name = "${target_name}__build_config" |
+ write_build_config(_build_config_target_name) { |
+ type = "junit_binary" |
+ build_config = _build_config |
+ if (defined(invoker.deps)) { |
+ possible_config_deps = invoker.deps |
+ } |
+ } |
+ |
test_runner_script(_test_runner_target_name) { |
test_name = invoker.target_name |
test_suite = invoker.target_name |
test_type = "junit" |
ignore_all_data_deps = true |
+ forward_variables_from(invoker, |
+ [ |
+ "android_manifest_path", |
+ "package_name", |
+ ]) |
} |
java_binary(_java_binary_target_name) { |
@@ -1108,6 +1123,7 @@ if (enable_java_templates) { |
} |
group(target_name) { |
public_deps = [ |
+ ":$_build_config_target_name", |
":$_java_binary_target_name", |
":$_test_runner_target_name", |
] |