blob: 6bf2fcdea31f380e8db1d2898c666b665824cdda [file] [log] [blame]
# Copyright 2016 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//ios/build/config.gni")
import("//ios/third_party/earl_grey/ios_eg_test.gni")
import("//ios/third_party/earl_grey2/ios_eg2_test.gni")
group("all_tests") {
testonly = true
deps = [
":ios_web_shell_eg2tests",
":ios_web_shell_eg2tests_module",
":ios_web_shell_egtests",
]
}
ios_eg_test("ios_web_shell_egtests") {
defines = [ "CHROME_EARL_GREY_1" ]
info_plist = "//ios/web/shell/Info.plist"
sources = [
"context_menu_egtest.mm",
"page_state_egtest.mm",
]
deps = [
":earl_grey_test_support",
"//base",
"//base/test:test_support",
"//ios/testing:http_server_bundle_data",
"//ios/testing/earl_grey:earl_grey_support",
"//ios/web",
"//ios/web:earl_grey_test_support",
"//ios/web/public/test",
"//ios/web/public/test:element_selector",
"//ios/web/public/test/fakes",
"//ios/web/shell",
"//net:test_support",
"//url",
]
configs += [ "//build/config/compiler:enable_arc" ]
assert_no_deps = ios_assert_no_deps
}
source_set("earl_grey_test_support") {
defines = [ "CHROME_EARL_GREY_1" ]
testonly = true
deps = [
"//base",
"//base/test:test_support",
"//ios/testing:nserror_support",
"//ios/testing/earl_grey:earl_grey_support",
"//ios/third_party/earl_grey:earl_grey+link",
"//ios/web",
"//ios/web:earl_grey_test_support",
"//ios/web/public/test",
"//ios/web/public/test:element_selector",
"//ios/web/shell",
"//ios/web/shell:shell_interfaces",
"//testing/gtest:gtest",
"//url",
]
public_deps = [
"//build/config/ios:xctest",
]
sources = [
"app/navigation_test_util.h",
"app/navigation_test_util.mm",
"app/web_shell_test_util.h",
"app/web_shell_test_util.mm",
"app/web_view_interaction_test_util.h",
"app/web_view_interaction_test_util.mm",
"earl_grey/shell_actions.h",
"earl_grey/shell_actions.mm",
"earl_grey/shell_actions_app_interface.h",
"earl_grey/shell_actions_app_interface.mm",
"earl_grey/shell_earl_grey.h",
"earl_grey/shell_earl_grey.mm",
"earl_grey/shell_earl_grey_app_interface.h",
"earl_grey/shell_earl_grey_app_interface.mm",
"earl_grey/shell_matchers.h",
"earl_grey/shell_matchers.mm",
"earl_grey/shell_matchers_app_interface.h",
"earl_grey/shell_matchers_app_interface.mm",
"earl_grey/web_shell_test_case.h",
"earl_grey/web_shell_test_case.mm",
]
configs += [ "//build/config/compiler:enable_arc" ]
}
################################
# EG2 targets.
source_set("eg_app_support+eg2") {
defines = [ "CHROME_EARL_GREY_2" ]
configs += [
"//build/config/compiler:enable_arc",
"//build/config/ios:xctest_config",
]
testonly = true
sources = [
"app/navigation_test_util.h",
"app/navigation_test_util.mm",
"app/web_shell_test_util.h",
"app/web_shell_test_util.mm",
"app/web_view_interaction_test_util.h",
"app/web_view_interaction_test_util.mm",
"earl_grey/shell_actions_app_interface.h",
"earl_grey/shell_actions_app_interface.mm",
"earl_grey/shell_earl_grey_app_interface.h",
"earl_grey/shell_earl_grey_app_interface.mm",
"earl_grey/shell_matchers_app_interface.h",
"earl_grey/shell_matchers_app_interface.mm",
]
deps = [
"//base",
"//base/test:test_support",
"//ios/testing:nserror_support",
"//ios/testing/earl_grey:eg_app_support+eg2",
"//ios/third_party/earl_grey2:app_framework+link",
"//ios/web",
"//ios/web:eg_app_support+eg2",
"//ios/web/public/test",
"//ios/web/public/test/http_server",
"//ios/web/shell",
"//ios/web/shell:shell_interfaces",
"//url",
]
}
source_set("eg_test_support+eg2") {
defines = [ "CHROME_EARL_GREY_2" ]
configs += [
"//build/config/compiler:enable_arc",
"//build/config/ios:xctest_config",
]
testonly = true
sources = [
"earl_grey/shell_actions.h",
"earl_grey/shell_actions.mm",
"earl_grey/shell_actions_app_interface.h",
"earl_grey/shell_earl_grey.h",
"earl_grey/shell_earl_grey.mm",
"earl_grey/shell_earl_grey_app_interface.h",
"earl_grey/shell_matchers.h",
"earl_grey/shell_matchers.mm",
"earl_grey/shell_matchers_app_interface.h",
"earl_grey/web_shell_test_case.h",
"earl_grey/web_shell_test_case.mm",
]
deps = [
"//base",
"//base/test:test_support",
"//ios/testing:http_server_bundle_data",
"//ios/testing:nserror_support",
"//ios/testing/earl_grey:eg_test_support+eg2",
"//ios/third_party/earl_grey2:test_lib",
"//ios/web/public/test:element_selector",
"//ios/web/shell:shell_interfaces",
"//url",
]
}
source_set("eg_tests+eg2") {
defines = [ "CHROME_EARL_GREY_2" ]
configs += [
"//build/config/compiler:enable_arc",
"//build/config/ios:xctest_config",
]
testonly = true
sources = [
"context_menu_egtest.mm",
"page_state_egtest.mm",
]
deps = [
":eg_test_support+eg2",
"//base",
"//ios/testing/earl_grey:eg_test_support+eg2",
"//ios/third_party/earl_grey2:test_lib",
"//ios/web/public/test:element_selector",
"//ios/web/public/test/http_server",
"//net:test_support",
]
libs = [ "UIKit.framework" ]
}
ios_eg2_test_app_host("ios_web_shell_eg2tests") {
info_plist = "//ios/web/shell/Info.plist"
deps = [
"//ios/web/shell",
# Test support libraries.
":eg_app_support+eg2",
"//ios/testing/earl_grey:eg_app_support+eg2",
]
}
ios_eg2_test("ios_web_shell_eg2tests_module") {
xcode_test_application_name = "ios_web_shell_eg2tests"
deps = [
# Test support libraries.
":eg_tests+eg2",
]
}