| # Copyright 2015 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/web/js_compile.gni") |
| |
| source_set("browser") { |
| configs += [ "//build/config/compiler:enable_arc" ] |
| sources = [ |
| "autofill_agent.h", |
| "autofill_agent.mm", |
| "autofill_client_ios_bridge.h", |
| "autofill_driver_ios.h", |
| "autofill_driver_ios.mm", |
| "autofill_driver_ios_bridge.h", |
| "autofill_driver_ios_webframe.h", |
| "autofill_driver_ios_webframe.mm", |
| "autofill_java_script_feature.h", |
| "autofill_java_script_feature.mm", |
| "autofill_switches.cc", |
| "autofill_switches.h", |
| "credit_card_util.h", |
| "credit_card_util.mm", |
| "form_suggestion.h", |
| "form_suggestion.mm", |
| "form_suggestion_provider.h", |
| "form_suggestion_provider_query.h", |
| "form_suggestion_provider_query.mm", |
| "personal_data_manager_observer_bridge.h", |
| "personal_data_manager_observer_bridge.mm", |
| "suggestion_controller_java_script_feature.h", |
| "suggestion_controller_java_script_feature.mm", |
| ] |
| |
| deps = [ |
| ":autofill_js", |
| ":suggestion_controller_js", |
| ":util", |
| "//base", |
| "//components/autofill/core/browser", |
| "//components/autofill/core/common", |
| "//components/autofill/ios/form_util", |
| "//components/autofill/ios/form_util:form_handler_feature", |
| "//components/autofill/ios/form_util:form_util_feature", |
| "//components/prefs:prefs", |
| "//components/prefs/ios", |
| "//components/ukm/ios:ukm_url_recorder", |
| "//google_apis", |
| "//ios/web/common", |
| "//ios/web/public", |
| "//ios/web/public/deprecated", |
| "//ios/web/public/js_messaging", |
| "//ios/web/public/security", |
| "//services/metrics/public/cpp:metrics_cpp", |
| "//services/metrics/public/cpp:ukm_builders", |
| "//services/network/public/cpp", |
| "//ui/accessibility", |
| "//ui/gfx/geometry", |
| "//url", |
| ] |
| } |
| |
| source_set("util") { |
| configs += [ "//build/config/compiler:enable_arc" ] |
| sources = [ |
| "autofill_util.h", |
| "autofill_util.mm", |
| ] |
| deps = [ |
| "//base", |
| "//components/autofill/core/browser", |
| "//components/autofill/core/common", |
| "//ios/web/public", |
| "//ios/web/public/js_messaging", |
| "//ios/web/public/security", |
| "//url", |
| ] |
| } |
| |
| js_compile_bundle("autofill_js") { |
| closure_entry_point = "__crWeb.autofill" |
| sources = [ "resources/autofill_controller.js" ] |
| } |
| |
| js_compile_bundle("suggestion_controller_js") { |
| closure_entry_point = "__crWeb.suggestion" |
| sources = [ "resources/suggestion_controller.js" ] |
| } |
| |
| source_set("test_support") { |
| testonly = true |
| configs += [ "//build/config/compiler:enable_arc" ] |
| sources = [ |
| "credit_card_save_manager_test_observer_bridge.h", |
| "credit_card_save_manager_test_observer_bridge.mm", |
| "fake_autofill_agent.h", |
| "fake_autofill_agent.mm", |
| "ios_test_event_waiter.h", |
| ] |
| public_deps = [ ":browser" ] |
| deps = [ |
| "//base", |
| "//base/test:test_support", |
| "//components/autofill/core/browser", |
| "//components/leveldb_proto:leveldb_proto", |
| "//ios/web/public", |
| "//ios/web/public/js_messaging", |
| ] |
| } |
| |
| source_set("unit_tests") { |
| testonly = true |
| configs += [ "//build/config/compiler:enable_arc" ] |
| sources = [ |
| "autofill_agent_unittests.mm", |
| "autofill_util_unittests.mm", |
| "form_suggestion_provider_query_unittests.mm", |
| ] |
| deps = [ |
| ":browser", |
| ":util", |
| "//base", |
| "//base/test:test_support", |
| "//components/autofill/core/browser:test_support", |
| "//components/autofill/ios/form_util", |
| "//components/autofill/ios/form_util:form_handler_feature", |
| "//components/leveldb_proto:leveldb_proto", |
| "//components/prefs", |
| "//ios/web/public", |
| "//ios/web/public/js_messaging", |
| "//ios/web/public/test", |
| "//ios/web/public/test:test_fixture", |
| "//ios/web/public/test/fakes", |
| "//services/metrics/public/cpp:ukm_builders", |
| "//testing/gmock", |
| "//testing/gtest", |
| "//third_party/ocmock", |
| ] |
| } |
| |
| bundle_data("autofill_test_bundle_data") { |
| testonly = true |
| sources = [ "//components/test/data/autofill/credit_card_upload_form_address_and_cc.html" ] |
| outputs = [ "{{bundle_resources_dir}}/" + |
| "{{source_root_relative_dir}}/{{source_file_part}}" ] |
| } |