• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2023-2024 Huawei Device Co., Ltd.
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6#     http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11# See the License for the specific language governing permissions and
12# limitations under the License.
13import("//build/test.gni")
14import("//foundation/ability/ability_runtime/ability_runtime.gni")
15
16module_output_path = "ability_runtime/ability_runtime/abilitymgr"
17
18ohos_unittest("auto_startup_info_test") {
19  module_out_path = module_output_path
20
21  include_dirs = [
22    "${ability_runtime_innerkits_path}/ability_manager/include",
23    "${ability_runtime_abilitymgr_path}/include",
24    "${ability_runtime_services_path}/common/include",
25  ]
26
27  sources = [
28    "${ability_runtime_services_path}/abilitymgr/src/ability_auto_startup_service.cpp",
29    "${ability_runtime_services_path}/abilitymgr/src/auto_startup_info.cpp",
30    "auto_startup_info_test.cpp",
31  ]
32
33  configs = []
34
35  deps = [
36    "${ability_runtime_abilitymgr_path}/:abilityms",
37    "${ability_runtime_innerkits_path}/ability_manager:ability_manager",
38    "${ability_runtime_innerkits_path}/ability_manager:ability_start_setting",
39    "${ability_runtime_native_path}/ability:ability_context_native",
40    "${ability_runtime_native_path}/ability/native:auto_startup_callback",
41    "${ability_runtime_services_path}/abilitymgr:abilityms",
42    "${ability_runtime_services_path}/common:perm_verification",
43  ]
44
45  external_deps = [
46    "ability_base:want",
47    "ability_base:zuri",
48    "ability_runtime:ability_manager",
49    "access_token:libaccesstoken_sdk",
50    "bundle_framework:appexecfwk_base",
51    "bundle_framework:appexecfwk_core",
52    "c_utils:utils",
53    "common_event_service:cesfwk_innerkits",
54    "eventhandler:libeventhandler",
55    "ffrt:libffrt",
56    "googletest:gtest_main",
57    "hilog:libhilog",
58    "hisysevent:libhisysevent",
59    "image_framework:image_native",
60    "ipc:ipc_core",
61    "kv_store:distributeddata_inner",
62    "safwk:api_cache_manager",
63  ]
64
65  if (ability_runtime_graphics) {
66    external_deps += [
67      "window_manager:libwsutils",
68      "window_manager:scene_session",
69    ]
70  }
71  if (ability_runtime_upms) {
72    deps += [
73      "${ability_runtime_innerkits_path}/uri_permission:uri_permission_mgr",
74    ]
75  }
76  cflags_cc = []
77  if (os_dlp_part_enabled) {
78    cflags_cc += [ "-DWITH_DLP" ]
79  }
80}
81
82group("unittest") {
83  testonly = true
84
85  deps = [ ":auto_startup_info_test" ]
86}
87