1# Copyright (c) 2021-2022 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("//base/notification/common_event_service/event.gni")
15import("//build/test.gni")
16
17module_output_path = "common_event_service/frameworks/native"
18
19ohos_unittest("matching_skills_test") {
20  module_out_path = module_output_path
21
22  sources = [ "matching_skills_test.cpp" ]
23
24  configs = []
25
26  deps = [ "${ces_native_path}:cesfwk_innerkits" ]
27
28  external_deps = [
29    "ability_base:want",
30    "c_utils:utils",
31    "eventhandler:libeventhandler",
32    "hilog:libhilog",
33    "ipc:ipc_core",
34  ]
35}
36
37ohos_unittest("common_event_subscribe_test") {
38  module_out_path = module_output_path
39
40  sources = [ "common_event_subscribe_test.cpp" ]
41
42  configs = []
43
44  deps = [
45    "${ces_core_path}:cesfwk_core",
46    "${ces_native_path}:cesfwk_innerkits",
47    "${services_path}:cesfwk_services_static",
48  ]
49
50  external_deps = [
51    "ability_base:want",
52    "access_token:libaccesstoken_sdk",
53    "bundle_framework:appexecfwk_base",
54    "bundle_framework:appexecfwk_core",
55    "c_utils:utils",
56    "eventhandler:libeventhandler",
57    "ffrt:libffrt",
58    "hilog:libhilog",
59    "init:libbegetutil",
60    "ipc:ipc_core",
61  ]
62}
63
64ohos_unittest("common_event_unsubscribe_test") {
65  module_out_path = module_output_path
66
67  sources = [ "common_event_unsubscribe_test.cpp" ]
68
69  configs = []
70
71  deps = [
72    "${ces_core_path}:cesfwk_core",
73    "${ces_native_path}:cesfwk_innerkits",
74    "${services_path}:cesfwk_services_static",
75  ]
76
77  external_deps = [
78    "ability_base:want",
79    "access_token:libaccesstoken_sdk",
80    "bundle_framework:appexecfwk_base",
81    "bundle_framework:appexecfwk_core",
82    "c_utils:utils",
83    "eventhandler:libeventhandler",
84    "ffrt:libffrt",
85    "hilog:libhilog",
86    "init:libbegetutil",
87    "ipc:ipc_core",
88  ]
89}
90
91ohos_unittest("common_event_subscribe_info_test") {
92  module_out_path = module_output_path
93
94  sources = [ "common_event_subscribe_info_test.cpp" ]
95
96  configs = []
97
98  deps = [
99    "${ces_core_path}:cesfwk_core",
100    "${ces_native_path}:cesfwk_innerkits",
101    "${services_path}:cesfwk_services_static",
102  ]
103
104  external_deps = [
105    "ability_base:want",
106    "access_token:libaccesstoken_sdk",
107    "bundle_framework:appexecfwk_base",
108    "bundle_framework:appexecfwk_core",
109    "c_utils:utils",
110    "eventhandler:libeventhandler",
111    "ffrt:libffrt",
112    "hilog:libhilog",
113    "init:libbegetutil",
114    "ipc:ipc_core",
115  ]
116}
117
118group("unittest") {
119  testonly = true
120  deps = []
121
122  deps += [
123    ":common_event_subscribe_info_test",
124    ":common_event_subscribe_test",
125    ":common_event_unsubscribe_test",
126    ":matching_skills_test",
127  ]
128}
129