1# Copyright (c) 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 14#####################hydra-fuzz################### 15import("//build/test.gni") 16import("//foundation/ability/ability_runtime/ability_runtime.gni") 17##############################fuzztest########################################## 18module_output_path = "ability_runtime/appmgrservice" 19ohos_fuzztest("AbilityProcessOptionsFuzzTest") { 20 module_out_path = module_output_path 21 22 fuzz_config_file = 23 "${ability_runtime_test_path}/fuzztest/abilityprocessoptions_fuzzer" 24 25 include_dirs = [ 26 "${ability_runtime_services_path}/appmgr/include", 27 "${ability_runtime_innerkits_path}/ability_manager/include", 28 "${ability_runtime_innerkits_path}/app_manager/include/appmgr", 29 "${ability_runtime_path}/interfaces/kits/native/appkit/ability_bundle_manager_helper", 30 "${ability_runtime_services_path}/abilitymgr/include/utils", 31 "${ability_runtime_services_path}/abilitymgr/include/keep_alive", 32 "${ability_runtime_services_path}/common/include", 33 ] 34 35 cflags = [ 36 "-g", 37 "-O0", 38 "-Wno-unused-variable", 39 "-fno-omit-frame-pointer", 40 ] 41 sources = [ 42 "${ability_runtime_services_path}/abilitymgr/src/process_options.cpp", 43 "abilityprocessoptions_fuzzer.cpp", 44 ] 45 46 configs = [ "${ability_runtime_innerkits_path}/ability_manager:ability_manager_public_config" ] 47 48 deps = [ "${ability_runtime_innerkits_path}/ability_manager:process_options" ] 49 50 external_deps = [ 51 "ability_base:want", 52 "ability_base:zuri", 53 "bundle_framework:appexecfwk_base", 54 "bundle_framework:appexecfwk_core", 55 "c_utils:utils", 56 "common_event_service:cesfwk_innerkits", 57 "ffrt:libffrt", 58 "hilog:libhilog", 59 "ipc:ipc_core", 60 "napi:ace_napi", 61 "safwk:system_ability_fwk", 62 "samgr:samgr_proxy", 63 ] 64} 65 66############################################################################### 67group("fuzztest") { 68 testonly = true 69 deps = [] 70 deps += [ 71 # deps file 72 ":AbilityProcessOptionsFuzzTest", 73 ] 74} 75############################################################################### 76