• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2023 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.
13
14import("//build/test.gni")
15import("//foundation/bundlemanager/app_domain_verify/app_domain_verify.gni")
16
17config("module_private_config") {
18  visibility = [ ":*" ]
19  configs = [ "//build/config/compiler:exceptions" ]
20  include_dirs = [
21    "${app_domain_verify_client_path}/include",
22    "${app_domain_verify_service_path}/include",
23    "${app_domain_verify_service_path}/include/agent/core",
24    "${app_domain_verify_service_path}/include/agent/zidl",
25    "${app_domain_verify_service_path}/include/agent/bms",
26    "${app_domain_verify_service_path}/include/agent/constant",
27    "${app_domain_verify_service_path}/include/agent/httpsession",
28    "${app_domain_verify_service_path}/include/agent/utils",
29    "${app_domain_verify_service_path}/include/manager/rdb",
30    "${app_domain_verify_service_path}/include/manager/core",
31    "${app_domain_verify_service_path}/include/manager/constant",
32    "${app_domain_verify_service_path}/include/manager/zidl",
33    "${app_domain_verify_common_path}/include",
34    "${app_domain_verify_frameworks_common_path}/include",
35    "${app_domain_verify_frameworks_common_path}/include/utils",
36    "${app_domain_verify_frameworks_common_path}/include/httpsession",
37    "${app_domain_verify_frameworks_extension_path}/include",
38    "${app_domain_verify_frameworks_verifier_path}/include",
39    "${app_domain_verify_frameworks_verifier_path}/include/constant",
40    "${app_domain_verify_test_path}/mock/include",
41    "${app_domain_verify_frameworks_common_path}/include/dfx",
42  ]
43}
44
45module_output_path = "app_domain_verify/app_domain_verify"
46
47ohos_unittest("app_domain_verify_agent_verifier_test") {
48  module_out_path = module_output_path
49
50  sources = [
51    "${app_domain_verify_frameworks_verifier_path}/src/domain_json_util.cpp",
52    "${app_domain_verify_frameworks_verifier_path}/src/domain_verifier.cpp",
53    "${app_domain_verify_frameworks_verifier_path}/src/verify_http_task.cpp",
54    "${app_domain_verify_frameworks_verifier_path}/src/verify_task.cpp",
55    "domain_json_util_test.cpp",
56    "domain_verifier_test.cpp",
57    "verify_task_test.cpp",
58  ]
59  configs = [ ":module_private_config" ]
60  external_deps = [
61    "ability_base:want",
62    "ability_base:zuri",
63    "bundle_framework:appexecfwk_base",
64    "bundle_framework:appexecfwk_core",
65    "c_utils:utils",
66    "eventhandler:libeventhandler",
67    "ffrt:libffrt",
68    "googletest:gmock_main",
69    "googletest:gtest_main",
70    "hilog:libhilog",
71    "hisysevent:libhisysevent",
72    "image_framework:image_native",
73    "ipc:ipc_core",
74    "json:nlohmann_json_static",
75    "netstack:http_client",
76    "os_account:os_account_innerkits",
77    "relational_store:native_rdb",
78    "safwk:system_ability_fwk",
79    "samgr:samgr_proxy",
80  ]
81
82  defines = [ "API_EXPORT=__attribute__((visibility (\"default\")))" ]
83  deps = [
84    "${app_domain_verify_client_path}:app_domain_verify_mgr_client",
85    "${app_domain_verify_common_path}:app_domain_verify_common",
86    "${app_domain_verify_frameworks_common_path}:app_domain_verify_frameworks_common",
87  ]
88}
89