| # Copyright 2017 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. |
| |
| if (!is_ios && !is_android) { |
| import("//mojo/public/tools/bindings/mojom.gni") |
| import("//services/service_manager/public/cpp/service.gni") |
| import("//services/service_manager/public/service_manifest.gni") |
| import("//services/service_manager/public/tools/test/service_test.gni") |
| |
| static_library("service") { |
| sources = [ |
| "cryptauth_client_factory_impl.cc", |
| "cryptauth_client_factory_impl.h", |
| "cryptauth_enroller_factory_impl.cc", |
| "cryptauth_enroller_factory_impl.h", |
| "cryptauth_token_fetcher_impl.cc", |
| "cryptauth_token_fetcher_impl.h", |
| "device_sync_impl.cc", |
| "device_sync_impl.h", |
| "fake_device_sync.cc", |
| "fake_device_sync.h", |
| "multidevice_service.cc", |
| "multidevice_service.h", |
| ] |
| |
| deps = [ |
| "//base", |
| "//net", |
| "//services/identity/public/cpp", |
| ] |
| |
| public_deps = [ |
| "//components/cryptauth", |
| "//components/multidevice/service/public/interfaces", |
| "//services/identity/public/mojom", |
| "//services/service_manager/public/cpp", |
| ] |
| } |
| |
| service_manifest("multidevice_manifest") { |
| name = "multidevice" |
| source = "multidevice_service_manifest.json" |
| } |
| |
| source_set("unit_tests") { |
| testonly = true |
| |
| sources = [ |
| "cryptauth_token_fetcher_impl_unittest.cc", |
| ] |
| |
| deps = [ |
| ":service", |
| "//base", |
| "//base/test:test_support", |
| "//components/cryptauth", |
| "//components/cryptauth:test_support", |
| "//components/multidevice/service/public/interfaces", |
| "//mojo/common", |
| "//services/identity/public/cpp:test_support", |
| "//services/service_manager/public/cpp:service_test_support", |
| "//testing/gmock", |
| "//testing/gtest", |
| ] |
| } |
| |
| service("multidevice") { |
| sources = [ |
| "test_main.cc", |
| ] |
| |
| deps = [ |
| ":service", |
| "//base", |
| "//components/cryptauth", |
| ] |
| } |
| |
| service_test("multidevice_service_unittest") { |
| sources = [ |
| "multidevice_service_unittest.cc", |
| ] |
| |
| catalog = ":multidevice_service_unittest_catalog" |
| |
| include_dirs = [ "testing/gmock/include" ] |
| deps = [ |
| ":multidevice", |
| "//base", |
| "//components/multidevice/service/public/interfaces", |
| "//mojo/common", |
| "//services/service_manager/public/cpp:service_test_support", |
| "//testing/gmock", |
| "//testing/gtest", |
| ] |
| } |
| |
| service_manifest("multidevice_service_unittest_manifest") { |
| name = "multidevice_service_unittest" |
| source = "multidevice_service_unittest_manifest.json" |
| } |
| |
| catalog("multidevice_service_unittest_catalog") { |
| embedded_services = [ ":multidevice_service_unittest_manifest" ] |
| standalone_services = [ ":multidevice_manifest" ] |
| } |
| } |