# Copyright 2018 The Chromium Authors # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import("//build/chromeos/crosier_tests.gni") import("//build/config/chromeos/args.gni") assert(is_chromeos) static_library("smart_dim") { friend = [ ":unit_tests" ] public = [ "metrics.h", "ml_agent.h", ] sources = [ "builtin_worker.cc", "builtin_worker.h", "download_worker.cc", "download_worker.h", "metrics.cc", "ml_agent.cc", "ml_agent.h", "ml_agent_util.cc", "ml_agent_util.h", "smart_dim_worker.cc", "smart_dim_worker.h", ] deps = [ "//ash/constants", "//base", "//chrome/browser:resources", "//chrome/browser/ash/power/ml:user_activity_event_proto", "//chrome/browser/ash/power/ml:user_activity_ukm_logger_helpers", "//chrome/common:constants", "//chromeos/services/machine_learning/public/cpp", "//chromeos/services/machine_learning/public/mojom", "//components/assist_ranker", "//components/assist_ranker/proto", "//components/sessions", "//ui/base", ] } source_set("unit_tests") { testonly = true sources = [ "ml_agent_unittest.cc", "ml_agent_util_unittest.cc", ] deps = [ ":smart_dim", "//ash/constants", "//base", "//chromeos:test_support", "//chromeos/dbus/machine_learning", "//chromeos/services/machine_learning/public/cpp", "//chromeos/services/machine_learning/public/cpp:stub", "//components/assist_ranker/proto", "//content/test:test_support", "//testing/gtest", ] } if (is_chromeos_device) { crosier_tests("integration_tests") { sources = [ "smart_dim_integration_test.cc" ] sources_metadata = [ "smart_dim_integration_test.yaml" ] deps = [ ":smart_dim", "//base/test:test_support", "//chrome/browser", "//chrome/browser:browser_process", "//chrome/browser/ash/power/ml", "//chrome/browser/component_updater", "//chrome/common", "//chrome/test:ash_integration_test_support", "//components/component_updater", "//net:test_support", "//testing/gtest", "//ui/aura", ] } }