146f34cbfSopenharmony_ci# Copyright (c) 2024 Huawei Device Co., Ltd.
246f34cbfSopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License");
346f34cbfSopenharmony_ci# you may not use this file except in compliance with the License.
446f34cbfSopenharmony_ci# You may obtain a copy of the License at
546f34cbfSopenharmony_ci#
646f34cbfSopenharmony_ci#     http://www.apache.org/licenses/LICENSE-2.0
746f34cbfSopenharmony_ci#
846f34cbfSopenharmony_ci# Unless required by applicable law or agreed to in writing, software
946f34cbfSopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS,
1046f34cbfSopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1146f34cbfSopenharmony_ci# See the License for the specific language governing permissions and
1246f34cbfSopenharmony_ci# limitations under the License.
1346f34cbfSopenharmony_ci
1446f34cbfSopenharmony_ciimport("//build/ohos.gni")
1546f34cbfSopenharmony_ciimport("//build/test.gni")
1646f34cbfSopenharmony_ciimport("../../../accessibility.gni")
1746f34cbfSopenharmony_ciimport("../../../appgallery.gni")
1846f34cbfSopenharmony_ciimport("../../../bluetooth_part.gni")
1946f34cbfSopenharmony_ciimport("../../../config.gni")
2046f34cbfSopenharmony_ci
2146f34cbfSopenharmony_cigroup("audio_policy_unittest_packages") {
2246f34cbfSopenharmony_ci  testonly = true
2346f34cbfSopenharmony_ci  deps = [
2446f34cbfSopenharmony_ci    ":audio_affinity_parser_test",
2546f34cbfSopenharmony_ci    ":audio_client_tracker_callback_stub_unit_test",
2646f34cbfSopenharmony_ci    ":audio_effect_config_parser_test",
2746f34cbfSopenharmony_ci    ":audio_interrupt_service_unit_test",
2846f34cbfSopenharmony_ci    ":audio_policy_client_stub_impl_test",
2946f34cbfSopenharmony_ci    ":audio_policy_server_unit_test",
3046f34cbfSopenharmony_ci    ":audio_policy_service_all_unit_test",
3146f34cbfSopenharmony_ci    ":audio_routing_manager_listener_stub_unit_test",
3246f34cbfSopenharmony_ci    ":audio_session_timer_test",
3346f34cbfSopenharmony_ci    ":audio_socket_thread_unit_test",
3446f34cbfSopenharmony_ci    ":audio_spatialization_service_unit_test",
3546f34cbfSopenharmony_ci    ":stream_filter_router_unit_test",
3646f34cbfSopenharmony_ci  ]
3746f34cbfSopenharmony_ci}
3846f34cbfSopenharmony_ci
3946f34cbfSopenharmony_cimodule_output_path = "multimedia_audio_framework/audio_policy"
4046f34cbfSopenharmony_ci
4146f34cbfSopenharmony_ciohos_unittest("audio_interrupt_service_unit_test") {
4246f34cbfSopenharmony_ci  module_out_path = module_output_path
4346f34cbfSopenharmony_ci  include_dirs = [
4446f34cbfSopenharmony_ci    "./unittest/audio_interrupt_service_test/include",
4546f34cbfSopenharmony_ci    "../../audio_policy/server/src/service/interrupt",
4646f34cbfSopenharmony_ci  ]
4746f34cbfSopenharmony_ci
4846f34cbfSopenharmony_ci  use_exceptions = true
4946f34cbfSopenharmony_ci
5046f34cbfSopenharmony_ci  cflags = [
5146f34cbfSopenharmony_ci    "-Wall",
5246f34cbfSopenharmony_ci    "-Werror",
5346f34cbfSopenharmony_ci    "-Wno-macro-redefined",
5446f34cbfSopenharmony_ci  ]
5546f34cbfSopenharmony_ci
5646f34cbfSopenharmony_ci  cflags_cc = cflags
5746f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
5846f34cbfSopenharmony_ci
5946f34cbfSopenharmony_ci  external_deps = [
6046f34cbfSopenharmony_ci    "ability_base:want",
6146f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
6246f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
6346f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
6446f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
6546f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
6646f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
6746f34cbfSopenharmony_ci    "c_utils:utils",
6846f34cbfSopenharmony_ci    "data_share:datashare_common",
6946f34cbfSopenharmony_ci    "data_share:datashare_consumer",
7046f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
7146f34cbfSopenharmony_ci    "hdf_core:libhdi",
7246f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
7346f34cbfSopenharmony_ci    "hilog:libhilog",
7446f34cbfSopenharmony_ci    "ipc:ipc_single",
7546f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
7646f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
7746f34cbfSopenharmony_ci    "power_manager:powermgr_client",
7846f34cbfSopenharmony_ci    "pulseaudio:pulse",
7946f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
8046f34cbfSopenharmony_ci  ]
8146f34cbfSopenharmony_ci
8246f34cbfSopenharmony_ci  sources = [
8346f34cbfSopenharmony_ci    "./unittest/audio_interrupt_service_test/src/audio_interrupt_unit_test.cpp",
8446f34cbfSopenharmony_ci  ]
8546f34cbfSopenharmony_ci
8646f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_service" ]
8746f34cbfSopenharmony_ci
8846f34cbfSopenharmony_ci  if (accessibility_enable == true) {
8946f34cbfSopenharmony_ci    external_deps += [
9046f34cbfSopenharmony_ci      "accessibility:accessibility_common",
9146f34cbfSopenharmony_ci      "accessibility:accessibilityconfig",
9246f34cbfSopenharmony_ci    ]
9346f34cbfSopenharmony_ci  }
9446f34cbfSopenharmony_ci
9546f34cbfSopenharmony_ci  if (bluetooth_part_enable == true) {
9646f34cbfSopenharmony_ci    external_deps += [ "bluetooth:btframework" ]
9746f34cbfSopenharmony_ci  }
9846f34cbfSopenharmony_ci
9946f34cbfSopenharmony_ci  if (audio_framework_feature_input) {
10046f34cbfSopenharmony_ci    external_deps += [ "input:libmmi-client" ]
10146f34cbfSopenharmony_ci  }
10246f34cbfSopenharmony_ci
10346f34cbfSopenharmony_ci  if (audio_framework_feature_device_manager) {
10446f34cbfSopenharmony_ci    external_deps += [ "device_manager:devicemanagersdk" ]
10546f34cbfSopenharmony_ci  }
10646f34cbfSopenharmony_ci}
10746f34cbfSopenharmony_ci
10846f34cbfSopenharmony_ciohos_unittest("audio_policy_service_all_unit_test") {
10946f34cbfSopenharmony_ci  module_out_path = module_output_path
11046f34cbfSopenharmony_ci  include_dirs = [
11146f34cbfSopenharmony_ci    "./unittest/audio_policy_service_unit_test/include",
11246f34cbfSopenharmony_ci    "../../audio_policy/server/include/service",
11346f34cbfSopenharmony_ci    "../../audio_policy/server/include",
11446f34cbfSopenharmony_ci  ]
11546f34cbfSopenharmony_ci
11646f34cbfSopenharmony_ci  use_exceptions = true
11746f34cbfSopenharmony_ci
11846f34cbfSopenharmony_ci  cflags = [
11946f34cbfSopenharmony_ci    "-Wall",
12046f34cbfSopenharmony_ci    "-Werror",
12146f34cbfSopenharmony_ci    "-Wno-macro-redefined",
12246f34cbfSopenharmony_ci  ]
12346f34cbfSopenharmony_ci
12446f34cbfSopenharmony_ci  cflags_cc = cflags
12546f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
12646f34cbfSopenharmony_ci
12746f34cbfSopenharmony_ci  external_deps = [
12846f34cbfSopenharmony_ci    "ability_base:want",
12946f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
13046f34cbfSopenharmony_ci    "access_token:libnativetoken_shared",
13146f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
13246f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
13346f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
13446f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
13546f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
13646f34cbfSopenharmony_ci    "c_utils:utils",
13746f34cbfSopenharmony_ci    "data_share:datashare_common",
13846f34cbfSopenharmony_ci    "data_share:datashare_consumer",
13946f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
14046f34cbfSopenharmony_ci    "hdf_core:libhdi",
14146f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
14246f34cbfSopenharmony_ci    "hilog:libhilog",
14346f34cbfSopenharmony_ci    "ipc:ipc_single",
14446f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
14546f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
14646f34cbfSopenharmony_ci    "power_manager:powermgr_client",
14746f34cbfSopenharmony_ci    "pulseaudio:pulse",
14846f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
14946f34cbfSopenharmony_ci    "samgr:samgr_proxy",
15046f34cbfSopenharmony_ci  ]
15146f34cbfSopenharmony_ci
15246f34cbfSopenharmony_ci  sources = [
15346f34cbfSopenharmony_ci    "./unittest/audio_policy_service_unit_test/src/audio_policy_service_first_unit_test.cpp",
15446f34cbfSopenharmony_ci    "./unittest/audio_policy_service_unit_test/src/audio_policy_service_second_unit_test.cpp",
15546f34cbfSopenharmony_ci    "./unittest/audio_policy_service_unit_test/src/audio_policy_service_third_unit_test.cpp",
15646f34cbfSopenharmony_ci  ]
15746f34cbfSopenharmony_ci
15846f34cbfSopenharmony_ci  configs = [ "../../../services/audio_policy:audio_policy_public_config" ]
15946f34cbfSopenharmony_ci
16046f34cbfSopenharmony_ci  deps = [
16146f34cbfSopenharmony_ci    "../../../services/audio_policy:audio_policy_client",
16246f34cbfSopenharmony_ci    "../../audio_policy:audio_policy_service",
16346f34cbfSopenharmony_ci    "../../audio_service:audio_client",
16446f34cbfSopenharmony_ci  ]
16546f34cbfSopenharmony_ci
16646f34cbfSopenharmony_ci  if (accessibility_enable == true) {
16746f34cbfSopenharmony_ci    external_deps += [
16846f34cbfSopenharmony_ci      "accessibility:accessibility_common",
16946f34cbfSopenharmony_ci      "accessibility:accessibilityconfig",
17046f34cbfSopenharmony_ci    ]
17146f34cbfSopenharmony_ci  }
17246f34cbfSopenharmony_ci
17346f34cbfSopenharmony_ci  defines = []
17446f34cbfSopenharmony_ci
17546f34cbfSopenharmony_ci  if (audio_framework_feature_dtmf_tone) {
17646f34cbfSopenharmony_ci    defines += [ "FEATURE_DTMF_TONE" ]
17746f34cbfSopenharmony_ci  }
17846f34cbfSopenharmony_ci
17946f34cbfSopenharmony_ci  if (audio_framework_feature_support_os_account) {
18046f34cbfSopenharmony_ci    defines += [ "SUPPORT_USER_ACCOUNT" ]
18146f34cbfSopenharmony_ci  }
18246f34cbfSopenharmony_ci
18346f34cbfSopenharmony_ci  if (build_variant == "user") {
18446f34cbfSopenharmony_ci    defines += [ "AUDIO_BUILD_VARIANT_USER" ]
18546f34cbfSopenharmony_ci  } else if (build_variant == "root") {
18646f34cbfSopenharmony_ci    defines += [ "AUDIO_BUILD_VARIANT_ROOT" ]
18746f34cbfSopenharmony_ci  }
18846f34cbfSopenharmony_ci
18946f34cbfSopenharmony_ci  if (appgallery_part_enable == true) {
19046f34cbfSopenharmony_ci    defines += [ "FEATURE_APPGALLERY" ]
19146f34cbfSopenharmony_ci  }
19246f34cbfSopenharmony_ci
19346f34cbfSopenharmony_ci  if (bluetooth_part_enable == true) {
19446f34cbfSopenharmony_ci    external_deps += [ "bluetooth:btframework" ]
19546f34cbfSopenharmony_ci  }
19646f34cbfSopenharmony_ci
19746f34cbfSopenharmony_ci  if (audio_framework_feature_input) {
19846f34cbfSopenharmony_ci    defines += [ "FEATURE_MULTIMODALINPUT_INPUT" ]
19946f34cbfSopenharmony_ci    external_deps += [ "input:libmmi-client" ]
20046f34cbfSopenharmony_ci  }
20146f34cbfSopenharmony_ci
20246f34cbfSopenharmony_ci  if (audio_framework_feature_device_manager) {
20346f34cbfSopenharmony_ci    defines += [ "FEATURE_DEVICE_MANAGER" ]
20446f34cbfSopenharmony_ci    external_deps += [ "device_manager:devicemanagersdk" ]
20546f34cbfSopenharmony_ci  }
20646f34cbfSopenharmony_ci
20746f34cbfSopenharmony_ci  if (audio_framework_feature_double_pnp_detect) {
20846f34cbfSopenharmony_ci    defines += [ "AUDIO_DOUBLE_PNP_DETECT" ]
20946f34cbfSopenharmony_ci  }
21046f34cbfSopenharmony_ci}
21146f34cbfSopenharmony_ci
21246f34cbfSopenharmony_ciohos_unittest("audio_effect_config_parser_test") {
21346f34cbfSopenharmony_ci  module_out_path = module_output_path
21446f34cbfSopenharmony_ci  include_dirs = [
21546f34cbfSopenharmony_ci    "./unittest/audio_effect_config_parser_test/include",
21646f34cbfSopenharmony_ci    "../../audio_policy/server/include/service/effect",
21746f34cbfSopenharmony_ci  ]
21846f34cbfSopenharmony_ci
21946f34cbfSopenharmony_ci  cflags = [
22046f34cbfSopenharmony_ci    "-Wall",
22146f34cbfSopenharmony_ci    "-Werror",
22246f34cbfSopenharmony_ci    "-Wno-macro-redefined",
22346f34cbfSopenharmony_ci  ]
22446f34cbfSopenharmony_ci
22546f34cbfSopenharmony_ci  cflags_cc = cflags
22646f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
22746f34cbfSopenharmony_ci
22846f34cbfSopenharmony_ci  external_deps = [
22946f34cbfSopenharmony_ci    "bounds_checking_function:libsec_shared",
23046f34cbfSopenharmony_ci    "c_utils:utils",
23146f34cbfSopenharmony_ci    "eventhandler:libeventhandler",
23246f34cbfSopenharmony_ci    "hilog:libhilog",
23346f34cbfSopenharmony_ci    "init:libbegetutil",
23446f34cbfSopenharmony_ci    "libxml2:libxml2",
23546f34cbfSopenharmony_ci  ]
23646f34cbfSopenharmony_ci
23746f34cbfSopenharmony_ci  sources = [ "./unittest/audio_effect_config_parser_test/src/audio_effect_config_parser_test.cpp" ]
23846f34cbfSopenharmony_ci
23946f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_service" ]
24046f34cbfSopenharmony_ci}
24146f34cbfSopenharmony_ci
24246f34cbfSopenharmony_ciohos_unittest("audio_socket_thread_unit_test") {
24346f34cbfSopenharmony_ci  module_out_path = module_output_path
24446f34cbfSopenharmony_ci
24546f34cbfSopenharmony_ci  include_dirs = [
24646f34cbfSopenharmony_ci    "./unittest/audio_socket_thread_test/include",
24746f34cbfSopenharmony_ci    "../../audio_policy/client/src",
24846f34cbfSopenharmony_ci  ]
24946f34cbfSopenharmony_ci
25046f34cbfSopenharmony_ci  use_exceptions = true
25146f34cbfSopenharmony_ci
25246f34cbfSopenharmony_ci  cflags = [
25346f34cbfSopenharmony_ci    "-Wall",
25446f34cbfSopenharmony_ci    "-Werror",
25546f34cbfSopenharmony_ci    "-Wno-macro-redefined",
25646f34cbfSopenharmony_ci    "-fno-access-control",
25746f34cbfSopenharmony_ci  ]
25846f34cbfSopenharmony_ci
25946f34cbfSopenharmony_ci  external_deps = [
26046f34cbfSopenharmony_ci    "ability_base:session_info",
26146f34cbfSopenharmony_ci    "ability_base:want",
26246f34cbfSopenharmony_ci    "ability_base:zuri",
26346f34cbfSopenharmony_ci    "ability_runtime:ability_connect_callback_stub",
26446f34cbfSopenharmony_ci    "ability_runtime:ability_context_native",
26546f34cbfSopenharmony_ci    "ability_runtime:ability_manager",
26646f34cbfSopenharmony_ci    "ability_runtime:app_context",
26746f34cbfSopenharmony_ci    "ability_runtime:dataobs_manager",
26846f34cbfSopenharmony_ci    "ability_runtime:extension_manager",
26946f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
27046f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
27146f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
27246f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
27346f34cbfSopenharmony_ci    "bounds_checking_function:libsec_shared",
27446f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
27546f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
27646f34cbfSopenharmony_ci    "c_utils:utils",
27746f34cbfSopenharmony_ci    "data_share:datashare_common",
27846f34cbfSopenharmony_ci    "data_share:datashare_consumer",
27946f34cbfSopenharmony_ci    "drivers_interface_audio:libaudio_proxy_4.0",
28046f34cbfSopenharmony_ci    "eventhandler:libeventhandler",
28146f34cbfSopenharmony_ci    "googletest:gmock",
28246f34cbfSopenharmony_ci    "hdf_core:libhdf_host",
28346f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
28446f34cbfSopenharmony_ci    "hdf_core:libhdf_utils",
28546f34cbfSopenharmony_ci    "hdf_core:libhdi",
28646f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
28746f34cbfSopenharmony_ci    "hilog:libhilog",
28846f34cbfSopenharmony_ci    "hisysevent:libhisysevent",
28946f34cbfSopenharmony_ci    "init:libbegetutil",
29046f34cbfSopenharmony_ci    "ipc:ipc_single",
29146f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
29246f34cbfSopenharmony_ci    "media_foundation:media_monitor_client",
29346f34cbfSopenharmony_ci    "media_foundation:media_monitor_common",
29446f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
29546f34cbfSopenharmony_ci    "power_manager:power_setting",
29646f34cbfSopenharmony_ci    "power_manager:powermgr_client",
29746f34cbfSopenharmony_ci    "pulseaudio:pulse",
29846f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
29946f34cbfSopenharmony_ci    "samgr:samgr_proxy",
30046f34cbfSopenharmony_ci  ]
30146f34cbfSopenharmony_ci
30246f34cbfSopenharmony_ci  sources =
30346f34cbfSopenharmony_ci      [ "./unittest/audio_socket_thread_test/src/audio_socket_thread_test.cpp" ]
30446f34cbfSopenharmony_ci
30546f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_service" ]
30646f34cbfSopenharmony_ci}
30746f34cbfSopenharmony_ci
30846f34cbfSopenharmony_ciohos_unittest("audio_policy_server_unit_test") {
30946f34cbfSopenharmony_ci  module_out_path = module_output_path
31046f34cbfSopenharmony_ci  include_dirs = [
31146f34cbfSopenharmony_ci    "./unittest/audio_interrupt_service_test/include",
31246f34cbfSopenharmony_ci    "../../audio_policy/server/src/service/interrupt",
31346f34cbfSopenharmony_ci    "../../audio_policy/server/include",
31446f34cbfSopenharmony_ci    "../../audio_policy/test/unittest/audio_interrupt_service_test/include",
31546f34cbfSopenharmony_ci  ]
31646f34cbfSopenharmony_ci
31746f34cbfSopenharmony_ci  use_exceptions = true
31846f34cbfSopenharmony_ci
31946f34cbfSopenharmony_ci  cflags = [
32046f34cbfSopenharmony_ci    "-Wall",
32146f34cbfSopenharmony_ci    "-Werror",
32246f34cbfSopenharmony_ci    "-Wno-macro-redefined",
32346f34cbfSopenharmony_ci  ]
32446f34cbfSopenharmony_ci
32546f34cbfSopenharmony_ci  cflags_cc = cflags
32646f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
32746f34cbfSopenharmony_ci
32846f34cbfSopenharmony_ci  external_deps = [
32946f34cbfSopenharmony_ci    "ability_base:want",
33046f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
33146f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
33246f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
33346f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
33446f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
33546f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
33646f34cbfSopenharmony_ci    "c_utils:utils",
33746f34cbfSopenharmony_ci    "data_share:datashare_common",
33846f34cbfSopenharmony_ci    "data_share:datashare_consumer",
33946f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
34046f34cbfSopenharmony_ci    "hdf_core:libhdi",
34146f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
34246f34cbfSopenharmony_ci    "hilog:libhilog",
34346f34cbfSopenharmony_ci    "ipc:ipc_single",
34446f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
34546f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
34646f34cbfSopenharmony_ci    "power_manager:powermgr_client",
34746f34cbfSopenharmony_ci    "pulseaudio:pulse",
34846f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
34946f34cbfSopenharmony_ci  ]
35046f34cbfSopenharmony_ci
35146f34cbfSopenharmony_ci  sources = [ "./unittest/audio_interrupt_service_test/src/audio_policy_server_unit_test.cpp" ]
35246f34cbfSopenharmony_ci
35346f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_service" ]
35446f34cbfSopenharmony_ci
35546f34cbfSopenharmony_ci  if (accessibility_enable == true) {
35646f34cbfSopenharmony_ci    external_deps += [
35746f34cbfSopenharmony_ci      "accessibility:accessibility_common",
35846f34cbfSopenharmony_ci      "accessibility:accessibilityconfig",
35946f34cbfSopenharmony_ci    ]
36046f34cbfSopenharmony_ci  }
36146f34cbfSopenharmony_ci
36246f34cbfSopenharmony_ci  if (bluetooth_part_enable == true) {
36346f34cbfSopenharmony_ci    external_deps += [ "bluetooth:btframework" ]
36446f34cbfSopenharmony_ci  }
36546f34cbfSopenharmony_ci
36646f34cbfSopenharmony_ci  if (audio_framework_feature_input) {
36746f34cbfSopenharmony_ci    external_deps += [ "input:libmmi-client" ]
36846f34cbfSopenharmony_ci  }
36946f34cbfSopenharmony_ci
37046f34cbfSopenharmony_ci  if (audio_framework_feature_device_manager) {
37146f34cbfSopenharmony_ci    external_deps += [ "device_manager:devicemanagersdk" ]
37246f34cbfSopenharmony_ci  }
37346f34cbfSopenharmony_ci}
37446f34cbfSopenharmony_ci
37546f34cbfSopenharmony_ciohos_unittest("audio_routing_manager_listener_stub_unit_test") {
37646f34cbfSopenharmony_ci  module_out_path = module_output_path
37746f34cbfSopenharmony_ci  include_dirs = [
37846f34cbfSopenharmony_ci    "./unittest/audio_routing_manager_listener_stub_unit_test/include",
37946f34cbfSopenharmony_ci    "../../audio_policy/client/include/",
38046f34cbfSopenharmony_ci  ]
38146f34cbfSopenharmony_ci
38246f34cbfSopenharmony_ci  use_exceptions = true
38346f34cbfSopenharmony_ci
38446f34cbfSopenharmony_ci  cflags = [
38546f34cbfSopenharmony_ci    "-Wall",
38646f34cbfSopenharmony_ci    "-Werror",
38746f34cbfSopenharmony_ci    "-Wno-macro-redefined",
38846f34cbfSopenharmony_ci  ]
38946f34cbfSopenharmony_ci
39046f34cbfSopenharmony_ci  cflags_cc = cflags
39146f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
39246f34cbfSopenharmony_ci
39346f34cbfSopenharmony_ci  external_deps = [
39446f34cbfSopenharmony_ci    "ability_base:want",
39546f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
39646f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
39746f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
39846f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
39946f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
40046f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
40146f34cbfSopenharmony_ci    "c_utils:utils",
40246f34cbfSopenharmony_ci    "data_share:datashare_common",
40346f34cbfSopenharmony_ci    "data_share:datashare_consumer",
40446f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
40546f34cbfSopenharmony_ci    "hdf_core:libhdi",
40646f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
40746f34cbfSopenharmony_ci    "hilog:libhilog",
40846f34cbfSopenharmony_ci    "ipc:ipc_single",
40946f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
41046f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
41146f34cbfSopenharmony_ci    "power_manager:powermgr_client",
41246f34cbfSopenharmony_ci    "pulseaudio:pulse",
41346f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
41446f34cbfSopenharmony_ci  ]
41546f34cbfSopenharmony_ci
41646f34cbfSopenharmony_ci  sources = [ "./unittest/audio_routing_manager_listener_stub_unit_test/src/audio_routing_manager_listener_stub_unit_test.cpp" ]
41746f34cbfSopenharmony_ci
41846f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_client" ]
41946f34cbfSopenharmony_ci
42046f34cbfSopenharmony_ci  if (accessibility_enable == true) {
42146f34cbfSopenharmony_ci    external_deps += [
42246f34cbfSopenharmony_ci      "accessibility:accessibility_common",
42346f34cbfSopenharmony_ci      "accessibility:accessibilityconfig",
42446f34cbfSopenharmony_ci    ]
42546f34cbfSopenharmony_ci  }
42646f34cbfSopenharmony_ci
42746f34cbfSopenharmony_ci  if (bluetooth_part_enable == true) {
42846f34cbfSopenharmony_ci    external_deps += [ "bluetooth:btframework" ]
42946f34cbfSopenharmony_ci  }
43046f34cbfSopenharmony_ci
43146f34cbfSopenharmony_ci  if (audio_framework_feature_input) {
43246f34cbfSopenharmony_ci    external_deps += [ "input:libmmi-client" ]
43346f34cbfSopenharmony_ci  }
43446f34cbfSopenharmony_ci
43546f34cbfSopenharmony_ci  if (audio_framework_feature_device_manager) {
43646f34cbfSopenharmony_ci    external_deps += [ "device_manager:devicemanagersdk" ]
43746f34cbfSopenharmony_ci  }
43846f34cbfSopenharmony_ci}
43946f34cbfSopenharmony_ci
44046f34cbfSopenharmony_ciohos_unittest("audio_policy_client_stub_impl_test") {
44146f34cbfSopenharmony_ci  module_out_path = module_output_path
44246f34cbfSopenharmony_ci  include_dirs = [
44346f34cbfSopenharmony_ci    "./unittest/audio_policy_client_stub_impl_test/include",
44446f34cbfSopenharmony_ci    "../../audio_policy/client/include",
44546f34cbfSopenharmony_ci  ]
44646f34cbfSopenharmony_ci
44746f34cbfSopenharmony_ci  cflags = [
44846f34cbfSopenharmony_ci    "-Wall",
44946f34cbfSopenharmony_ci    "-Werror",
45046f34cbfSopenharmony_ci    "-Wno-macro-redefined",
45146f34cbfSopenharmony_ci    "-fno-access-control",
45246f34cbfSopenharmony_ci  ]
45346f34cbfSopenharmony_ci
45446f34cbfSopenharmony_ci  external_deps = [
45546f34cbfSopenharmony_ci    "bounds_checking_function:libsec_shared",
45646f34cbfSopenharmony_ci    "c_utils:utils",
45746f34cbfSopenharmony_ci    "eventhandler:libeventhandler",
45846f34cbfSopenharmony_ci    "googletest:gmock",
45946f34cbfSopenharmony_ci    "hilog:libhilog",
46046f34cbfSopenharmony_ci    "init:libbegetutil",
46146f34cbfSopenharmony_ci    "ipc:ipc_single",
46246f34cbfSopenharmony_ci    "samgr:samgr_proxy",
46346f34cbfSopenharmony_ci  ]
46446f34cbfSopenharmony_ci
46546f34cbfSopenharmony_ci  sources = [ "./unittest/audio_policy_client_stub_impl_test/src/audio_policy_client_stub_impl_test.cpp" ]
46646f34cbfSopenharmony_ci
46746f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_client" ]
46846f34cbfSopenharmony_ci}
46946f34cbfSopenharmony_ci
47046f34cbfSopenharmony_ciohos_unittest("audio_client_tracker_callback_stub_unit_test") {
47146f34cbfSopenharmony_ci  module_out_path = module_output_path
47246f34cbfSopenharmony_ci  include_dirs = [
47346f34cbfSopenharmony_ci    "./unittest/audio_client_tracker_callback_stub_unit_test/include",
47446f34cbfSopenharmony_ci    "../../audio_policy/client/include/",
47546f34cbfSopenharmony_ci  ]
47646f34cbfSopenharmony_ci
47746f34cbfSopenharmony_ci  use_exceptions = true
47846f34cbfSopenharmony_ci
47946f34cbfSopenharmony_ci  cflags = [
48046f34cbfSopenharmony_ci    "-Wall",
48146f34cbfSopenharmony_ci    "-Werror",
48246f34cbfSopenharmony_ci    "-Wno-macro-redefined",
48346f34cbfSopenharmony_ci  ]
48446f34cbfSopenharmony_ci
48546f34cbfSopenharmony_ci  cflags_cc = cflags
48646f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
48746f34cbfSopenharmony_ci
48846f34cbfSopenharmony_ci  external_deps = [
48946f34cbfSopenharmony_ci    "ability_base:want",
49046f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
49146f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
49246f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
49346f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
49446f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
49546f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
49646f34cbfSopenharmony_ci    "c_utils:utils",
49746f34cbfSopenharmony_ci    "data_share:datashare_common",
49846f34cbfSopenharmony_ci    "data_share:datashare_consumer",
49946f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
50046f34cbfSopenharmony_ci    "hdf_core:libhdi",
50146f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
50246f34cbfSopenharmony_ci    "hilog:libhilog",
50346f34cbfSopenharmony_ci    "ipc:ipc_single",
50446f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
50546f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
50646f34cbfSopenharmony_ci    "power_manager:powermgr_client",
50746f34cbfSopenharmony_ci    "pulseaudio:pulse",
50846f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
50946f34cbfSopenharmony_ci  ]
51046f34cbfSopenharmony_ci
51146f34cbfSopenharmony_ci  sources = [ "./unittest/audio_client_tracker_callback_stub_unit_test/src/audio_client_tracker_callback_stub_unit_test.cpp" ]
51246f34cbfSopenharmony_ci
51346f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_client" ]
51446f34cbfSopenharmony_ci
51546f34cbfSopenharmony_ci  if (accessibility_enable == true) {
51646f34cbfSopenharmony_ci    external_deps += [
51746f34cbfSopenharmony_ci      "accessibility:accessibility_common",
51846f34cbfSopenharmony_ci      "accessibility:accessibilityconfig",
51946f34cbfSopenharmony_ci    ]
52046f34cbfSopenharmony_ci  }
52146f34cbfSopenharmony_ci
52246f34cbfSopenharmony_ci  if (bluetooth_part_enable == true) {
52346f34cbfSopenharmony_ci    external_deps += [ "bluetooth:btframework" ]
52446f34cbfSopenharmony_ci  }
52546f34cbfSopenharmony_ci
52646f34cbfSopenharmony_ci  if (audio_framework_feature_input) {
52746f34cbfSopenharmony_ci    external_deps += [ "input:libmmi-client" ]
52846f34cbfSopenharmony_ci  }
52946f34cbfSopenharmony_ci
53046f34cbfSopenharmony_ci  if (audio_framework_feature_device_manager) {
53146f34cbfSopenharmony_ci    external_deps += [ "device_manager:devicemanagersdk" ]
53246f34cbfSopenharmony_ci  }
53346f34cbfSopenharmony_ci}
53446f34cbfSopenharmony_ci
53546f34cbfSopenharmony_ciohos_unittest("audio_spatialization_service_unit_test") {
53646f34cbfSopenharmony_ci  module_out_path = module_output_path
53746f34cbfSopenharmony_ci  include_dirs = [
53846f34cbfSopenharmony_ci    "./unittest/audio_spatialization_service_unit_test/include",
53946f34cbfSopenharmony_ci    "../../audio_policy/server/include/service/spatialization",
54046f34cbfSopenharmony_ci  ]
54146f34cbfSopenharmony_ci
54246f34cbfSopenharmony_ci  use_exceptions = true
54346f34cbfSopenharmony_ci
54446f34cbfSopenharmony_ci  cflags = [
54546f34cbfSopenharmony_ci    "-Wall",
54646f34cbfSopenharmony_ci    "-Werror",
54746f34cbfSopenharmony_ci    "-Wno-macro-redefined",
54846f34cbfSopenharmony_ci  ]
54946f34cbfSopenharmony_ci
55046f34cbfSopenharmony_ci  cflags_cc = cflags
55146f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
55246f34cbfSopenharmony_ci
55346f34cbfSopenharmony_ci  external_deps = [
55446f34cbfSopenharmony_ci    "ability_base:want",
55546f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
55646f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
55746f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
55846f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
55946f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
56046f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
56146f34cbfSopenharmony_ci    "c_utils:utils",
56246f34cbfSopenharmony_ci    "data_share:datashare_common",
56346f34cbfSopenharmony_ci    "data_share:datashare_consumer",
56446f34cbfSopenharmony_ci    "googletest:gmock",
56546f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
56646f34cbfSopenharmony_ci    "hdf_core:libhdi",
56746f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
56846f34cbfSopenharmony_ci    "hilog:libhilog",
56946f34cbfSopenharmony_ci    "ipc:ipc_single",
57046f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
57146f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
57246f34cbfSopenharmony_ci    "power_manager:powermgr_client",
57346f34cbfSopenharmony_ci    "pulseaudio:pulse",
57446f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
57546f34cbfSopenharmony_ci  ]
57646f34cbfSopenharmony_ci
57746f34cbfSopenharmony_ci  sources = [ "./unittest/audio_spatialization_service_unit_test/src/audio_spatialization_service_unit_test.cpp" ]
57846f34cbfSopenharmony_ci
57946f34cbfSopenharmony_ci  deps = [
58046f34cbfSopenharmony_ci    "../../../frameworks/native/bluetoothclient:audio_bluetooth_client",
58146f34cbfSopenharmony_ci    "../../audio_policy:audio_policy_service",
58246f34cbfSopenharmony_ci    "../../audio_policy:audio_setting_provider",
58346f34cbfSopenharmony_ci  ]
58446f34cbfSopenharmony_ci}
58546f34cbfSopenharmony_ci
58646f34cbfSopenharmony_ciohos_unittest("stream_filter_router_unit_test") {
58746f34cbfSopenharmony_ci  module_out_path = module_output_path
58846f34cbfSopenharmony_ci  include_dirs = [
58946f34cbfSopenharmony_ci    "./unittest/stream_filter_router_unit_test/include",
59046f34cbfSopenharmony_ci    "../../audio_policy/server/include/service/routers",
59146f34cbfSopenharmony_ci  ]
59246f34cbfSopenharmony_ci
59346f34cbfSopenharmony_ci  use_exceptions = true
59446f34cbfSopenharmony_ci
59546f34cbfSopenharmony_ci  cflags = [
59646f34cbfSopenharmony_ci    "-Wall",
59746f34cbfSopenharmony_ci    "-Werror",
59846f34cbfSopenharmony_ci    "-Wno-macro-redefined",
59946f34cbfSopenharmony_ci  ]
60046f34cbfSopenharmony_ci
60146f34cbfSopenharmony_ci  cflags_cc = cflags
60246f34cbfSopenharmony_ci  cflags_cc += [ "-fno-access-control" ]
60346f34cbfSopenharmony_ci
60446f34cbfSopenharmony_ci  external_deps = [
60546f34cbfSopenharmony_ci    "ability_base:want",
60646f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
60746f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
60846f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
60946f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
61046f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
61146f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
61246f34cbfSopenharmony_ci    "c_utils:utils",
61346f34cbfSopenharmony_ci    "data_share:datashare_common",
61446f34cbfSopenharmony_ci    "data_share:datashare_consumer",
61546f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
61646f34cbfSopenharmony_ci    "hdf_core:libhdi",
61746f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
61846f34cbfSopenharmony_ci    "hilog:libhilog",
61946f34cbfSopenharmony_ci    "ipc:ipc_single",
62046f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
62146f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
62246f34cbfSopenharmony_ci    "power_manager:powermgr_client",
62346f34cbfSopenharmony_ci    "pulseaudio:pulse",
62446f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
62546f34cbfSopenharmony_ci    "samgr:samgr_proxy",
62646f34cbfSopenharmony_ci  ]
62746f34cbfSopenharmony_ci
62846f34cbfSopenharmony_ci  sources = [ "./unittest/stream_filter_router_test/src/stream_filter_router_unit_test.cpp" ]
62946f34cbfSopenharmony_ci
63046f34cbfSopenharmony_ci  deps = [
63146f34cbfSopenharmony_ci    "../../../frameworks/native/bluetoothclient:audio_bluetooth_client",
63246f34cbfSopenharmony_ci    "../../audio_policy:audio_policy_client",
63346f34cbfSopenharmony_ci    "../../audio_policy:audio_policy_service",
63446f34cbfSopenharmony_ci    "../../audio_service:audio_client",
63546f34cbfSopenharmony_ci    "../../audio_service:audio_common",
63646f34cbfSopenharmony_ci  ]
63746f34cbfSopenharmony_ci
63846f34cbfSopenharmony_ci  if (accessibility_enable == true) {
63946f34cbfSopenharmony_ci    external_deps += [
64046f34cbfSopenharmony_ci      "accessibility:accessibility_common",
64146f34cbfSopenharmony_ci      "accessibility:accessibilityconfig",
64246f34cbfSopenharmony_ci    ]
64346f34cbfSopenharmony_ci  }
64446f34cbfSopenharmony_ci
64546f34cbfSopenharmony_ci  defines = []
64646f34cbfSopenharmony_ci
64746f34cbfSopenharmony_ci  if (audio_framework_feature_dtmf_tone) {
64846f34cbfSopenharmony_ci    defines += [ "FEATURE_DTMF_TONE" ]
64946f34cbfSopenharmony_ci  }
65046f34cbfSopenharmony_ci
65146f34cbfSopenharmony_ci  if (audio_framework_feature_support_os_account) {
65246f34cbfSopenharmony_ci    defines += [ "SUPPORT_USER_ACCOUNT" ]
65346f34cbfSopenharmony_ci  }
65446f34cbfSopenharmony_ci
65546f34cbfSopenharmony_ci  if (build_variant == "user") {
65646f34cbfSopenharmony_ci    defines += [ "AUDIO_BUILD_VARIANT_USER" ]
65746f34cbfSopenharmony_ci  } else if (build_variant == "root") {
65846f34cbfSopenharmony_ci    defines += [ "AUDIO_BUILD_VARIANT_ROOT" ]
65946f34cbfSopenharmony_ci  }
66046f34cbfSopenharmony_ci
66146f34cbfSopenharmony_ci  if (appgallery_part_enable == true) {
66246f34cbfSopenharmony_ci    defines += [ "FEATURE_APPGALLERY" ]
66346f34cbfSopenharmony_ci  }
66446f34cbfSopenharmony_ci
66546f34cbfSopenharmony_ci  if (bluetooth_part_enable == true) {
66646f34cbfSopenharmony_ci    external_deps += [ "bluetooth:btframework" ]
66746f34cbfSopenharmony_ci  }
66846f34cbfSopenharmony_ci
66946f34cbfSopenharmony_ci  if (audio_framework_feature_input) {
67046f34cbfSopenharmony_ci    defines += [ "FEATURE_MULTIMODALINPUT_INPUT" ]
67146f34cbfSopenharmony_ci    external_deps += [ "input:libmmi-client" ]
67246f34cbfSopenharmony_ci  }
67346f34cbfSopenharmony_ci
67446f34cbfSopenharmony_ci  if (audio_framework_feature_device_manager) {
67546f34cbfSopenharmony_ci    defines += [ "FEATURE_DEVICE_MANAGER" ]
67646f34cbfSopenharmony_ci    external_deps += [ "device_manager:devicemanagersdk" ]
67746f34cbfSopenharmony_ci  }
67846f34cbfSopenharmony_ci
67946f34cbfSopenharmony_ci  if (audio_framework_feature_double_pnp_detect) {
68046f34cbfSopenharmony_ci    defines += [ "AUDIO_DOUBLE_PNP_DETECT" ]
68146f34cbfSopenharmony_ci  }
68246f34cbfSopenharmony_ci}
68346f34cbfSopenharmony_ci
68446f34cbfSopenharmony_ciohos_unittest("audio_affinity_parser_test") {
68546f34cbfSopenharmony_ci  module_out_path = module_output_path
68646f34cbfSopenharmony_ci  include_dirs = [
68746f34cbfSopenharmony_ci    "../server/include",
68846f34cbfSopenharmony_ci    "./unittest/audio_affinity_parser_test/include",
68946f34cbfSopenharmony_ci  ]
69046f34cbfSopenharmony_ci
69146f34cbfSopenharmony_ci  cflags = [
69246f34cbfSopenharmony_ci    "-Wall",
69346f34cbfSopenharmony_ci    "-Werror",
69446f34cbfSopenharmony_ci    "-Wno-macro-redefined",
69546f34cbfSopenharmony_ci    "-fno-access-control",
69646f34cbfSopenharmony_ci  ]
69746f34cbfSopenharmony_ci
69846f34cbfSopenharmony_ci  external_deps = [
69946f34cbfSopenharmony_ci    "ability_base:session_info",
70046f34cbfSopenharmony_ci    "ability_base:want",
70146f34cbfSopenharmony_ci    "ability_base:zuri",
70246f34cbfSopenharmony_ci    "ability_runtime:ability_connect_callback_stub",
70346f34cbfSopenharmony_ci    "ability_runtime:ability_context_native",
70446f34cbfSopenharmony_ci    "ability_runtime:ability_manager",
70546f34cbfSopenharmony_ci    "ability_runtime:app_context",
70646f34cbfSopenharmony_ci    "ability_runtime:dataobs_manager",
70746f34cbfSopenharmony_ci    "ability_runtime:extension_manager",
70846f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
70946f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
71046f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
71146f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
71246f34cbfSopenharmony_ci    "bounds_checking_function:libsec_shared",
71346f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
71446f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
71546f34cbfSopenharmony_ci    "c_utils:utils",
71646f34cbfSopenharmony_ci    "data_share:datashare_common",
71746f34cbfSopenharmony_ci    "data_share:datashare_consumer",
71846f34cbfSopenharmony_ci    "drivers_interface_audio:libaudio_proxy_4.0",
71946f34cbfSopenharmony_ci    "eventhandler:libeventhandler",
72046f34cbfSopenharmony_ci    "hdf_core:libhdf_host",
72146f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
72246f34cbfSopenharmony_ci    "hdf_core:libhdf_utils",
72346f34cbfSopenharmony_ci    "hdf_core:libhdi",
72446f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
72546f34cbfSopenharmony_ci    "hilog:libhilog",
72646f34cbfSopenharmony_ci    "hisysevent:libhisysevent",
72746f34cbfSopenharmony_ci    "init:libbegetutil",
72846f34cbfSopenharmony_ci    "ipc:ipc_single",
72946f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
73046f34cbfSopenharmony_ci    "media_foundation:media_monitor_client",
73146f34cbfSopenharmony_ci    "media_foundation:media_monitor_common",
73246f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
73346f34cbfSopenharmony_ci    "power_manager:power_setting",
73446f34cbfSopenharmony_ci    "power_manager:powermgr_client",
73546f34cbfSopenharmony_ci    "pulseaudio:pulse",
73646f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
73746f34cbfSopenharmony_ci    "samgr:samgr_proxy",
73846f34cbfSopenharmony_ci  ]
73946f34cbfSopenharmony_ci
74046f34cbfSopenharmony_ci  sources = [
74146f34cbfSopenharmony_ci    "./unittest/audio_affinity_parser_test/src/audio_affinity_parser_test.cpp",
74246f34cbfSopenharmony_ci  ]
74346f34cbfSopenharmony_ci
74446f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_service" ]
74546f34cbfSopenharmony_ci}
74646f34cbfSopenharmony_ci
74746f34cbfSopenharmony_ciohos_unittest("audio_session_timer_test") {
74846f34cbfSopenharmony_ci  module_out_path = module_output_path
74946f34cbfSopenharmony_ci  include_dirs = [
75046f34cbfSopenharmony_ci    "../server/include",
75146f34cbfSopenharmony_ci    "./unittest/audio_session_timer_test/include",
75246f34cbfSopenharmony_ci  ]
75346f34cbfSopenharmony_ci
75446f34cbfSopenharmony_ci  cflags = [
75546f34cbfSopenharmony_ci    "-Wall",
75646f34cbfSopenharmony_ci    "-Werror",
75746f34cbfSopenharmony_ci    "-Wno-macro-redefined",
75846f34cbfSopenharmony_ci    "-fno-access-control",
75946f34cbfSopenharmony_ci  ]
76046f34cbfSopenharmony_ci
76146f34cbfSopenharmony_ci  external_deps = [
76246f34cbfSopenharmony_ci    "ability_base:session_info",
76346f34cbfSopenharmony_ci    "ability_base:want",
76446f34cbfSopenharmony_ci    "ability_base:zuri",
76546f34cbfSopenharmony_ci    "ability_runtime:ability_connect_callback_stub",
76646f34cbfSopenharmony_ci    "ability_runtime:ability_context_native",
76746f34cbfSopenharmony_ci    "ability_runtime:ability_manager",
76846f34cbfSopenharmony_ci    "ability_runtime:app_context",
76946f34cbfSopenharmony_ci    "ability_runtime:dataobs_manager",
77046f34cbfSopenharmony_ci    "ability_runtime:extension_manager",
77146f34cbfSopenharmony_ci    "access_token:libaccesstoken_sdk",
77246f34cbfSopenharmony_ci    "access_token:libprivacy_sdk",
77346f34cbfSopenharmony_ci    "access_token:libtokenid_sdk",
77446f34cbfSopenharmony_ci    "access_token:libtokensetproc_shared",
77546f34cbfSopenharmony_ci    "bounds_checking_function:libsec_shared",
77646f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_base",
77746f34cbfSopenharmony_ci    "bundle_framework:appexecfwk_core",
77846f34cbfSopenharmony_ci    "c_utils:utils",
77946f34cbfSopenharmony_ci    "data_share:datashare_common",
78046f34cbfSopenharmony_ci    "data_share:datashare_consumer",
78146f34cbfSopenharmony_ci    "drivers_interface_audio:libaudio_proxy_4.0",
78246f34cbfSopenharmony_ci    "eventhandler:libeventhandler",
78346f34cbfSopenharmony_ci    "googletest:gtest",
78446f34cbfSopenharmony_ci    "hdf_core:libhdf_host",
78546f34cbfSopenharmony_ci    "hdf_core:libhdf_ipc_adapter",
78646f34cbfSopenharmony_ci    "hdf_core:libhdf_utils",
78746f34cbfSopenharmony_ci    "hdf_core:libhdi",
78846f34cbfSopenharmony_ci    "hdf_core:libpub_utils",
78946f34cbfSopenharmony_ci    "hilog:libhilog",
79046f34cbfSopenharmony_ci    "hisysevent:libhisysevent",
79146f34cbfSopenharmony_ci    "init:libbegetutil",
79246f34cbfSopenharmony_ci    "ipc:ipc_single",
79346f34cbfSopenharmony_ci    "kv_store:distributeddata_inner",
79446f34cbfSopenharmony_ci    "media_foundation:media_monitor_client",
79546f34cbfSopenharmony_ci    "media_foundation:media_monitor_common",
79646f34cbfSopenharmony_ci    "os_account:os_account_innerkits",
79746f34cbfSopenharmony_ci    "power_manager:power_setting",
79846f34cbfSopenharmony_ci    "power_manager:powermgr_client",
79946f34cbfSopenharmony_ci    "pulseaudio:pulse",
80046f34cbfSopenharmony_ci    "safwk:system_ability_fwk",
80146f34cbfSopenharmony_ci    "samgr:samgr_proxy",
80246f34cbfSopenharmony_ci  ]
80346f34cbfSopenharmony_ci
80446f34cbfSopenharmony_ci  sources =
80546f34cbfSopenharmony_ci      [ "./unittest/audio_session_timer_test/src/audio_session_timer_test.cpp" ]
80646f34cbfSopenharmony_ci
80746f34cbfSopenharmony_ci  deps = [ "../../audio_policy:audio_policy_service" ]
80846f34cbfSopenharmony_ci}
809