1# Copyright (c) 2024 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/ohos.gni") 16import("//build/test.gni") 17import("//foundation/ability/ability_runtime/ability_runtime.gni") 18##############################fuzztest########################################## 19module_output_path = "ability_runtime/appmgrservice" 20ohos_fuzztest("AbilityAppFreezeManagerFuzzTest") { 21 module_out_path = module_output_path 22 fuzz_config_file = 23 "${ability_runtime_test_path}/fuzztest/abilityappfreezemanager_fuzzer" 24 include_dirs = [ 25 "${ability_runtime_services_path}/appmgr/include", 26 "${ability_runtime_services_path}/abilitymgr/include/utils", 27 "${ability_runtime_services_path}/abilitymgr/include", 28 "${ability_runtime_services_path}/appdfr/include", 29 "${ability_runtime_path}/utils/global/freeze/include", 30 ] 31 32 cflags = [ 33 "-g", 34 "-O0", 35 "-Wno-unused-variable", 36 "-fno-omit-frame-pointer", 37 ] 38 sources = [ "abilityappfreezemanager_fuzzer.cpp" ] 39 40 deps = [ 41 "${ability_runtime_innerkits_path}/app_manager:app_manager", 42 "${ability_runtime_path}/utils/global/freeze:freeze_util", 43 "${ability_runtime_services_path}/appmgr:libappms", 44 "${ability_runtime_services_path}/common:task_handler_wrap", 45 ] 46 47 external_deps = [ 48 "ability_base:configuration", 49 "ability_base:want", 50 "appspawn:appspawn_client", 51 "bundle_framework:appexecfwk_base", 52 "bundle_framework:appexecfwk_core", 53 "c_utils:utils", 54 "faultloggerd:libdfx_dumpcatcher", 55 "faultloggerd:libfaultloggerd", 56 "ffrt:libffrt", 57 "hilog:libhilog", 58 "hisysevent:libhisysevent", 59 "hitrace:hitrace_meter", 60 "init:libbegetutil", 61 "init:libbegetutil", 62 "ipc:ipc_core", 63 "jsoncpp:jsoncpp", 64 "samgr:samgr_proxy", 65 "window_manager:libwm", 66 ] 67} 68 69############################################################################### 70group("fuzztest") { 71 testonly = true 72 deps = [] 73 deps += [ 74 # deps file 75 ":AbilityAppFreezeManagerFuzzTest", 76 ] 77} 78############################################################################### 79