1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
# Copyright 2014 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("//third_party/protobuf/proto_library.gni")
proto_library("proto") {
sources = [ "internal/proto/shared_db_metadata.proto" ]
}
component("leveldb_proto") {
sources = [
"internal/leveldb_database.cc",
"internal/leveldb_database.h",
"internal/leveldb_proto_feature_list.cc",
"internal/leveldb_proto_feature_list.h",
"internal/migration_delegate.cc",
"internal/migration_delegate.h",
"internal/proto_database_impl.cc",
"internal/proto_database_impl.h",
"internal/proto_database_selector.cc",
"internal/proto_database_selector.h",
"internal/proto_leveldb_wrapper.cc",
"internal/proto_leveldb_wrapper.h",
"internal/proto_leveldb_wrapper_metrics.cc",
"internal/proto_leveldb_wrapper_metrics.h",
"internal/shared_proto_database.cc",
"internal/shared_proto_database.h",
"internal/shared_proto_database_client.cc",
"internal/shared_proto_database_client.h",
"internal/shared_proto_database_provider.cc",
"internal/shared_proto_database_provider.h",
"internal/unique_proto_database.cc",
"internal/unique_proto_database.h",
"public/proto_database.cc",
"public/proto_database.h",
"public/proto_database_provider.cc",
"public/proto_database_provider.h",
"public/shared_proto_database_client_list.cc",
"public/shared_proto_database_client_list.h",
]
defines = [ "IS_LEVELDB_PROTO_IMPL" ]
deps = [ ":proto" ]
public_deps = [
"//base",
"//components/keyed_service/core",
"//third_party/leveldatabase",
]
}
source_set("test_support") {
testonly = true
sources = [ "testing/fake_db.h" ]
public_deps = [
":leveldb_proto",
"//base",
"//base/test:test_support",
"//components/leveldb_proto/testing/proto",
]
}
source_set("unit_tests") {
testonly = true
sources = [
"internal/proto_database_impl_unittest.cc",
"internal/shared_proto_database_client_list_unittest.cc",
"internal/shared_proto_database_client_unittest.cc",
"internal/shared_proto_database_unittest.cc",
"internal/unique_proto_database_unittest.cc",
]
deps = [
":proto",
":test_support",
"//testing/gmock",
"//testing/gtest",
]
}
|