Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cherry pick PR #548: Requisite ukm changes to get it building #728

Merged
merged 2 commits into from
Jun 27, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 45 additions & 34 deletions components/ukm/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,14 @@ static_library("ukm") {
"//components/variations",
"//url",
]

if (use_cobalt_customizations) {
public_deps -= [
"//services/metrics/public/cpp:metrics_cpp",
"//services/metrics/public/cpp:ukm_builders",
"//services/metrics/public/mojom",
]
}
}

# Helper library for observing signals that we need to clear any local data.
Expand Down Expand Up @@ -79,40 +87,43 @@ static_library("test_support") {
]
}

source_set("unit_tests") {
testonly = true
sources = [
"observers/sync_disable_observer_unittest.cc",
"ukm_service_unittest.cc",
]
# TODO(b/283275474): Re-enable as many tests as possible.
if (!use_cobalt_customizations) {
source_set("unit_tests") {
testonly = true
sources = [
"observers/sync_disable_observer_unittest.cc",
"ukm_service_unittest.cc",
]

deps = [
":observers",
":test_support",
":ukm",
"//base",
"//base/test:test_support",
"//components/metrics",
"//components/metrics:test_support",
"//components/prefs:test_support",
"//components/sync",
"//components/sync:test_support_driver",
"//components/sync_preferences:test_support",
"//components/variations",
"//net:test_support",
"//services/metrics/public/cpp:ukm_builders",
"//testing/gtest",
"//third_party/zlib/google:compression_utils",
"//url",
]
}
deps = [
":observers",
":test_support",
":ukm",
"//base",
"//base/test:test_support",
"//components/metrics",
"//components/metrics:test_support",
"//components/prefs:test_support",
"//components/sync",
"//components/sync:test_support_driver",
"//components/sync_preferences:test_support",
"//components/variations",
"//net:test_support",
"//services/metrics/public/cpp:ukm_builders",
"//testing/gtest",
"//third_party/zlib/google:compression_utils",
"//url",
]
}

# Convenience testing target
test("ukm_unittests") {
deps = [
":unit_tests",
"//base",
"//base/test:test_support",
"//components/test:run_all_unittests",
]
# Convenience testing target
test("ukm_unittests") {
deps = [
":unit_tests",
"//base",
"//base/test:test_support",
"//components/test:run_all_unittests",
]
}
}