• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022-2025 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(
16    "//foundation/distributedhardware/distributed_screen/distributedscreen.gni")
17
18module_out_path =
19    "distributed_screen/distributed_screen/dscreen_sink_service_test"
20
21config("module_private_config") {
22  visibility = [ ":*" ]
23  include_dirs = [
24    "include",
25    "${common_path}/include",
26    "${interfaces_path}/innerkits/native_cpp/screen_sink/include",
27    "${interfaces_path}/innerkits/native_cpp/screen_sink/include/callback",
28    "${interfaces_path}/innerkits/native_cpp/screen_source/include",
29    "${interfaces_path}/innerkits/native_cpp/screen_source/include/callback",
30    "${services_path}/common/utils/include",
31    "${services_path}/screenclient/include",
32    "${services_path}/screenservice/sinkservice/dscreenservice/include",
33    "${services_path}/screenservice/sinkservice/screenregionmgr",
34    "${services_path}/screentransport/screensinktrans/include",
35  ]
36}
37
38## UnitTest DScreenSinkStubTest
39ohos_unittest("DScreenSinkStubTest") {
40  sanitize = {
41    cfi = true
42    cfi_cross_dso = true
43    debug = false
44  }
45  module_out_path = module_out_path
46
47  sources = [
48    "${services_path}/screenservice/test/unittest/sinkservice/dscreenservice/src/dscreen_sink_service_test.cpp",
49    "${services_path}/screenservice/test/unittest/sinkservice/dscreenservice/src/dscreen_sink_stub_test.cpp",
50  ]
51
52  configs = [
53    ":module_private_config",
54    "${common_path}/test/unittest/resource:dscreen_unittest_public_config",
55  ]
56
57  deps = [
58    "${interfaces_path}/innerkits/native_cpp/screen_sink:distributed_screen_sink_sdk",
59    "${services_path}/screenservice/sinkservice:distributed_screen_sink",
60  ]
61
62  external_deps = [
63    "access_token:libaccesstoken_sdk",
64    "cJSON:cjson",
65    "c_utils:utils",
66    "distributed_hardware_fwk:distributed_av_receiver",
67    "distributed_hardware_fwk:distributedhardwareutils",
68    "distributed_hardware_fwk:libdhfwk_sdk",
69    "googletest:gmock",
70    "googletest:gtest_main",
71    "graphic_2d:librender_service_base",
72    "graphic_2d:librender_service_client",
73    "graphic_surface:surface",
74    "hilog:libhilog",
75    "ipc:ipc_core",
76    "json:nlohmann_json_static",
77    "safwk:system_ability_fwk",
78    "samgr:samgr_proxy",
79    "window_manager:libdm",
80  ]
81}
82