1# Copyright (c) 2022-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( 16 "//foundation/distributedhardware/distributed_input/distributedinput.gni") 17 18module_out_path = "distributed_input/ipc" 19 20group("dinputsourcecallbackunittest") { 21 testonly = true 22 23 deps = [ ":dinput_source_callback_test" ] 24} 25 26## UnitTest dinput_source_callback_test {{{ 27ohos_unittest("dinput_source_callback_test") { 28 module_out_path = module_out_path 29 30 include_dirs = [ 31 "${common_path}/include", 32 "${frameworks_path}/include", 33 "${fwk_common_path}/log/include", 34 "${fwk_common_path}/utils/include", 35 "${fwk_interfaces_path}/include", 36 "${fwk_interfaces_path}/include/ipc", 37 "${innerkits_path}/include", 38 "${innerkits_path}/src", 39 "${ipc_path}/include", 40 "${ipc_path}/src", 41 "${utils_path}/include", 42 "//third_party/json/include", 43 ] 44 45 sources = [ 46 "${ipc_path}/src/add_white_list_infos_call_back_proxy.cpp", 47 "${ipc_path}/src/add_white_list_infos_call_back_stub.cpp", 48 "${ipc_path}/src/del_white_list_infos_call_back_proxy.cpp", 49 "${ipc_path}/src/del_white_list_infos_call_back_stub.cpp", 50 "${ipc_path}/src/distributed_input_source_proxy.cpp", 51 "${ipc_path}/src/distributed_input_source_stub.cpp", 52 "${ipc_path}/src/get_sink_screen_infos_call_back_proxy.cpp", 53 "${ipc_path}/src/get_sink_screen_infos_call_back_stub.cpp", 54 "${ipc_path}/src/input_node_listener_proxy.cpp", 55 "${ipc_path}/src/input_node_listener_stub.cpp", 56 "${ipc_path}/src/prepare_d_input_call_back_proxy.cpp", 57 "${ipc_path}/src/prepare_d_input_call_back_stub.cpp", 58 "${ipc_path}/src/register_d_input_call_back_proxy.cpp", 59 "${ipc_path}/src/register_d_input_call_back_stub.cpp", 60 "${ipc_path}/src/simulation_event_listener_proxy.cpp", 61 "${ipc_path}/src/simulation_event_listener_stub.cpp", 62 "${ipc_path}/src/start_d_input_call_back_proxy.cpp", 63 "${ipc_path}/src/start_d_input_call_back_stub.cpp", 64 "${ipc_path}/src/start_stop_d_inputs_call_back_proxy.cpp", 65 "${ipc_path}/src/start_stop_d_inputs_call_back_stub.cpp", 66 "${ipc_path}/src/stop_d_input_call_back_proxy.cpp", 67 "${ipc_path}/src/stop_d_input_call_back_stub.cpp", 68 "${ipc_path}/src/unprepare_d_input_call_back_proxy.cpp", 69 "${ipc_path}/src/unprepare_d_input_call_back_stub.cpp", 70 "${ipc_path}/src/unregister_d_input_call_back_proxy.cpp", 71 "${ipc_path}/src/unregister_d_input_call_back_stub.cpp", 72 "dinput_source_callback_unittest.cpp", 73 ] 74 75 cflags = [ 76 "-Wall", 77 "-Werror", 78 "-g3", 79 "-Dprivate=public", 80 "-Dprotected=public", 81 ] 82 83 defines = [ 84 "HI_LOG_ENABLE", 85 "DH_LOG_TAG=\"distributedinpututtest\"", 86 "LOG_DOMAIN=0xD004100", 87 ] 88 89 deps = [ 90 "${dfx_utils_path}:libdinput_dfx_utils", 91 "${utils_path}:libdinput_utils", 92 ] 93 94 external_deps = [ 95 "c_utils:utils", 96 "distributed_hardware_fwk:libdhfwk_sdk", 97 "dsoftbus:softbus_client", 98 "eventhandler:libeventhandler", 99 "ipc:ipc_core", 100 "safwk:system_ability_fwk", 101 "samgr:samgr_proxy", 102 ] 103 104 cflags_cc = [ "-DHILOG_ENABLE" ] 105} 106## UnitTest dinput_source_callback_test }}} 107