1# Copyright (c) 2022 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/config/features.gni") 16import("//build/ohos.gni") 17import("//build/test.gni") 18SMS_MMS_SOURCE_DIR = "../../../" 19 20##############################fuzztest########################################## 21ohos_fuzztest("GetSmsSegmentsInfoFuzzTest") { 22 module_output_path = "sms_mms/sms_mms" 23 module_out_path = module_output_path 24 fuzz_config_file = 25 "$SMS_MMS_SOURCE_DIR/test/fuzztest/getsmssegmentsinfo_fuzzer" 26 27 include_dirs = [ 28 "$SMS_MMS_SOURCE_DIR/frameworks/js/napi/include", 29 "$SMS_MMS_SOURCE_DIR/services/include", 30 "$SMS_MMS_SOURCE_DIR/test/fuzztest/common_fuzzer", 31 "$SMS_MMS_SOURCE_DIR/interfaces/innerkits/", 32 "$SMS_MMS_SOURCE_DIR/interfaces/innerkits/ims", 33 "//third_party/libphonenumber/cpp/src", 34 "//third_party/libphonenumber/cpp/src/phonenumbers", 35 "//third_party/protobuf/src", 36 ] 37 38 deps = [ 39 "$SMS_MMS_SOURCE_DIR:tel_sms_mms", 40 "$SMS_MMS_SOURCE_DIR/frameworks/native:tel_sms_mms_api", 41 "//third_party/libphonenumber/cpp:phonenumber_standard", 42 ] 43 44 external_deps = [ 45 "ability_runtime:ability_manager", 46 "ability_runtime:data_ability_helper", 47 "access_token:libaccesstoken_sdk", 48 "access_token:libnativetoken", 49 "access_token:libtoken_setproc", 50 "curl:curl_shared", 51 "c_utils:utils", 52 "common_event_service:cesfwk_innerkits", 53 "core_service:libtel_common", 54 "core_service:tel_core_service_api", 55 "data_share:datashare_consumer", 56 "eventhandler:libeventhandler", 57 "hilog:libhilog", 58 "ipc:ipc_single", 59 "napi:ace_napi", 60 "netmanager_base:net_conn_manager_if", 61 "netstack:http_client", 62 "telephony_data:tel_telephony_data", 63 ] 64 defines = [ 65 "TELEPHONY_LOG_TAG = \"SmsMmsFuzzTest\"", 66 "LOG_DOMAIN = 0xD000F00", 67 ] 68 69 cflags = [ 70 "-g", 71 "-O0", 72 "-Wno-unused-variable", 73 "-fno-omit-frame-pointer", 74 ] 75 76 sources = [ 77 "$SMS_MMS_SOURCE_DIR/test/fuzztest/common_fuzzer/addsmstoken_fuzzer.cpp", 78 "getsmssegmentsinfo_fuzzer.cpp", 79 ] 80} 81 82############################################################################### 83group("fuzztest") { 84 testonly = true 85 deps = [] 86 deps += [ 87 # deps file 88 ":GetSmsSegmentsInfoFuzzTest", 89 ] 90} 91############################################################################### 92