diff --git a/test/fuzztest/authenticators/account_related/auth/isoauthtask_fuzzer/BUILD.gn b/test/fuzztest/authenticators/account_related/auth/isoauthtask_fuzzer/BUILD.gn index 98a0a251011f603223849d4689b5ef146d2d9b47..f0a5ef53c51a3297d7668700367795e22f9c7649 100644 --- a/test/fuzztest/authenticators/account_related/auth/isoauthtask_fuzzer/BUILD.gn +++ b/test/fuzztest/authenticators/account_related/auth/isoauthtask_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2023 Huawei Device Co., Ltd. +# Copyright (c) 2023-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -82,11 +82,15 @@ ohos_fuzztest("IsoAuthTaskFuzzTest") { "access_token:libaccesstoken_sdk", "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } + if (support_os_account) { external_deps += [ "ability_base:want", diff --git a/test/fuzztest/authenticators/account_unrelated/pake/standardexchangetask_fuzzer/BUILD.gn b/test/fuzztest/authenticators/account_unrelated/pake/standardexchangetask_fuzzer/BUILD.gn index 945eda6b392b3a51851f649a8eb4a1ec4f9d94ff..5ab8f82538eb2c300f8283051c2ba6f573d20664 100644 --- a/test/fuzztest/authenticators/account_unrelated/pake/standardexchangetask_fuzzer/BUILD.gn +++ b/test/fuzztest/authenticators/account_unrelated/pake/standardexchangetask_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2023 Huawei Device Co., Ltd. +# Copyright (c) 2023-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -76,7 +76,6 @@ ohos_fuzztest("StandardExchangeTaskFuzzTest") { "access_token:libtoken_setproc", "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", @@ -84,6 +83,11 @@ ohos_fuzztest("StandardExchangeTaskFuzzTest") { "ipc:ipc_core", "samgr:samgr_proxy", ] + + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } + if (support_os_account) { external_deps += [ "ability_base:want", diff --git a/test/fuzztest/creds_manager/credsmanager_fuzzer/BUILD.gn b/test/fuzztest/creds_manager/credsmanager_fuzzer/BUILD.gn index a6472ab4e8f9c8c1381ea9f05ded1fb49dfb08e9..2b10c11f1d6a560d6664ebb944d5938c5b9975c1 100644 --- a/test/fuzztest/creds_manager/credsmanager_fuzzer/BUILD.gn +++ b/test/fuzztest/creds_manager/credsmanager_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2023 Huawei Device Co., Ltd. +# Copyright (c) 2023-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -54,8 +54,11 @@ ohos_fuzztest("CredsManagerFuzzTest") { sources += account_auth_plugin_mock_files sources += account_task_manager_mock_files } - sources -= soft_bus_channel_files - sources += soft_bus_channel_mock_files + + if (device_auth_enable_soft_bus_channel) { + sources -= soft_bus_channel_files + sources += soft_bus_channel_mock_files + } sources += identity_manager_files sources += [ "${key_management_adapter_path}/impl/src/common/mbedtls_ec_adapter.c", @@ -88,7 +91,6 @@ ohos_fuzztest("CredsManagerFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", @@ -96,6 +98,10 @@ ohos_fuzztest("CredsManagerFuzzTest") { "mbedtls:mbedtls_shared", "openssl:libcrypto_static", ] + + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/devauth_fuzzer/BUILD.gn b/test/fuzztest/devauth_fuzzer/BUILD.gn index 06bda0074f17c951117c2a16c67737eb8deb7a90..06d26f047890052edd6377db9a244ebaffd907bb 100644 --- a/test/fuzztest/devauth_fuzzer/BUILD.gn +++ b/test/fuzztest/devauth_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2023 Huawei Device Co., Ltd. +# Copyright (c) 2023-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -89,7 +89,6 @@ ohos_fuzztest("DevAuthFuzzTest") { "selinux_adapter:librestorecon", "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", @@ -97,6 +96,11 @@ ohos_fuzztest("DevAuthFuzzTest") { "ipc:ipc_core", "samgr:samgr_proxy", ] + + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } + if (support_os_account) { external_deps += [ "ability_base:want", diff --git a/test/fuzztest/devauthinterface_fuzzer/BUILD.gn b/test/fuzztest/devauthinterface_fuzzer/BUILD.gn index 9a89d59184617aa61dda39f49ff285a96d8ee4f0..258d2ae36573726d287934fca247a6f087a20d5a 100644 --- a/test/fuzztest/devauthinterface_fuzzer/BUILD.gn +++ b/test/fuzztest/devauthinterface_fuzzer/BUILD.gn @@ -142,7 +142,6 @@ ohos_fuzztest("DevAuthInterfaceFuzzTest") { "bounds_checking_function:libsec_shared", "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", @@ -155,6 +154,9 @@ ohos_fuzztest("DevAuthInterfaceFuzzTest") { "common_event_service:cesfwk_innerkits", "safwk:system_ability_fwk", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservaddmembertogroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservaddmembertogroup_fuzzer/BUILD.gn index c4edc3ef65aa238ca41c3ed5007e0c316fbef690..d55fec45f6ef9297d4b4b63652d9e8338cc0b525 100644 --- a/test/fuzztest/device_auth_service/devauthservaddmembertogroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservaddmembertogroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -58,11 +58,13 @@ ohos_fuzztest("DevAuthServAddMemberToGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservaddmultimemberstogroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservaddmultimemberstogroup_fuzzer/BUILD.gn index 84ac5491812866c94d4c4cea52ff44c91293890f..510291fdd37da05c2ab90185bfa186cf96649802 100644 --- a/test/fuzztest/device_auth_service/devauthservaddmultimemberstogroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservaddmultimemberstogroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,14 @@ ohos_fuzztest("DevAuthServAddMultiMembersToGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservauthdevice_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservauthdevice_fuzzer/BUILD.gn index 46a46db3179cdae2a17dc2aaa00d8d9a8c29d4a6..e3c92bd1d78f9b08fa08778a53d52e3fc9716f72 100644 --- a/test/fuzztest/device_auth_service/devauthservauthdevice_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservauthdevice_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServAuthDeviceFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservcancelauthrequest_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservcancelauthrequest_fuzzer/BUILD.gn index 7c7a4f7d43e67ae7bf55bc82d774d5db767a4d4e..237ac2faa6366e2df82668894df6d540c48eda0f 100644 --- a/test/fuzztest/device_auth_service/devauthservcancelauthrequest_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservcancelauthrequest_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServCancelAuthRequestFuzzTest") { external_deps = [ "cJSON:cjson_static", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservcancelbindrequest_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservcancelbindrequest_fuzzer/BUILD.gn index a261c5b8e7b3742791f1abafb9c8f66e2f045363..60c4f9a0677729520c5a08112a8200f7f7b6bc5a 100644 --- a/test/fuzztest/device_auth_service/devauthservcancelbindrequest_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservcancelbindrequest_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServCancelBindRequestFuzzTest") { external_deps = [ "cJSON:cjson_static", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservcheckaccesstogroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservcheckaccesstogroup_fuzzer/BUILD.gn index cffa2799031c53abf5c677a34a112cac7bcf761d..0c4c481d8124588fff933d9313f10a4bbc7b7b37 100644 --- a/test/fuzztest/device_auth_service/devauthservcheckaccesstogroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservcheckaccesstogroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServCheckAccessToGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservcreategroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservcreategroup_fuzzer/BUILD.gn index 8797b792ab008736c8adfd3b861d6a30204feb90..85309d933093f2673721e46bfcafcdd931b38ddb 100644 --- a/test/fuzztest/device_auth_service/devauthservcreategroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservcreategroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServCreateGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservdeletegroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservdeletegroup_fuzzer/BUILD.gn index 26a44da9437a9427ff0830ca7e8c65e9f1045db6..5b3561fb63e2621a852354369c35b6c4d4d0b081 100644 --- a/test/fuzztest/device_auth_service/devauthservdeletegroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservdeletegroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServDeleteGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservdeletememberfromgroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservdeletememberfromgroup_fuzzer/BUILD.gn index 6dc7d86ccd3b6543330478bdca37ccc71a02d1c7..34375003880b047fc9d15d4da17209e5f917eea6 100644 --- a/test/fuzztest/device_auth_service/devauthservdeletememberfromgroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservdeletememberfromgroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServDeleteMemberFromGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservdeletemultimembersfromgroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservdeletemultimembersfromgroup_fuzzer/BUILD.gn index 87bfd47b9842f6dc642f1d22915f68f613339611..82caa984c8a5b9f30390ca6be12a2f41dc548bff 100644 --- a/test/fuzztest/device_auth_service/devauthservdeletemultimembersfromgroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservdeletemultimembersfromgroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServDeleteMultiMembersFromGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgetdeviceinfobyid_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgetdeviceinfobyid_fuzzer/BUILD.gn index 808db63358357dca3c9df358a781de41473fbeb6..62312906195f4b98f258b8b56414cd425014170d 100644 --- a/test/fuzztest/device_auth_service/devauthservgetdeviceinfobyid_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgetdeviceinfobyid_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetDeviceInfoByIdFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgetgroupinfo_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgetgroupinfo_fuzzer/BUILD.gn index 9bb23bd3c7c87511172b14b9c15224c0d19c0c10..d0a41e2d1ba03fb3abd2fa1f8f89b7f31b0d3e2f 100644 --- a/test/fuzztest/device_auth_service/devauthservgetgroupinfo_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgetgroupinfo_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetGroupInfoFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgetgroupinfobyid_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgetgroupinfobyid_fuzzer/BUILD.gn index 442e0a30d32d9bf4ef04a171dc194ac6a689c595..7b4123139173bdcf0b7dbdf02947872e8af4ca06 100644 --- a/test/fuzztest/device_auth_service/devauthservgetgroupinfobyid_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgetgroupinfobyid_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetGroupInfoByIdFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgetjoinedgroups_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgetjoinedgroups_fuzzer/BUILD.gn index 2c1122ba81b81b0611090ea4295496aa1992ae36..4fdc2d79d2578d7ca525aec7674e2452582438de 100644 --- a/test/fuzztest/device_auth_service/devauthservgetjoinedgroups_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgetjoinedgroups_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetJoinedGroupsFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgetpkinfolist_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgetpkinfolist_fuzzer/BUILD.gn index 5b5cebf144ca18c62777a8d01bfbfae3c7c7d730..2b70605827107b13eb0561b56a1624a76584ef8d 100644 --- a/test/fuzztest/device_auth_service/devauthservgetpkinfolist_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgetpkinfolist_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetPkInfoListFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgetregisterinfo_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgetregisterinfo_fuzzer/BUILD.gn index 0710cc3695e1108021a560288b4cd71a605c47a4..0fc8da83ae3b423023571412e95d5a901dc182fb 100644 --- a/test/fuzztest/device_auth_service/devauthservgetregisterinfo_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgetregisterinfo_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetRegisterInfoFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgetrelatedgroups_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgetrelatedgroups_fuzzer/BUILD.gn index 6a4735cd8aa17926cc478a3026ec50888a93f28b..fa1785ecf8df2304ed4eb80244dd3606f0baf7e9 100644 --- a/test/fuzztest/device_auth_service/devauthservgetrelatedgroups_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgetrelatedgroups_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetRelatedGroupsFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservgettrusteddevices_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservgettrusteddevices_fuzzer/BUILD.gn index ad7908b3035f07f44382c6430f3f771b8b6d33ae..5ea8e4f6e9dee6f42cd1f9f7718ce6cd5e7f73e7 100644 --- a/test/fuzztest/device_auth_service/devauthservgettrusteddevices_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservgettrusteddevices_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServGetTrustedDevicesFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservisdeviceingroup_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservisdeviceingroup_fuzzer/BUILD.gn index 764273f3e690e23148574f1c827c2898345b85b1..4b3d9f33915aa47f5de8b19d7d9a4b1665e557e5 100644 --- a/test/fuzztest/device_auth_service/devauthservisdeviceingroup_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservisdeviceingroup_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServIsDeviceInGroupFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservprocessauthdata_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservprocessauthdata_fuzzer/BUILD.gn index bccab43bcec3be8a243def32734596575fbddf3f..0b6ee1d31f1c403384999697aafb7d4ac7974a29 100644 --- a/test/fuzztest/device_auth_service/devauthservprocessauthdata_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservprocessauthdata_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServProcessAuthDataFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservprocessbinddata_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservprocessbinddata_fuzzer/BUILD.gn index c8aaf8ed8e63865eb2a7e8b959c92809074648b7..5dca6c8d4bc17a665dd834c74c5d32d8dc0c4999 100644 --- a/test/fuzztest/device_auth_service/devauthservprocessbinddata_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservprocessbinddata_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServProcessBindDataFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservregcallback_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservregcallback_fuzzer/BUILD.gn index 5dd805deeaa15783ef6a150aea29fb6208dd5247..98fe2ec1002d3bb90cb756260a9427689b4e61b7 100644 --- a/test/fuzztest/device_auth_service/devauthservregcallback_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservregcallback_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServRegCallbackFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservregdatachangelistener_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservregdatachangelistener_fuzzer/BUILD.gn index 6591748a74b4c91f64940da94e10b4ba2f4f87ff..0d45c0b1bbdb6e0e0908e877862c9777015c50eb 100644 --- a/test/fuzztest/device_auth_service/devauthservregdatachangelistener_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservregdatachangelistener_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -60,11 +60,13 @@ ohos_fuzztest("DevAuthServRegDataChangeListenerFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservunregcallback_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservunregcallback_fuzzer/BUILD.gn index 1887f0d14c90e53848fb3446c984cd1468ad029e..4dd580fb2840e6884a218499ea59fa6ab487b563 100644 --- a/test/fuzztest/device_auth_service/devauthservunregcallback_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservunregcallback_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServUnregCallbackFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/device_auth_service/devauthservunregdatachangelistener_fuzzer/BUILD.gn b/test/fuzztest/device_auth_service/devauthservunregdatachangelistener_fuzzer/BUILD.gn index 36a810c0e2d6ad0c1720d3c3d4e9770e6043b784..1b41b9ef8ed08d9aa8235bfd6198cb3317da3bd1 100644 --- a/test/fuzztest/device_auth_service/devauthservunregdatachangelistener_fuzzer/BUILD.gn +++ b/test/fuzztest/device_auth_service/devauthservunregdatachangelistener_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2022-2023 Huawei Device Co., Ltd. +# Copyright (c) 2022-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -59,11 +59,13 @@ ohos_fuzztest("DevAuthServUnregDataChangeListenerFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ############################################################################### diff --git a/test/fuzztest/group_manage/groupoperationcommon_fuzzer/BUILD.gn b/test/fuzztest/group_manage/groupoperationcommon_fuzzer/BUILD.gn index 1481d41fb2c87ac5e79401ae8016194e68ad9d1b..81880a6ac7a44fd351854dddb378f9b87052cbca 100644 --- a/test/fuzztest/group_manage/groupoperationcommon_fuzzer/BUILD.gn +++ b/test/fuzztest/group_manage/groupoperationcommon_fuzzer/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2023 Huawei Device Co., Ltd. +# Copyright (c) 2023-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -47,8 +47,10 @@ ohos_fuzztest("GroupOperationCommonFuzzTest") { sources += hal_common_files sources += hiview_adapter_files sources += identity_manager_files - sources -= soft_bus_channel_files - sources += soft_bus_channel_mock_files + if (device_auth_enable_soft_bus_channel) { + sources -= soft_bus_channel_files + sources += soft_bus_channel_mock_files + } if (support_os_account) { sources += account_subscriber_files sources += sa_subscriber_files @@ -83,7 +85,6 @@ ohos_fuzztest("GroupOperationCommonFuzzTest") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", @@ -91,6 +92,11 @@ ohos_fuzztest("GroupOperationCommonFuzzTest") { "mbedtls:mbedtls_shared", "openssl:libcrypto_static", ] + + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } + if (support_os_account) { external_deps += [ "ability_base:want", diff --git a/test/unittest/deviceauth/BUILD.gn b/test/unittest/deviceauth/BUILD.gn index 49b6a4b38e640d79cb51923af1469ff16ee04020..2ac899a342df828d35c00e5aa4c479faa27f2018 100644 --- a/test/unittest/deviceauth/BUILD.gn +++ b/test/unittest/deviceauth/BUILD.gn @@ -534,7 +534,6 @@ ohos_unittest("device_auth_interface_test") { "bounds_checking_function:libsec_shared", "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "googletest:gmock_main", "googletest:gtest_main", "hilog:libhilog", @@ -549,6 +548,9 @@ ohos_unittest("device_auth_interface_test") { "common_event_service:cesfwk_innerkits", "safwk:system_ability_fwk", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ohos_unittest("deviceauth_unit_test") { @@ -818,7 +820,6 @@ ohos_unittest("light_auth_test") { "bounds_checking_function:libsec_shared", "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "googletest:gmock_main", "googletest:gtest_main", "hilog:libhilog", @@ -840,6 +841,9 @@ ohos_unittest("light_auth_test") { "googletest:gtest_main", "hilog:libhilog", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } ohos_unittest("identity_service_ipc_test") { diff --git a/test/unittest/tdd_framework/unit_test/services/creds_manager/BUILD.gn b/test/unittest/tdd_framework/unit_test/services/creds_manager/BUILD.gn index 6907bdb4830040b58844a0317b0ce14b013078b2..a7f145302c99745d4ccc118e2a4ae3d62509395d 100644 --- a/test/unittest/tdd_framework/unit_test/services/creds_manager/BUILD.gn +++ b/test/unittest/tdd_framework/unit_test/services/creds_manager/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (C) 2023 Huawei Device Co., Ltd. +# Copyright (C) 2023-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -81,7 +81,6 @@ ohos_unittest("creds_manager_test") { external_deps = [ "cJSON:cjson", "c_utils:utils", - "dsoftbus:softbus_client", "googletest:gmock_main", "googletest:gtest_main", "hilog:libhilog", @@ -91,4 +90,7 @@ ohos_unittest("creds_manager_test") { "mbedtls:mbedtls_shared", "openssl:libcrypto_static", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } diff --git a/test/unittest/tdd_framework/unit_test/services/frameworks/os_account_adapter/BUILD.gn b/test/unittest/tdd_framework/unit_test/services/frameworks/os_account_adapter/BUILD.gn index 0e9db739dcaab03b4833504499737c8ab6debc0f..f988bcd568f1003299295e177f77d3234ead53b5 100644 --- a/test/unittest/tdd_framework/unit_test/services/frameworks/os_account_adapter/BUILD.gn +++ b/test/unittest/tdd_framework/unit_test/services/frameworks/os_account_adapter/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (C) 2023 Huawei Device Co., Ltd. +# Copyright (C) 2023-2025 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at @@ -96,7 +96,6 @@ if (support_os_account) { "cJSON:cjson", "c_utils:utils", "common_event_service:cesfwk_innerkits", - "dsoftbus:softbus_client", "googletest:gmock_main", "googletest:gtest_main", "hilog:libhilog", @@ -111,6 +110,9 @@ if (support_os_account) { "os_account:os_account_innerkits", "samgr:samgr_proxy", ] + if (device_auth_enable_soft_bus_channel) { + external_deps += [ "dsoftbus:softbus_client" ] + } } }