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.
13
14if (defined(ohos_lite)) {
15  import("//build/lite/config/test.gni")
16} else {
17  import("//build/ohos.gni")
18}
19
20import("//foundation/distributedhardware/device_manager/device_manager.gni")
21
22group("lite_devicemanager_test") {
23  if (ohos_build_type == "debug") {
24    deps = [ ":lite_devicemanager_unittest" ]
25  }
26}
27
28if (defined(ohos_lite)) {
29  if (ohos_build_type == "debug") {
30    unittest("lite_devicemanager_unittest") {
31      output_extension = "bin"
32      output_dir = "$root_out_dir/test/unittest/devicemanager"
33
34      include_dirs = [
35        "include",
36        "${common_path}/include",
37        "${common_path}/include/dfx",
38        "${common_path}/include/dfx/lite",
39        "${common_path}/include/ipc",
40        "${common_path}/include/ipc/lite",
41        "${common_path}/include/ipc/model",
42        "${innerkits_path}/native_cpp/include",
43        "${innerkits_path}/native_cpp/include/ipc",
44        "${innerkits_path}/native_cpp/include/ipc/lite",
45        "${innerkits_path}/native_cpp/include/notify",
46        "${interfaces_path}/c/ipc/include",
47        "${interfaces_path}/ipc_core/include",
48        "${samgr_lite_path}/kits/samgr",
49        "${samgr_lite_path}/kits/registry",
50        "${utils_lite_path}/include",
51      ]
52
53      sources = [ "device_manager_linux_test.cpp" ]
54
55      deps = [ "${innerkits_path}/native_cpp:devicemanagersdk" ]
56    }
57  }
58}
59