1# Copyright (c) 2021 - 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_camera/distributedcamera.gni") 17 18module_out_path = "distributed_camera/dcamera_sink_mgr_test" 19 20config("module_private_config") { 21 visibility = [ ":*" ] 22 include_dirs = [ 23 "${graphicstandard_path}/frameworks/surface/include", 24 "${camerastandard_path}/interfaces/inner_api/native/camera/include", 25 "${camerastandard_path}/interfaces/inner_api/native/camera/include/input", 26 "${camerastandard_path}/interfaces/inner_api/native/camera/include/output", 27 "${camerastandard_path}/interfaces/inner_api/native/camera/include/session", 28 "${camerastandard_path}/services/camera_service/binder/base/include", 29 "${camerastandard_path}/services/camera_service/binder/client/include", 30 "${camerastandard_path}/services/camera_service/binder/server/include", 31 "${camerastandard_path}/services/camera_service/include", 32 "${mediastandard_path}/interfaces/innerkits/native/media/include", 33 "${services_path}/cameraservice/sinkservice/include/distributedcameramgr", 34 "${services_path}/cameraservice/sinkservice/include/distributedcameramgr/callback", 35 "${services_path}/cameraservice/sinkservice/include/distributedcameramgr/eventbus", 36 "${services_path}/cameraservice/sinkservice/include/distributedcameramgr/interface", 37 "${services_path}/cameraservice/sinkservice/include/distributedcameramgr/listener", 38 "${services_path}/cameraservice/cameraoperator/client/include", 39 "${services_path}/cameraservice/cameraoperator/handler/include", 40 "${services_path}/cameraservice/base/include", 41 "${services_path}/channel/include", 42 "${services_path}/data_process/include/pipeline", 43 "${services_path}/data_process/include/interfaces", 44 "${services_path}/data_process/include/utils", 45 "${common_path}/include/constants", 46 "${common_path}/include/utils", 47 "${innerkits_path}/native_cpp/camera_source/include", 48 "${innerkits_path}/native_cpp/camera_source/include/callback", 49 50 "${fwk_common_path}/utils/include", 51 "${fwk_utils_path}/include/eventbus", 52 "${feeding_smoother_path}/base", 53 "${feeding_smoother_path}/derived", 54 "${feeding_smoother_path}/utils", 55 ] 56} 57 58ohos_unittest("DCameraSinkMgrTest") { 59 module_out_path = module_out_path 60 61 sources = [ 62 "dcamera_sink_access_control_test.cpp", 63 "dcamera_sink_controller_test.cpp", 64 "dcamera_sink_data_process_test.cpp", 65 "dcamera_sink_dev_test.cpp", 66 "dcamera_sink_output_test.cpp", 67 "dcamera_sink_service_ipc_test.cpp", 68 ] 69 70 configs = [ ":module_private_config" ] 71 72 deps = [ 73 "${camerastandard_path}/frameworks/native/camera:camera_framework", 74 "${common_path}:distributed_camera_utils", 75 "${graphicstandard_path}:libsurface", 76 "${services_path}/cameraservice/cameraoperator/handler:distributed_camera_handler", 77 "${services_path}/cameraservice/sinkservice:distributed_camera_sink", 78 "${services_path}/channel:distributed_camera_channel", 79 "//third_party/jsoncpp:jsoncpp", 80 ] 81 82 external_deps = [ 83 "c_utils:utils", 84 "drivers_interface_camera:metadata", 85 "drivers_interface_distributed_camera:libdistributed_camera_provider_proxy_1.0", 86 "eventhandler:libeventhandler", 87 "ipc:ipc_core", 88 "player_framework:media_client", 89 ] 90 91 defines = [ 92 "HI_LOG_ENABLE", 93 "DH_LOG_TAG=\"DCameraSinkMgrTest\"", 94 "LOG_DOMAIN=0xD004100", 95 ] 96} 97 98group("dcamera_sink_mgr_test") { 99 testonly = true 100 deps = [ ":DCameraSinkMgrTest" ] 101} 102