1bc03f14fSopenharmony_ci# Copyright (c) 2024 Huawei Device Co., Ltd. 2bc03f14fSopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License"); 3bc03f14fSopenharmony_ci# you may not use this file except in compliance with the License. 4bc03f14fSopenharmony_ci# You may obtain a copy of the License at 5bc03f14fSopenharmony_ci# 6bc03f14fSopenharmony_ci# http://www.apache.org/licenses/LICENSE-2.0 7bc03f14fSopenharmony_ci# 8bc03f14fSopenharmony_ci# Unless required by applicable law or agreed to in writing, software 9bc03f14fSopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS, 10bc03f14fSopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11bc03f14fSopenharmony_ci# See the License for the specific language governing permissions and 12bc03f14fSopenharmony_ci# limitations under the License. 13bc03f14fSopenharmony_ci 14bc03f14fSopenharmony_ciimport("//foundation/distributeddatamgr/pasteboard/pasteboard.gni") 15bc03f14fSopenharmony_ci 16bc03f14fSopenharmony_ci#####################hydra-fuzz################### 17bc03f14fSopenharmony_ciimport("//build/config/features.gni") 18bc03f14fSopenharmony_ciimport("//build/ohos.gni") 19bc03f14fSopenharmony_ciimport("//build/test.gni") 20bc03f14fSopenharmony_ci 21bc03f14fSopenharmony_ci##############################fuzztest########################################## 22bc03f14fSopenharmony_ciohos_fuzztest("PasteboardObserverFuzzTest") { 23bc03f14fSopenharmony_ci module_out_path = "pasteboard/pasteboard" 24bc03f14fSopenharmony_ci 25bc03f14fSopenharmony_ci fuzz_config_file = 26bc03f14fSopenharmony_ci "${pasteboard_root_path}/test/fuzztest/pasteboardobserver_fuzzer" 27bc03f14fSopenharmony_ci 28bc03f14fSopenharmony_ci configs = [ "${pasteboard_service_path}:pasteboard_service_config" ] 29bc03f14fSopenharmony_ci 30bc03f14fSopenharmony_ci include_dirs = [ 31bc03f14fSopenharmony_ci "${pasteboard_service_path}/zidl/include", 32bc03f14fSopenharmony_ci "${pasteboard_service_path}/core/include", 33bc03f14fSopenharmony_ci ] 34bc03f14fSopenharmony_ci 35bc03f14fSopenharmony_ci cflags = [ 36bc03f14fSopenharmony_ci "-g", 37bc03f14fSopenharmony_ci "-O0", 38bc03f14fSopenharmony_ci "-Wno-unused-variable", 39bc03f14fSopenharmony_ci "-fno-omit-frame-pointer", 40bc03f14fSopenharmony_ci ] 41bc03f14fSopenharmony_ci 42bc03f14fSopenharmony_ci sources = [ "pasteboardobserver_fuzzer.cpp" ] 43bc03f14fSopenharmony_ci 44bc03f14fSopenharmony_ci deps = [ 45bc03f14fSopenharmony_ci "${pasteboard_framework_path}:pasteboard_framework", 46bc03f14fSopenharmony_ci "${pasteboard_innerkits_path}:pasteboard_client", 47bc03f14fSopenharmony_ci "${pasteboard_service_path}:pasteboard_service", 48bc03f14fSopenharmony_ci ] 49bc03f14fSopenharmony_ci 50bc03f14fSopenharmony_ci external_deps = [ 51bc03f14fSopenharmony_ci "ability_base:want", 52bc03f14fSopenharmony_ci "ability_base:zuri", 53bc03f14fSopenharmony_ci "access_token:libaccesstoken_sdk", 54bc03f14fSopenharmony_ci "access_token:libprivacy_sdk", 55bc03f14fSopenharmony_ci "app_file_service:remote_file_share_native", 56bc03f14fSopenharmony_ci "bundle_framework:appexecfwk_core", 57bc03f14fSopenharmony_ci "c_utils:utils", 58bc03f14fSopenharmony_ci "data_share:datashare_consumer", 59bc03f14fSopenharmony_ci "dataclassification:data_transit_mgr", 60bc03f14fSopenharmony_ci "eventhandler:libeventhandler", 61bc03f14fSopenharmony_ci "ffrt:libffrt", 62bc03f14fSopenharmony_ci "hilog:libhilog", 63bc03f14fSopenharmony_ci "image_framework:image_native", 64bc03f14fSopenharmony_ci "input:libmmi-client", 65bc03f14fSopenharmony_ci "ipc:ipc_core", 66bc03f14fSopenharmony_ci "os_account:os_account_innerkits", 67bc03f14fSopenharmony_ci "safwk:system_ability_fwk", 68bc03f14fSopenharmony_ci "udmf:udmf_client", 69bc03f14fSopenharmony_ci ] 70bc03f14fSopenharmony_ci} 71bc03f14fSopenharmony_ci 72bc03f14fSopenharmony_ci############################################################################### 73bc03f14fSopenharmony_cigroup("fuzztest") { 74bc03f14fSopenharmony_ci testonly = true 75bc03f14fSopenharmony_ci deps = [] 76bc03f14fSopenharmony_ci deps += [ 77bc03f14fSopenharmony_ci # deps file 78bc03f14fSopenharmony_ci ":PasteboardObserverFuzzTest", 79bc03f14fSopenharmony_ci ] 80bc03f14fSopenharmony_ci} 81bc03f14fSopenharmony_ci############################################################################### 82