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 14import("//foundation/distributeddatamgr/pasteboard/pasteboard.gni") 15 16#####################hydra-fuzz################### 17import("//build/config/features.gni") 18import("//build/ohos.gni") 19import("//build/test.gni") 20 21##############################fuzztest########################################## 22ohos_fuzztest("PasteboardObserverFuzzTest") { 23 module_out_path = "pasteboard/pasteboard" 24 25 fuzz_config_file = 26 "${pasteboard_root_path}/test/fuzztest/pasteboardobserver_fuzzer" 27 28 configs = [ "${pasteboard_service_path}:pasteboard_service_config" ] 29 30 include_dirs = [ 31 "${pasteboard_service_path}/zidl/include", 32 "${pasteboard_service_path}/core/include", 33 ] 34 35 cflags = [ 36 "-g", 37 "-O0", 38 "-Wno-unused-variable", 39 "-fno-omit-frame-pointer", 40 ] 41 42 sources = [ "pasteboardobserver_fuzzer.cpp" ] 43 44 deps = [ 45 "${pasteboard_framework_path}:pasteboard_framework", 46 "${pasteboard_innerkits_path}:pasteboard_client", 47 "${pasteboard_service_path}:pasteboard_service", 48 ] 49 50 external_deps = [ 51 "ability_base:want", 52 "ability_base:zuri", 53 "access_token:libaccesstoken_sdk", 54 "access_token:libprivacy_sdk", 55 "app_file_service:remote_file_share_native", 56 "bundle_framework:appexecfwk_core", 57 "c_utils:utils", 58 "data_share:datashare_consumer", 59 "dataclassification:data_transit_mgr", 60 "eventhandler:libeventhandler", 61 "ffrt:libffrt", 62 "hilog:libhilog", 63 "image_framework:image_native", 64 "input:libmmi-client", 65 "ipc:ipc_core", 66 "os_account:os_account_innerkits", 67 "safwk:system_ability_fwk", 68 "udmf:udmf_client", 69 ] 70} 71 72############################################################################### 73group("fuzztest") { 74 testonly = true 75 deps = [] 76 deps += [ 77 # deps file 78 ":PasteboardObserverFuzzTest", 79 ] 80} 81############################################################################### 82