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

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

Issue 2859583004: Revert of (Reland x2) Expose resources in Robolectric/JUnit tests. (Closed)
Patch Set: Created 3 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 | « 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 50014b54eadeefa76fc9f8d38ab20a3f0a977c8d..a08a4755523c40ed357bf8869112b651a42b47b2 100644
--- a/build/config/android/rules.gni
+++ b/build/config/android/rules.gni
@@ -579,10 +579,7 @@
assert(defined(invoker.res_dir))
_base_path = "$target_gen_dir/$target_name"
-
- # JUnit tests use resource zip files. These must not be put in gen/
- # directory or they will not be available to tester bots.
- _resources_zip = "${target_out_dir}/${target_name}.resources.zip"
+ _resources_zip = _base_path + ".resources.zip"
_build_config = _base_path + ".build_config"
write_build_config("${target_name}__build_config") {
@@ -679,10 +676,7 @@
assert(defined(invoker.resource_dirs))
base_path = "$target_gen_dir/$target_name"
-
- # JUnit tests use resource zip files. These must not be put in gen/
- # directory or they will not be available to tester bots.
- zip_path = "${target_out_dir}/${target_name}.resources.zip"
+ zip_path = base_path + ".resources.zip"
srcjar_path = base_path + ".srcjar"
r_text_out_path = base_path + "_R.txt"
build_config = base_path + ".build_config"
@@ -901,10 +895,7 @@
forward_variables_from(invoker, [ "testonly" ])
base_path = "$target_gen_dir/$target_name"
-
- # JUnit tests use resource zip files. These must not be put in gen/
- # directory or they will not be available to tester bots.
- resources_zip = "${target_out_dir}/${target_name}.resources.zip"
+ resources_zip = base_path + ".resources.zip"
build_config = base_path + ".build_config"
write_build_config("${target_name}__build_config") {
@@ -916,7 +907,6 @@
grit_target_name = "${target_name}__grit"
grit_output_dir = "$target_gen_dir/$extra_output_path"
-
grit(grit_target_name) {
forward_variables_from(invoker, [ "deps" ])
grit_flags = [
@@ -971,10 +961,7 @@
forward_variables_from(invoker, [ "testonly" ])
base_path = "$target_gen_dir/$target_name"
-
- # JUnit tests use resource zip files. These must not be put in gen/
- # directory or they will not be available to tester bots.
- resources_zip = "${target_out_dir}/${target_name}.resources.zip"
+ resources_zip = base_path + ".resources.zip"
build_config = base_path + ".build_config"
build_config_target_name = "${target_name}__build_config"
@@ -1080,27 +1067,11 @@
_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) {
@@ -1120,7 +1091,6 @@
}
group(target_name) {
public_deps = [
- ":$_build_config_target_name",
":$_java_binary_target_name",
":$_test_runner_target_name",
]
@@ -1546,10 +1516,7 @@
gen_dir = "$target_gen_dir/$target_name"
base_path = "$gen_dir/$target_name"
_build_config = "$target_gen_dir/$target_name.build_config"
-
- # JUnit tests use resource zip files. These must not be put in gen/
- # directory or they will not be available to tester bots.
- resources_zip_path = "${target_out_dir}/${target_name}.resources.zip"
+ resources_zip_path = "$base_path.resources.zip"
_all_resources_zip_path = "$base_path.resources.all.zip"
_jar_path = "$base_path.jar"
_lib_dex_path = "$base_path.dex.jar"
« 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