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_camera/distributedcamera.gni") 17 18module_out_path = "${unittest_output_path}/dcamera_data_process_test" 19 20config("module_private_config") { 21 visibility = [ ":*" ] 22 include_dirs = [ 23 "${services_path}/data_process/include/interfaces", 24 "${services_path}/data_process/include/eventbus", 25 "${services_path}/data_process/include/pipeline", 26 "${services_path}/data_process/include/utils", 27 "${services_path}/data_process/include/pipeline_node/multimedia_codec/decoder", 28 "${services_path}/data_process/include/pipeline_node/multimedia_codec/encoder", 29 "${services_path}/data_process/include/pipeline_node/fpscontroller", 30 "${services_path}/data_process/include/pipeline_node/scale_conversion", 31 "${services_path}/cameraservice/sinkservice/include/distributedcameramgr", 32 "${common_path}/include/constants", 33 "${common_path}/include/utils", 34 "${innerkits_path}/native_cpp/camera_source/include", 35 "${feeding_smoother_path}/base", 36 "${services_path}/cameraservice/base/include", 37 ] 38} 39 40ohos_unittest("DCameraDataProcessPipelineTest") { 41 module_out_path = module_out_path 42 43 cflags = [ 44 "-g", 45 "-O0", 46 "-Wno-unused-variable", 47 "-fno-omit-frame-pointer", 48 "-Dprivate=public", 49 "-Dprotected=public", 50 ] 51 52 sources = [ 53 "dcamera_pipeline_sink_test.cpp", 54 "dcamera_pipeline_source_test.cpp", 55 "decode_surface_listener_test.cpp", 56 ] 57 58 configs = [ ":module_private_config" ] 59 60 deps = [ 61 "${common_path}:distributed_camera_utils", 62 "${services_path}/data_process:distributed_camera_data_process", 63 ] 64 65 external_deps = [ 66 "av_codec:av_codec_client", 67 "c_utils:utils", 68 "distributed_hardware_fwk:distributedhardwareutils", 69 "eventhandler:libeventhandler", 70 "ffmpeg:libohosffmpeg", 71 "graphic_surface:surface", 72 "hilog:libhilog", 73 "hitrace:hitrace_meter", 74 "ipc:ipc_single", 75 ] 76 77 defines = [ 78 "HI_LOG_ENABLE", 79 "DH_LOG_TAG=\"DCameraDataProcessPipelineTest\"", 80 "LOG_DOMAIN=0xD004150", 81 ] 82} 83 84group("dcamera_pipeline_test") { 85 testonly = true 86 deps = [ ":DCameraDataProcessPipelineTest" ] 87} 88