chromium/components/reading_list/core/BUILD.gn

# Copyright 2016 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//components/reading_list/features/reading_list.gni")

source_set("core") {
  sources = [
    "dual_reading_list_model.cc",
    "dual_reading_list_model.h",
    "offline_url_utils.cc",
    "offline_url_utils.h",
    "reading_list_entry.cc",
    "reading_list_entry.h",
    "reading_list_local_data_batch_uploader.cc",
    "reading_list_local_data_batch_uploader.h",
    "reading_list_model.h",
    "reading_list_model_impl.cc",
    "reading_list_model_impl.h",
    "reading_list_model_observer.h",
    "reading_list_model_storage.h",
    "reading_list_model_storage_impl.cc",
    "reading_list_model_storage_impl.h",
    "reading_list_pref_names.cc",
    "reading_list_pref_names.h",
    "reading_list_sync_bridge.cc",
    "reading_list_sync_bridge.h",
  ]
  deps = [
    "//components/keyed_service/core",
    "//components/prefs",
    "//components/sync",
    "//net",
    "//url",
  ]
  public_deps = [
    "//base",
    "//components/reading_list/core/proto",
    "//google_apis",
  ]
}

static_library("test_support") {
  testonly = true

  sources = [
    "fake_reading_list_model_storage.cc",
    "fake_reading_list_model_storage.h",
    "mock_reading_list_model_observer.cc",
    "mock_reading_list_model_observer.h",
    "reading_list_test_utils.cc",
    "reading_list_test_utils.h",
  ]
  deps = [ "//components/sync/model" ]
  public_deps = [
    ":core",
    "//base",
    "//testing/gmock",
  ]
}

source_set("unit_tests") {
  testonly = true
  sources = [
    "dual_reading_list_model_unittest.cc",
    "offline_url_utils_unittest.cc",
    "reading_list_entry_unittest.cc",
    "reading_list_local_data_batch_uploader_unittest.cc",
    "reading_list_model_storage_impl_unittest.cc",
    "reading_list_model_unittest.cc",
    "reading_list_sync_bridge_unittest.cc",
  ]
  deps = [
    ":core",
    ":test_support",
    "//base",
    "//base/test:test_support",
    "//components/sync",
    "//components/sync:test_support",
    "//testing/gtest",
    "//url",
  ]
}