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

Unified Diff: build/config/android/rules.gni

Issue 2864693002: (Reland x3) Expose resources in Robolectric/JUnit tests. (Closed)
Patch Set: Created 3 years, 7 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 | « build/config/android/internal_rules.gni ('k') | chrome/android/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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",
]
« no previous file with comments | « build/config/android/internal_rules.gni ('k') | chrome/android/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698