1# Copyright (c) 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("//foundation/multimedia/player_framework/config.gni") 16import("./../../../multimedia_player_framework_aafwk.gni") 17 18module_output_path = "player_framework/soundpool" 19 20ohos_unittest("soundpool_unit_test") { 21 module_out_path = module_output_path 22 include_dirs = [ 23 "./include", 24 "${multimedia_player_framework_path}/frameworks/native/soundpool", 25 "${multimedia_player_framework_path}/test/unittest/common/include", 26 "${multimedia_player_framework_path}/interfaces/inner_api/native/soundpool/include", 27 ] 28 29 cflags = [ 30 "-Wall", 31 "-Werror", 32 ] 33 34 if (player_framework_support_jssoundpool) { 35 sources = [ 36 "src/soundpool_mock.cpp", 37 "src/soundpool_unit_test.cpp", 38 ] 39 } 40 41 deps = [ 42 "${multimedia_player_framework_path}/frameworks/native/soundpool:soundpool_client", 43 "${multimedia_player_framework_path}/interfaces/inner_api/native:media_client", 44 ] 45 46 external_deps = [ 47 "audio_framework:audio_client", 48 "audio_framework:audio_renderer", 49 "hilog:libhilog", 50 ] 51 52 resource_config_file = "${multimedia_player_framework_path}/test/unittest/resources/ohos_test.xml" 53} 54