Commit ca60da81 authored by Rohit Rao's avatar Rohit Rao Committed by Commit Bot

[ios] Adds data_deps support to the chrome_ios_eg2_test template.

This will allow us to add dependencies to ensure that EG2 host apps are
always compiled alongside their test modules.  Previously, bots would
incrementally compile only the test modules and then fail when the host
app wasn't present.

BUG=1019533

Change-Id: I42fca4f6767fba723dcb425b6485a1211c714b09
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1949847
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: default avatarSylvain Defresne <sdefresne@chromium.org>
Cr-Commit-Position: refs/heads/master@{#739038}
parent 1c9c98d9
...@@ -1698,6 +1698,7 @@ template("ios_xctest_bundle") { ...@@ -1698,6 +1698,7 @@ template("ios_xctest_bundle") {
create_signed_bundle(_target_name) { create_signed_bundle(_target_name) {
forward_variables_from(invoker, forward_variables_from(invoker,
[ [
"data_deps",
"enable_code_signing", "enable_code_signing",
"product_type", "product_type",
"xcode_test_application_name", "xcode_test_application_name",
...@@ -1788,6 +1789,7 @@ template("ios_xctest_test") { ...@@ -1788,6 +1789,7 @@ template("ios_xctest_test") {
} }
ios_xctest_bundle(_xctest_target) { ios_xctest_bundle(_xctest_target) {
forward_variables_from(invoker, [ "data_deps" ])
output_name = _xctest_output output_name = _xctest_output
product_type = _ios_xcode_xctest_bundle_id product_type = _ios_xcode_xctest_bundle_id
host_target = _host_target host_target = _host_target
...@@ -1996,6 +1998,7 @@ template("ios_xcuitest_test") { ...@@ -1996,6 +1998,7 @@ template("ios_xcuitest_test") {
[ [
"xcode_test_application_name", "xcode_test_application_name",
"xctest_bundle_principal_class", "xctest_bundle_principal_class",
"data_deps",
]) ])
product_type = _ios_xcode_xcuitest_bundle_id product_type = _ios_xcode_xcuitest_bundle_id
......
...@@ -29,18 +29,21 @@ chrome_ios_eg2_test("ios_chrome_autofill_automation_eg2tests_module") { ...@@ -29,18 +29,21 @@ chrome_ios_eg2_test("ios_chrome_autofill_automation_eg2tests_module") {
xcode_test_application_name = "ios_chrome_eg2tests" xcode_test_application_name = "ios_chrome_eg2tests"
deps = [ "//ios/chrome/browser/autofill/automation:eg2_tests" ] deps = [ "//ios/chrome/browser/autofill/automation:eg2_tests" ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_bookmarks_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_bookmarks_eg2tests_module") {
xcode_test_application_name = "ios_chrome_eg2tests" xcode_test_application_name = "ios_chrome_eg2tests"
deps = [ "//ios/chrome/browser/ui/bookmarks:eg2_tests" ] deps = [ "//ios/chrome/browser/ui/bookmarks:eg2_tests" ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_device_check_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_device_check_eg2tests_module") {
xcode_test_application_name = "ios_chrome_eg2tests" xcode_test_application_name = "ios_chrome_eg2tests"
deps = [ "//ios/chrome/test/earl_grey:device_check_eg2_tests" ] deps = [ "//ios/chrome/test/earl_grey:device_check_eg2_tests" ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_integration_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_integration_eg2tests_module") {
...@@ -62,12 +65,14 @@ chrome_ios_eg2_test("ios_chrome_integration_eg2tests_module") { ...@@ -62,12 +65,14 @@ chrome_ios_eg2_test("ios_chrome_integration_eg2tests_module") {
"//ios/chrome/browser/ui/content_suggestions:eg2_tests", "//ios/chrome/browser/ui/content_suggestions:eg2_tests",
"//ios/chrome/browser/ui/integration_tests:eg2_tests", "//ios/chrome/browser/ui/integration_tests:eg2_tests",
] ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_smoke_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_smoke_eg2tests_module") {
xcode_test_application_name = "ios_chrome_eg2tests" xcode_test_application_name = "ios_chrome_eg2tests"
deps = [ "//ios/chrome/test/earl_grey2:eg2_tests" ] deps = [ "//ios/chrome/test/earl_grey2:eg2_tests" ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_settings_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_settings_eg2tests_module") {
...@@ -80,12 +85,14 @@ chrome_ios_eg2_test("ios_chrome_settings_eg2tests_module") { ...@@ -80,12 +85,14 @@ chrome_ios_eg2_test("ios_chrome_settings_eg2tests_module") {
"//ios/chrome/browser/ui/settings/language:eg2_tests", "//ios/chrome/browser/ui/settings/language:eg2_tests",
"//ios/chrome/browser/ui/settings/password:eg2_tests", "//ios/chrome/browser/ui/settings/password:eg2_tests",
] ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_signin_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_signin_eg2tests_module") {
xcode_test_application_name = "ios_chrome_eg2tests" xcode_test_application_name = "ios_chrome_eg2tests"
deps = [ "//ios/chrome/browser/ui/signin_interaction:eg2_tests" ] deps = [ "//ios/chrome/browser/ui/signin_interaction:eg2_tests" ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_ui_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_ui_eg2tests_module") {
...@@ -121,12 +128,14 @@ chrome_ios_eg2_test("ios_chrome_ui_eg2tests_module") { ...@@ -121,12 +128,14 @@ chrome_ios_eg2_test("ios_chrome_ui_eg2tests_module") {
"//ios/chrome/browser/ui/toolbar:eg2_tests", "//ios/chrome/browser/ui/toolbar:eg2_tests",
"//ios/chrome/browser/ui/webui:eg2_tests", "//ios/chrome/browser/ui/webui:eg2_tests",
] ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
chrome_ios_eg2_test("ios_chrome_web_eg2tests_module") { chrome_ios_eg2_test("ios_chrome_web_eg2tests_module") {
xcode_test_application_name = "ios_chrome_eg2tests" xcode_test_application_name = "ios_chrome_eg2tests"
deps = [ "//ios/chrome/browser/web:eg2_tests" ] deps = [ "//ios/chrome/browser/web:eg2_tests" ]
data_deps = [ ":ios_chrome_eg2tests" ]
} }
source_set("eg2_tests") { source_set("eg2_tests") {
......
...@@ -139,6 +139,7 @@ template("chrome_ios_eg2_test") { ...@@ -139,6 +139,7 @@ template("chrome_ios_eg2_test") {
[ [
"xcode_test_application_name", "xcode_test_application_name",
"deps", "deps",
"data_deps",
]) ])
xctest_bundle_principal_class = "ChromeEGTestBundleMain" xctest_bundle_principal_class = "ChromeEGTestBundleMain"
......
...@@ -22,6 +22,7 @@ chrome_ios_eg2_test("ios_cwt_chromedriver_tests_module") { ...@@ -22,6 +22,7 @@ chrome_ios_eg2_test("ios_cwt_chromedriver_tests_module") {
xcode_test_application_name = "ios_cwt_chromedriver_tests" xcode_test_application_name = "ios_cwt_chromedriver_tests"
deps = [ ":cwt_chromedriver_tests" ] deps = [ ":cwt_chromedriver_tests" ]
data_deps = [ ":ios_cwt_chromedriver_tests" ]
} }
source_set("shared_helper_headers") { source_set("shared_helper_headers") {
......
...@@ -75,6 +75,7 @@ template("ios_eg2_test") { ...@@ -75,6 +75,7 @@ template("ios_eg2_test") {
"xctest_bundle_principal_class", "xctest_bundle_principal_class",
"bundle_deps", "bundle_deps",
"deps", "deps",
"data_deps",
]) ])
if (!defined(deps)) { if (!defined(deps)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment