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.
13import("../../../device_status.gni")
14
15###############################hydra_fuzz#################################
16import("//build/config/features.gni")
17import("//build/test.gni")
18module_output_path = "${device_status_fuzz_output_path}"
19deps_ex = [
20  "ability_runtime:app_manager",
21  "device_manager:devicemanagersdk",
22  "access_token:libaccesstoken_sdk",
23  "cJSON:cjson",
24  "c_utils:utils",
25  "common_event_service:cesfwk_innerkits",
26  "graphic_2d:libcomposer",
27  "graphic_2d:librender_service_client",
28  "graphic_2d:window_animation",
29  "hisysevent:libhisysevent",
30  "hitrace:hitrace_meter",
31  "hilog:libhilog",
32  "input:libmmi-client",
33  "image_framework:image_native",
34  "window_manager:libwm",
35  "window_manager:libdm",
36]
37
38###############################fuzztest#################################
39ohos_fuzztest("GetDragSummaryFuzzTest") {
40  module_out_path = module_output_path
41
42  fuzz_config_file =
43      "${device_status_root_path}/test/fuzztest/getdragsummary_fuzzer"
44  include_dirs = [
45    "${device_status_root_path}/libs/interface",
46    "${device_status_service_path}/interaction/drag/include",
47    "${device_status_service_path}/communication/service/include",
48    "${device_status_utils_path}/include",
49  ]
50
51  cflags = [
52    "-Dprivate=public",
53    "-g",
54    "-O0",
55    "-fno-omit-frame-pointer",
56  ]
57  sources = [ "getdragsummary_fuzzer.cpp" ]
58
59  deps = [
60    "${device_status_interfaces_path}/innerkits:devicestatus_client",
61    "${device_status_root_path}/services:devicestatus_static_service",
62    "${device_status_root_path}/utils/ipc:devicestatus_ipc",
63    "${device_status_utils_path}:devicestatus_util",
64  ]
65
66  external_deps = deps_ex
67}
68
69group("fuzztest") {
70  testonly = true
71  deps = []
72  deps += [ ":GetDragSummaryFuzzTest" ]
73}
74