1# Copyright (c) 2021-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 14import("//build/ohos_var.gni") 15import("//drivers/peripheral/usb/usb.gni") 16import("//test/xts/tools/build/suite.gni") 17 18module_output_path = "hdf/usb" 19 20ohos_moduletest_suite("HatsHdfUsbBenchmarkDeviceTest") { 21 module_out_path = module_output_path 22 sources = [ 23 "../UsbSubscriberTest/UsbSubscriberTest.cpp", 24 "./common/HdfUsbdBenchmarkDeviceTest.cpp", 25 ] 26 27 include_dirs = [ 28 "include", 29 "//test/xts/hats/hdf/usb/UsbSubscriberTest", 30 "//utils/system/safwk/native/include", 31 ] 32 33 deps = [ 34 "//drivers/peripheral/usb/ddk:libusb_core", 35 "//drivers/peripheral/usb/hdi_service:libusb_interface_service_1.0", 36 "//third_party/benchmark", 37 "//third_party/googletest:gmock_main", 38 "//third_party/googletest:gtest_main", 39 ] 40 41 external_deps = [ 42 "ability_base:want", 43 "bundle_framework:appexecfwk_base", 44 "c_utils:utils", 45 "common_event_service:cesfwk_innerkits", 46 "drivers_interface_usb:libusb_proxy_1.0", 47 "eventhandler:libeventhandler", 48 "hdf_core:libhdf_utils", 49 "hiviewdfx_hilog_native:libhilog", 50 "ipc:ipc_single", 51 "safwk:system_ability_fwk", 52 "samgr:samgr_proxy", 53 ] 54 subsystem_name = "hdf" 55 part_name = "drivers_peripheral_usb" 56} 57 58ohos_moduletest_suite("HatsHdfUsbBenchmarkFunctionTest") { 59 module_out_path = module_output_path 60 sources = [ 61 "../UsbSubscriberTest/UsbSubscriberTest.cpp", 62 "./common/HdfUsbdBenchmarkFunctionTest.cpp", 63 ] 64 65 include_dirs = [ 66 "include", 67 "//test/xts/hats/hdf/usb/UsbSubscriberTest", 68 "//utils/system/safwk/native/include", 69 ] 70 71 deps = [ 72 "//drivers/peripheral/usb/ddk:libusb_core", 73 "//drivers/peripheral/usb/hdi_service:libusb_interface_service_1.0", 74 "//third_party/benchmark", 75 "//third_party/googletest:gmock_main", 76 "//third_party/googletest:gtest_main", 77 ] 78 79 external_deps = [ 80 "ability_base:want", 81 "bundle_framework:appexecfwk_base", 82 "c_utils:utils", 83 "common_event_service:cesfwk_innerkits", 84 "drivers_interface_usb:libusb_proxy_1.0", 85 "eventhandler:libeventhandler", 86 "hdf_core:libhdf_utils", 87 "hiviewdfx_hilog_native:libhilog", 88 "ipc:ipc_single", 89 "safwk:system_ability_fwk", 90 "samgr:samgr_proxy", 91 ] 92 subsystem_name = "hdf" 93 part_name = "drivers_peripheral_usb" 94} 95 96ohos_moduletest_suite("HatsHdfUsbBenchmarkRequestTest") { 97 module_out_path = module_output_path 98 sources = [ 99 "../UsbSubscriberTest/UsbSubscriberTest.cpp", 100 "./common/HdfUsbdBenchmarkRequestTest.cpp", 101 ] 102 103 include_dirs = [ 104 "include", 105 "//test/xts/hats/hdf/usb/UsbSubscriberTest", 106 "//utils/system/safwk/native/include", 107 ] 108 109 deps = [ 110 "//drivers/peripheral/usb/ddk:libusb_core", 111 "//drivers/peripheral/usb/hdi_service:libusb_interface_service_1.0", 112 "//third_party/benchmark", 113 "//third_party/googletest:gmock_main", 114 "//third_party/googletest:gtest_main", 115 ] 116 117 external_deps = [ 118 "ability_base:want", 119 "bundle_framework:appexecfwk_base", 120 "c_utils:utils", 121 "common_event_service:cesfwk_innerkits", 122 "drivers_interface_usb:libusb_proxy_1.0", 123 "eventhandler:libeventhandler", 124 "hdf_core:libhdf_utils", 125 "hiviewdfx_hilog_native:libhilog", 126 "ipc:ipc_single", 127 "safwk:system_ability_fwk", 128 "samgr:samgr_proxy", 129 ] 130 subsystem_name = "hdf" 131 part_name = "drivers_peripheral_usb" 132} 133 134ohos_moduletest_suite("HatsHdfUsbBenchmarkTransferTest") { 135 module_out_path = module_output_path 136 sources = [ 137 "../UsbSubscriberTest/UsbSubscriberTest.cpp", 138 "./common/HdfUsbdBenchmarkTransferTest.cpp", 139 ] 140 141 include_dirs = [ 142 "include", 143 "//test/xts/hats/hdf/usb/UsbSubscriberTest", 144 "//utils/system/safwk/native/include", 145 ] 146 147 deps = [ 148 "//drivers/peripheral/usb/ddk:libusb_core", 149 "//drivers/peripheral/usb/hdi_service:libusb_interface_service_1.0", 150 "//third_party/benchmark", 151 "//third_party/googletest:gmock_main", 152 "//third_party/googletest:gtest_main", 153 ] 154 155 external_deps = [ 156 "ability_base:want", 157 "bundle_framework:appexecfwk_base", 158 "c_utils:utils", 159 "common_event_service:cesfwk_innerkits", 160 "drivers_interface_usb:libusb_proxy_1.0", 161 "eventhandler:libeventhandler", 162 "hdf_core:libhdf_utils", 163 "hiviewdfx_hilog_native:libhilog", 164 "ipc:ipc_single", 165 "safwk:system_ability_fwk", 166 "samgr:samgr_proxy", 167 ] 168 subsystem_name = "hdf" 169 part_name = "drivers_peripheral_usb" 170} 171