# Copyright 2024 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
source_set("presenters") {
sources = [
"notifications_alert_presenter.h",
"notifications_confirmation_presenter.h",
]
deps = [ "//base" ]
}
source_set("opt_in_alert_coordinator") {
sources = [
"notifications_opt_in_alert_coordinator.h",
"notifications_opt_in_alert_coordinator.mm",
]
deps = [
":metrics",
"//ios/chrome/app/strings",
"//ios/chrome/browser/push_notification/model:push_notification_client",
"//ios/chrome/browser/push_notification/model:push_notification_service",
"//ios/chrome/browser/push_notification/model:push_notification_service_header",
"//ios/chrome/browser/shared/coordinator/alert",
"//ios/chrome/browser/shared/coordinator/chrome_coordinator",
"//ios/chrome/browser/shared/model/application_context",
"//ios/chrome/browser/shared/model/browser",
"//ios/chrome/browser/shared/model/browser_state",
"//ios/chrome/browser/shared/model/profile",
"//ios/chrome/browser/shared/public/commands",
"//ui/base",
]
}
source_set("notifications_opt_in") {
sources = [
"notifications_opt_in_coordinator.h",
"notifications_opt_in_coordinator.mm",
"notifications_opt_in_coordinator_delegate.h",
"notifications_opt_in_mediator.h",
"notifications_opt_in_mediator.mm",
]
deps = [
":metrics",
":notifications_opt_in_ui",
":opt_in_alert_coordinator",
"//components/prefs",
"//components/signin/public/base",
"//components/sync/base:features",
"//ios/chrome/app/strings",
"//ios/chrome/browser/content_notification/model:util",
"//ios/chrome/browser/ntp/model:set_up_list_item_type",
"//ios/chrome/browser/ntp/model:set_up_list_prefs",
"//ios/chrome/browser/push_notification/model:push_notification_client",
"//ios/chrome/browser/push_notification/model:push_notification_service",
"//ios/chrome/browser/push_notification/model:push_notification_service_header",
"//ios/chrome/browser/shared/coordinator/chrome_coordinator",
"//ios/chrome/browser/shared/model/application_context",
"//ios/chrome/browser/shared/model/browser",
"//ios/chrome/browser/shared/public/commands",
"//ios/chrome/browser/signin/model",
"//ios/chrome/browser/ui/authentication/signin:constants",
"//ios/chrome/common/ui/promo_style",
"//ui/base",
]
}
source_set("notifications_opt_in_ui") {
sources = [
"notifications_opt_in_consumer.h",
"notifications_opt_in_item_identifier.h",
"notifications_opt_in_presenter.h",
"notifications_opt_in_view_controller.h",
"notifications_opt_in_view_controller.mm",
]
deps = [
"//ios/chrome/app/strings",
"//ios/chrome/browser/shared/coordinator/chrome_coordinator",
"//ios/chrome/browser/shared/public/features",
"//ios/chrome/browser/shared/ui/symbols",
"//ios/chrome/browser/shared/ui/table_view:utils",
"//ios/chrome/browser/shared/ui/table_view/cells",
"//ios/chrome/browser/shared/ui/util",
"//ios/chrome/common/ui/colors",
"//ios/chrome/common/ui/promo_style",
"//ui/base",
]
}
source_set("metrics") {
sources = [
"metrics.h",
"metrics.mm",
]
}
source_set("test_support") {
testonly = true
sources = [
"scoped_notification_auth_swizzler.h",
"scoped_notification_auth_swizzler.mm",
]
deps = [
"//base",
"//ios/chrome/test/earl_grey:eg_test_support+eg2",
]
}
source_set("eg2_tests") {
configs += [ "//build/config/ios:xctest_config" ]
testonly = true
sources = [
"notifications_opt_in_egtest.mm",
"push_notification_egtest.mm",
]
deps = [
":test_support",
"//base",
"//base/test:test_support",
"//ios/chrome/app/strings",
"//ios/chrome/browser/shared/model/prefs:pref_names",
"//ios/chrome/browser/shared/public/features",
"//ios/chrome/browser/signin/model:fake_system_identity",
"//ios/chrome/browser/tips_notifications/model:utils",
"//ios/chrome/browser/ui/authentication:eg_test_support+eg2",
"//ios/chrome/browser/ui/authentication/signin:constants",
"//ios/chrome/browser/ui/content_suggestions:constants",
"//ios/chrome/browser/ui/content_suggestions:eg_test_support+eg2",
"//ios/chrome/browser/ui/content_suggestions/set_up_list:constants",
"//ios/chrome/common/ui/promo_style:constants",
"//ios/chrome/test/earl_grey:eg_test_support+eg2",
"//ios/testing/earl_grey:eg_test_support+eg2",
"//ui/base",
"//ui/strings",
]
}
source_set("unit_tests") {
testonly = true
sources = [ "notifications_opt_in_mediator_unittest.mm" ]
deps = [
":notifications_opt_in",
":notifications_opt_in_ui",
"//base/test:test_support",
"//components/prefs",
"//components/prefs:test_support",
"//ios/chrome/browser/ntp/model:set_up_list_item_type",
"//ios/chrome/browser/ntp/model:set_up_list_prefs",
"//ios/chrome/browser/push_notification/model:constants",
"//ios/chrome/browser/push_notification/model:push_notification_service",
"//ios/chrome/browser/shared/model/application_context",
"//ios/chrome/browser/shared/model/prefs:pref_names",
"//ios/chrome/browser/shared/model/profile/test",
"//ios/chrome/browser/shared/public/features",
"//ios/chrome/browser/signin/model",
"//ios/chrome/browser/signin/model:test_support",
"//ios/chrome/test:test_support",
"//ios/web/public/test",
"//testing/gtest:gtest",
"//third_party/ocmock",
]
}