Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 1 | // |
| 2 | // Copyright (C) 2014 The Android Open Source Project |
| 3 | // |
| 4 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | // you may not use this file except in compliance with the License. |
| 6 | // You may obtain a copy of the License at |
| 7 | // |
| 8 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | // |
| 10 | // Unless required by applicable law or agreed to in writing, software |
| 11 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | // See the License for the specific language governing permissions and |
| 14 | // limitations under the License. |
| 15 | // |
| 16 | |
Bob Badour | 3c53823 | 2021-02-12 21:26:48 -0800 | [diff] [blame] | 17 | package { |
| 18 | // See: http://go/android-license-faq |
| 19 | // A large-scale-change added 'default_applicable_licenses' to import |
| 20 | // all of the 'license_kinds' from "frameworks_native_license" |
| 21 | // to get the below license kinds: |
| 22 | // SPDX-license-identifier-Apache-2.0 |
| 23 | default_applicable_licenses: ["frameworks_native_license"], |
| 24 | } |
| 25 | |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 26 | cc_defaults { |
| 27 | name: "binder_test_defaults", |
Tomasz Wasilczyk | a32912e | 2024-04-30 10:55:58 -0700 | [diff] [blame^] | 28 | cmake_snapshot_supported: true, |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 29 | cflags: [ |
| 30 | "-Wall", |
| 31 | "-Werror", |
Tomasz Wasilczyk | e97f3a8 | 2024-04-30 10:37:32 -0700 | [diff] [blame] | 32 | "-Wformat", |
| 33 | "-Wpessimizing-move", |
| 34 | "-Wsign-compare", |
| 35 | "-Wunused-result", |
| 36 | "-Wzero-as-null-pointer-constant", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 37 | ], |
| 38 | } |
| 39 | |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 40 | cc_test { |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 41 | name: "binderDriverInterfaceTest", |
| 42 | defaults: ["binder_test_defaults"], |
Yifan Hong | 4e419d8 | 2021-04-26 11:32:56 -0700 | [diff] [blame] | 43 | header_libs: ["libbinder_headers"], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 44 | srcs: ["binderDriverInterfaceTest.cpp"], |
Steven Moreland | ea7659e | 2022-02-03 00:04:06 +0000 | [diff] [blame] | 45 | test_suites: [ |
| 46 | "device-tests", |
| 47 | "vts", |
| 48 | ], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 49 | } |
| 50 | |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 51 | // unit test only, which can run on host and doesn't use /dev/binder |
| 52 | cc_test { |
Steven Moreland | 2831860 | 2021-06-25 01:16:29 +0000 | [diff] [blame] | 53 | name: "binderUnitTest", |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 54 | host_supported: true, |
| 55 | target: { |
| 56 | darwin: { |
| 57 | enabled: false, |
| 58 | }, |
| 59 | }, |
Steven Moreland | ea7659e | 2022-02-03 00:04:06 +0000 | [diff] [blame] | 60 | srcs: [ |
| 61 | "binderParcelUnitTest.cpp", |
| 62 | "binderBinderUnitTest.cpp", |
Steven Moreland | cf37369 | 2022-01-21 23:55:15 +0000 | [diff] [blame] | 63 | "binderStatusUnitTest.cpp", |
Atneya Nair | 7ade4f4 | 2022-02-07 18:16:48 -0500 | [diff] [blame] | 64 | "binderMemoryHeapBaseUnitTest.cpp", |
Fabián Cañas | 08bdc77 | 2023-01-02 15:02:56 -0500 | [diff] [blame] | 65 | "binderRecordedTransactionTest.cpp", |
Abhishek Gadewar | 76f0082 | 2024-05-09 17:02:18 -0700 | [diff] [blame] | 66 | "binderPersistableBundleTest.cpp", |
Steven Moreland | ea7659e | 2022-02-03 00:04:06 +0000 | [diff] [blame] | 67 | ], |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 68 | shared_libs: [ |
| 69 | "libbinder", |
Steven Moreland | f80809b | 2021-10-07 18:09:20 -0700 | [diff] [blame] | 70 | "libcutils", |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 71 | "libutils", |
| 72 | ], |
| 73 | test_suites: ["general-tests"], |
| 74 | } |
| 75 | |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 76 | cc_test { |
Steven Moreland | a8244b9 | 2023-04-20 23:34:11 +0000 | [diff] [blame] | 77 | name: "binderRecordReplayTest", |
| 78 | srcs: ["binderRecordReplayTest.cpp"], |
Pawan Wagh | 76b1815 | 2023-12-01 14:30:26 +0000 | [diff] [blame] | 79 | cflags: [ |
| 80 | "-DBINDER_WITH_KERNEL_IPC", |
| 81 | ], |
Steven Moreland | a8244b9 | 2023-04-20 23:34:11 +0000 | [diff] [blame] | 82 | shared_libs: [ |
| 83 | "libbinder", |
| 84 | "libcutils", |
| 85 | "libutils", |
Pawan Wagh | 76b1815 | 2023-12-01 14:30:26 +0000 | [diff] [blame] | 86 | "liblog", |
Steven Moreland | a8244b9 | 2023-04-20 23:34:11 +0000 | [diff] [blame] | 87 | ], |
| 88 | static_libs: [ |
| 89 | "binderRecordReplayTestIface-cpp", |
Pawan Wagh | 8da4538 | 2023-05-11 08:08:50 +0000 | [diff] [blame] | 90 | "binderReadParcelIface-cpp", |
Pawan Wagh | 94bf303 | 2023-07-27 17:15:02 +0000 | [diff] [blame] | 91 | "libbinder_random_parcel_seeds", |
| 92 | "libbinder_random_parcel", |
Steven Moreland | a8244b9 | 2023-04-20 23:34:11 +0000 | [diff] [blame] | 93 | ], |
| 94 | test_suites: ["general-tests"], |
Steven Moreland | 4ed688d | 2023-05-03 23:03:56 +0000 | [diff] [blame] | 95 | require_root: true, |
Steven Moreland | a8244b9 | 2023-04-20 23:34:11 +0000 | [diff] [blame] | 96 | } |
| 97 | |
| 98 | aidl_interface { |
| 99 | name: "binderRecordReplayTestIface", |
| 100 | unstable: true, |
| 101 | srcs: [ |
| 102 | "IBinderRecordReplayTest.aidl", |
| 103 | ], |
Pawan Wagh | 8da4538 | 2023-05-11 08:08:50 +0000 | [diff] [blame] | 104 | imports: ["binderReadParcelIface"], |
| 105 | backend: { |
| 106 | java: { |
| 107 | enabled: true, |
| 108 | platform_apis: true, |
| 109 | }, |
Steven Moreland | 5981335 | 2024-02-08 23:52:11 +0000 | [diff] [blame] | 110 | |
| 111 | // TODO: switch from FileDescriptor to ParcelFileDescriptor |
Pawan Wagh | 76b1815 | 2023-12-01 14:30:26 +0000 | [diff] [blame] | 112 | ndk: { |
| 113 | enabled: false, |
| 114 | }, |
Steven Moreland | 5981335 | 2024-02-08 23:52:11 +0000 | [diff] [blame] | 115 | rust: { |
| 116 | enabled: false, |
| 117 | }, |
Pawan Wagh | 8da4538 | 2023-05-11 08:08:50 +0000 | [diff] [blame] | 118 | }, |
Steven Moreland | a8244b9 | 2023-04-20 23:34:11 +0000 | [diff] [blame] | 119 | } |
| 120 | |
| 121 | cc_test { |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 122 | name: "binderLibTest", |
| 123 | defaults: ["binder_test_defaults"], |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 124 | |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 125 | srcs: ["binderLibTest.cpp"], |
| 126 | shared_libs: [ |
Yifan Hong | 84bedeb | 2021-04-21 21:37:17 -0700 | [diff] [blame] | 127 | "libbase", |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 128 | "libbinder", |
Yifan Hong | 8b89085 | 2021-06-10 13:44:09 -0700 | [diff] [blame] | 129 | "liblog", |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 130 | "libutils", |
| 131 | ], |
Yifan Hong | bbd2a0d | 2021-05-07 22:12:23 -0700 | [diff] [blame] | 132 | static_libs: [ |
| 133 | "libgmock", |
| 134 | ], |
Steven Moreland | ea7659e | 2022-02-03 00:04:06 +0000 | [diff] [blame] | 135 | test_suites: [ |
| 136 | "device-tests", |
| 137 | "vts", |
| 138 | ], |
Dan Shi | 80ada59 | 2019-09-13 09:17:17 -0700 | [diff] [blame] | 139 | require_root: true, |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 140 | } |
| 141 | |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 142 | aidl_interface { |
| 143 | name: "binderRpcTestIface", |
Andrei Homescu | d65666d | 2023-03-03 07:28:02 +0000 | [diff] [blame] | 144 | vendor_available: true, |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 145 | host_supported: true, |
Tomasz Wasilczyk | a32912e | 2024-04-30 10:55:58 -0700 | [diff] [blame^] | 146 | cmake_snapshot_supported: true, |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 147 | unstable: true, |
| 148 | srcs: [ |
Yifan Hong | 1deca4b | 2021-09-10 16:16:44 -0700 | [diff] [blame] | 149 | "BinderRpcTestClientInfo.aidl", |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 150 | "BinderRpcTestServerConfig.aidl", |
Yifan Hong | 1deca4b | 2021-09-10 16:16:44 -0700 | [diff] [blame] | 151 | "BinderRpcTestServerInfo.aidl", |
Steven Moreland | 659416d | 2021-05-11 00:47:50 +0000 | [diff] [blame] | 152 | "IBinderRpcCallback.aidl", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 153 | "IBinderRpcSession.aidl", |
| 154 | "IBinderRpcTest.aidl", |
Yifan Hong | 1deca4b | 2021-09-10 16:16:44 -0700 | [diff] [blame] | 155 | "ParcelableCertificateData.aidl", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 156 | ], |
Tomasz Wasilczyk | 7c511e9 | 2023-12-04 17:00:28 -0800 | [diff] [blame] | 157 | flags: [ |
| 158 | "-Werror", |
| 159 | "-Wno-mixed-oneway", |
| 160 | ], |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 161 | backend: { |
| 162 | java: { |
| 163 | enabled: false, |
| 164 | }, |
| 165 | }, |
| 166 | } |
| 167 | |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 168 | cc_library_static { |
| 169 | name: "libbinder_tls_test_utils", |
| 170 | host_supported: true, |
Andrei Homescu | d65666d | 2023-03-03 07:28:02 +0000 | [diff] [blame] | 171 | vendor_available: true, |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 172 | target: { |
| 173 | darwin: { |
| 174 | enabled: false, |
| 175 | }, |
| 176 | }, |
| 177 | defaults: [ |
| 178 | "binder_test_defaults", |
| 179 | "libbinder_tls_shared_deps", |
| 180 | ], |
| 181 | shared_libs: [ |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 182 | "libbase", |
| 183 | "liblog", |
| 184 | ], |
| 185 | static_libs: [ |
| 186 | "libbinder_tls_static", |
| 187 | ], |
| 188 | srcs: [ |
| 189 | "RpcTlsTestUtils.cpp", |
| 190 | ], |
| 191 | export_include_dirs: [ |
| 192 | "include_tls_test_utils", |
| 193 | ], |
| 194 | visibility: [ |
| 195 | ":__subpackages__", |
| 196 | ], |
| 197 | } |
| 198 | |
Tomasz Wasilczyk | 26db5e4 | 2023-11-02 11:45:11 -0700 | [diff] [blame] | 199 | cc_library_static { |
| 200 | name: "libbinder_test_utils", |
| 201 | host_supported: true, |
| 202 | vendor_available: true, |
| 203 | target: { |
| 204 | darwin: { |
| 205 | enabled: false, |
| 206 | }, |
| 207 | }, |
| 208 | defaults: [ |
| 209 | "binder_test_defaults", |
| 210 | ], |
Tomasz Wasilczyk | fbfea5b | 2024-04-30 10:54:23 -0700 | [diff] [blame] | 211 | header_libs: [ |
| 212 | "libbinder_headers_base", |
| 213 | ], |
Tomasz Wasilczyk | 26db5e4 | 2023-11-02 11:45:11 -0700 | [diff] [blame] | 214 | shared_libs: [ |
| 215 | "libbase", |
Tomasz Wasilczyk | 26db5e4 | 2023-11-02 11:45:11 -0700 | [diff] [blame] | 216 | ], |
| 217 | srcs: [ |
| 218 | "FileUtils.cpp", |
| 219 | ], |
| 220 | visibility: [ |
| 221 | ":__subpackages__", |
| 222 | ], |
| 223 | } |
| 224 | |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 225 | cc_defaults { |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 226 | name: "binderRpcTest_common_defaults", |
Steven Moreland | f6ec463 | 2021-04-01 16:20:47 +0000 | [diff] [blame] | 227 | host_supported: true, |
Tomasz Wasilczyk | a32912e | 2024-04-30 10:55:58 -0700 | [diff] [blame^] | 228 | cmake_snapshot_supported: true, |
Steven Moreland | f6ec463 | 2021-04-01 16:20:47 +0000 | [diff] [blame] | 229 | target: { |
| 230 | darwin: { |
| 231 | enabled: false, |
| 232 | }, |
| 233 | }, |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 234 | defaults: [ |
| 235 | "binder_test_defaults", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 236 | ], |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 237 | |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 238 | static_libs: [ |
Tomasz Wasilczyk | 26db5e4 | 2023-11-02 11:45:11 -0700 | [diff] [blame] | 239 | "libbinder_test_utils", |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 240 | "libbinder_tls_static", |
| 241 | "libbinder_tls_test_utils", |
| 242 | "binderRpcTestIface-cpp", |
| 243 | "binderRpcTestIface-ndk", |
| 244 | ], |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 245 | } |
| 246 | |
| 247 | cc_defaults { |
| 248 | name: "binderRpcTest_service_defaults", |
| 249 | defaults: [ |
| 250 | "binderRpcTest_common_defaults", |
| 251 | ], |
| 252 | gtest: false, |
| 253 | auto_gen_config: false, |
| 254 | srcs: [ |
| 255 | "binderRpcTestCommon.cpp", |
| 256 | "binderRpcTestService.cpp", |
| 257 | ], |
| 258 | } |
| 259 | |
| 260 | cc_defaults { |
| 261 | name: "binderRpcTest_defaults", |
| 262 | target: { |
| 263 | android: { |
| 264 | test_suites: ["vts"], |
| 265 | }, |
| 266 | }, |
| 267 | defaults: [ |
| 268 | "binderRpcTest_common_defaults", |
| 269 | ], |
| 270 | |
| 271 | srcs: [ |
| 272 | "binderRpcTest.cpp", |
| 273 | "binderRpcTestCommon.cpp", |
Andrei Homescu | 9a9b1b4 | 2022-10-14 01:40:59 +0000 | [diff] [blame] | 274 | "binderRpcUniversalTests.cpp", |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 275 | ], |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 276 | |
Steven Moreland | 2053161 | 2023-04-04 18:03:24 +0000 | [diff] [blame] | 277 | // This test uses a lot of resources and takes a long time. Due to |
| 278 | // design of several tests, it is also very sensitive to resource |
| 279 | // contention on the device. b/276820894 |
| 280 | test_options: { |
| 281 | unit_test: false, |
Steven Moreland | f6b18f2 | 2023-12-16 04:46:22 +0000 | [diff] [blame] | 282 | test_runner_options: [ |
| 283 | { |
| 284 | name: "native-test-timeout", |
| 285 | value: "10m", |
| 286 | }, |
| 287 | ], |
Steven Moreland | 2053161 | 2023-04-04 18:03:24 +0000 | [diff] [blame] | 288 | }, |
| 289 | |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 290 | test_suites: ["general-tests"], |
| 291 | require_root: true, |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 292 | |
| 293 | data_bins: [ |
| 294 | "binder_rpc_test_service", |
| 295 | "binder_rpc_test_service_no_kernel", |
| 296 | "binder_rpc_test_service_single_threaded", |
| 297 | "binder_rpc_test_service_single_threaded_no_kernel", |
| 298 | ], |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 299 | } |
| 300 | |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 301 | cc_defaults { |
| 302 | name: "binderRpcTest_shared_defaults", |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 303 | cflags: [ |
| 304 | "-DBINDER_WITH_KERNEL_IPC", |
| 305 | ], |
| 306 | |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 307 | shared_libs: [ |
| 308 | "libbinder", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 309 | "libbinder_ndk", |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 310 | "libbase", |
| 311 | "libutils", |
| 312 | "libcutils", |
| 313 | "liblog", |
| 314 | ], |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 315 | } |
| 316 | |
| 317 | cc_defaults { |
| 318 | name: "binderRpcTest_static_defaults", |
| 319 | |
| 320 | shared_libs: [ |
Andrei Homescu | 68a5561 | 2022-08-02 01:25:15 +0000 | [diff] [blame] | 321 | "liblog", |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 322 | "libutils", |
| 323 | // libcrypto_static is not visible to this module |
| 324 | "libcrypto", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 325 | ], |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 326 | static_libs: [ |
| 327 | "libbase", |
| 328 | "libcutils", |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 329 | "libssl", |
| 330 | ], |
| 331 | |
| 332 | cflags: [ |
| 333 | // Disable tests that require shared libraries, |
| 334 | // e.g., libbinder.so or libbinder_ndk.so |
| 335 | "-DBINDER_TEST_NO_SHARED_LIBS", |
| 336 | ], |
| 337 | } |
| 338 | |
| 339 | cc_test { |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 340 | // The module name cannot start with "binderRpcTest" because |
| 341 | // then atest tries to execute it as part of binderRpcTest |
| 342 | name: "binder_rpc_test_service", |
| 343 | defaults: [ |
| 344 | "binderRpcTest_service_defaults", |
| 345 | "binderRpcTest_shared_defaults", |
| 346 | "libbinder_tls_shared_deps", |
| 347 | ], |
| 348 | } |
| 349 | |
| 350 | cc_test { |
| 351 | name: "binder_rpc_test_service_no_kernel", |
| 352 | defaults: [ |
| 353 | "binderRpcTest_service_defaults", |
| 354 | "binderRpcTest_static_defaults", |
| 355 | ], |
| 356 | static_libs: [ |
| 357 | "libbinder_rpc_no_kernel", |
| 358 | ], |
| 359 | } |
| 360 | |
| 361 | cc_test { |
| 362 | name: "binder_rpc_test_service_single_threaded", |
| 363 | defaults: [ |
| 364 | "binderRpcTest_service_defaults", |
| 365 | "binderRpcTest_static_defaults", |
| 366 | ], |
| 367 | cflags: [ |
| 368 | "-DBINDER_RPC_SINGLE_THREADED", |
| 369 | "-DBINDER_WITH_KERNEL_IPC", |
| 370 | ], |
| 371 | static_libs: [ |
| 372 | "libbinder_rpc_single_threaded", |
| 373 | ], |
| 374 | } |
| 375 | |
| 376 | cc_test { |
| 377 | name: "binder_rpc_test_service_single_threaded_no_kernel", |
| 378 | defaults: [ |
| 379 | "binderRpcTest_service_defaults", |
| 380 | "binderRpcTest_static_defaults", |
| 381 | ], |
| 382 | cflags: [ |
| 383 | "-DBINDER_RPC_SINGLE_THREADED", |
| 384 | ], |
| 385 | static_libs: [ |
| 386 | "libbinder_rpc_single_threaded_no_kernel", |
| 387 | ], |
Tomasz Wasilczyk | a32912e | 2024-04-30 10:55:58 -0700 | [diff] [blame^] | 388 | shared_libs: [ |
| 389 | "libbinder_ndk", |
| 390 | ], |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 391 | } |
| 392 | |
Andrei Homescu | 9d8adb1 | 2022-08-02 04:38:30 +0000 | [diff] [blame] | 393 | cc_binary { |
| 394 | name: "binderRpcTestService_on_trusty_mock", |
| 395 | defaults: [ |
| 396 | "trusty_mock_defaults", |
| 397 | ], |
| 398 | |
| 399 | srcs: [ |
| 400 | "binderRpcTestCommon.cpp", |
| 401 | "binderRpcTestServiceTrusty.cpp", |
| 402 | ], |
| 403 | |
| 404 | shared_libs: [ |
| 405 | "libbinder_on_trusty_mock", |
| 406 | "libbase", |
| 407 | "libutils", |
| 408 | "libcutils", |
| 409 | ], |
| 410 | |
| 411 | static_libs: [ |
| 412 | "binderRpcTestIface-cpp", |
| 413 | ], |
| 414 | } |
| 415 | |
Andrei Homescu | 4d9420e | 2023-01-31 01:38:48 +0000 | [diff] [blame] | 416 | cc_binary { |
| 417 | name: "binderRpcTest_on_trusty_mock", |
| 418 | defaults: [ |
| 419 | "trusty_mock_defaults", |
| 420 | ], |
| 421 | |
| 422 | srcs: [ |
| 423 | "binderRpcUniversalTests.cpp", |
| 424 | "binderRpcTestCommon.cpp", |
| 425 | "binderRpcTestTrusty.cpp", |
| 426 | ], |
| 427 | |
| 428 | shared_libs: [ |
| 429 | "libbinder_on_trusty_mock", |
| 430 | "libbase", |
| 431 | "libutils", |
| 432 | "libcutils", |
| 433 | ], |
| 434 | |
| 435 | static_libs: [ |
| 436 | "binderRpcTestIface-cpp", |
| 437 | "libgtest", |
| 438 | ], |
| 439 | } |
| 440 | |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 441 | cc_test { |
| 442 | name: "binderRpcTest", |
| 443 | defaults: [ |
| 444 | "binderRpcTest_defaults", |
| 445 | "binderRpcTest_shared_defaults", |
| 446 | "libbinder_tls_shared_deps", |
| 447 | ], |
Andrei Homescu | 875996f | 2022-08-24 04:25:11 +0000 | [diff] [blame] | 448 | |
| 449 | // Add the Trusty mock library as a fake dependency so it gets built |
| 450 | required: [ |
| 451 | "libbinder_on_trusty_mock", |
Andrei Homescu | 40dbf25 | 2024-03-28 21:19:42 +0000 | [diff] [blame] | 452 | "libbinder_ndk_on_trusty_mock", |
Andrei Homescu | 6dfa8c9 | 2024-03-29 04:58:32 +0000 | [diff] [blame] | 453 | "libbinder_rs_on_trusty_mock", |
Andrei Homescu | 9d8adb1 | 2022-08-02 04:38:30 +0000 | [diff] [blame] | 454 | "binderRpcTestService_on_trusty_mock", |
Andrei Homescu | 4d9420e | 2023-01-31 01:38:48 +0000 | [diff] [blame] | 455 | "binderRpcTest_on_trusty_mock", |
Andrei Homescu | 875996f | 2022-08-24 04:25:11 +0000 | [diff] [blame] | 456 | ], |
Andrei Homescu | 2a29801 | 2022-06-15 01:08:54 +0000 | [diff] [blame] | 457 | } |
| 458 | |
| 459 | cc_test { |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 460 | name: "binderRpcTestNoKernel", |
| 461 | defaults: [ |
| 462 | "binderRpcTest_defaults", |
| 463 | "binderRpcTest_static_defaults", |
| 464 | ], |
| 465 | static_libs: [ |
| 466 | "libbinder_rpc_no_kernel", |
| 467 | ], |
| 468 | } |
| 469 | |
| 470 | cc_test { |
Tomasz Wasilczyk | 2265ad9 | 2024-05-01 12:54:46 -0700 | [diff] [blame] | 471 | name: "binderRpcTestNoKernelAtAll", |
| 472 | defaults: [ |
| 473 | "binderRpcTest_defaults", |
| 474 | "binderRpcTest_static_defaults", |
| 475 | ], |
| 476 | static_libs: [ |
| 477 | "libbinder_rpc_no_kernel", |
| 478 | ], |
| 479 | cflags: [ |
| 480 | "-DBINDER_NO_KERNEL_IPC_TESTING", |
| 481 | ], |
| 482 | } |
| 483 | |
| 484 | cc_test { |
Andrei Homescu | 12106de | 2022-04-27 04:42:21 +0000 | [diff] [blame] | 485 | name: "binderRpcTestSingleThreaded", |
| 486 | defaults: [ |
| 487 | "binderRpcTest_defaults", |
| 488 | "binderRpcTest_static_defaults", |
| 489 | ], |
| 490 | cflags: [ |
| 491 | "-DBINDER_RPC_SINGLE_THREADED", |
| 492 | "-DBINDER_WITH_KERNEL_IPC", |
| 493 | ], |
| 494 | static_libs: [ |
| 495 | "libbinder_rpc_single_threaded", |
| 496 | ], |
| 497 | } |
| 498 | |
| 499 | cc_test { |
| 500 | name: "binderRpcTestSingleThreadedNoKernel", |
| 501 | defaults: [ |
| 502 | "binderRpcTest_defaults", |
| 503 | "binderRpcTest_static_defaults", |
| 504 | ], |
| 505 | cflags: [ |
| 506 | "-DBINDER_RPC_SINGLE_THREADED", |
| 507 | ], |
| 508 | static_libs: [ |
| 509 | "libbinder_rpc_single_threaded_no_kernel", |
| 510 | ], |
Tomasz Wasilczyk | a32912e | 2024-04-30 10:55:58 -0700 | [diff] [blame^] | 511 | shared_libs: [ |
| 512 | "libbinder_ndk", |
| 513 | ], |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 514 | } |
| 515 | |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 516 | cc_test { |
Andrei Homescu | d65666d | 2023-03-03 07:28:02 +0000 | [diff] [blame] | 517 | name: "binderRpcToTrustyTest", |
| 518 | vendor: true, |
| 519 | host_supported: false, |
| 520 | defaults: [ |
| 521 | "binderRpcTest_common_defaults", |
| 522 | "binderRpcTest_static_defaults", |
| 523 | ], |
| 524 | |
| 525 | srcs: [ |
| 526 | "binderRpcTest.cpp", |
| 527 | "binderRpcTestCommon.cpp", |
| 528 | "binderRpcUniversalTests.cpp", |
| 529 | ], |
| 530 | |
| 531 | cflags: [ |
| 532 | "-DBINDER_RPC_TO_TRUSTY_TEST", |
| 533 | ], |
| 534 | |
| 535 | static_libs: [ |
| 536 | // We want to link libbinder statically so we can push the binary |
| 537 | // to the device for testing independently of the library |
| 538 | "libbinder_rpc_no_kernel", |
| 539 | "libbinder_trusty", |
| 540 | "libtrusty", |
| 541 | ], |
| 542 | |
| 543 | test_suites: ["device-tests"], |
| 544 | require_root: true, |
| 545 | } |
| 546 | |
| 547 | cc_test { |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 548 | name: "RpcTlsUtilsTest", |
| 549 | host_supported: true, |
| 550 | target: { |
| 551 | darwin: { |
| 552 | enabled: false, |
| 553 | }, |
| 554 | android: { |
| 555 | test_suites: ["vts"], |
| 556 | }, |
| 557 | }, |
| 558 | defaults: [ |
| 559 | "binder_test_defaults", |
| 560 | "libbinder_tls_shared_deps", |
| 561 | ], |
| 562 | srcs: [ |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 563 | "RpcTlsUtilsTest.cpp", |
| 564 | ], |
| 565 | shared_libs: [ |
| 566 | "libbinder", |
| 567 | "libbase", |
| 568 | "libutils", |
| 569 | "liblog", |
| 570 | ], |
| 571 | static_libs: [ |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 572 | "libbinder_tls_test_utils", |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 573 | "libbinder_tls_static", |
| 574 | ], |
Steven Moreland | ea7659e | 2022-02-03 00:04:06 +0000 | [diff] [blame] | 575 | test_suites: [ |
| 576 | "general-tests", |
| 577 | "device-tests", |
| 578 | ], |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 579 | } |
| 580 | |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 581 | cc_benchmark { |
| 582 | name: "binderRpcBenchmark", |
Yifan Hong | aecdd17 | 2021-09-21 14:53:13 -0700 | [diff] [blame] | 583 | defaults: [ |
| 584 | "binder_test_defaults", |
| 585 | "libbinder_tls_shared_deps", |
| 586 | ], |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 587 | host_supported: true, |
Steven Moreland | 722b490 | 2021-04-16 16:30:18 +0000 | [diff] [blame] | 588 | target: { |
| 589 | darwin: { |
| 590 | enabled: false, |
| 591 | }, |
| 592 | }, |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 593 | srcs: [ |
| 594 | "binderRpcBenchmark.cpp", |
| 595 | "IBinderRpcBenchmark.aidl", |
| 596 | ], |
| 597 | shared_libs: [ |
| 598 | "libbase", |
| 599 | "libbinder", |
| 600 | "liblog", |
| 601 | "libutils", |
| 602 | ], |
Yifan Hong | aecdd17 | 2021-09-21 14:53:13 -0700 | [diff] [blame] | 603 | static_libs: [ |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 604 | "libbinder_tls_test_utils", |
Yifan Hong | aecdd17 | 2021-09-21 14:53:13 -0700 | [diff] [blame] | 605 | "libbinder_tls_static", |
| 606 | ], |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 607 | } |
| 608 | |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 609 | cc_test { |
Steven Moreland | 59640db | 2021-07-22 17:19:31 -0700 | [diff] [blame] | 610 | name: "binderRpcWireProtocolTest", |
| 611 | host_supported: true, |
| 612 | target: { |
| 613 | darwin: { |
| 614 | enabled: false, |
| 615 | }, |
| 616 | android: { |
| 617 | test_suites: ["vts"], |
| 618 | }, |
| 619 | }, |
| 620 | defaults: [ |
| 621 | "binder_test_defaults", |
| 622 | ], |
| 623 | srcs: [ |
| 624 | "binderRpcWireProtocolTest.cpp", |
| 625 | ], |
| 626 | shared_libs: [ |
| 627 | "libbinder", |
| 628 | "libbase", |
| 629 | "libutils", |
| 630 | "libcutils", |
| 631 | "liblog", |
| 632 | ], |
| 633 | test_suites: ["general-tests"], |
| 634 | } |
| 635 | |
| 636 | cc_test { |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 637 | name: "binderThroughputTest", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 638 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 639 | srcs: ["binderThroughputTest.cpp"], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 640 | shared_libs: [ |
| 641 | "libbinder", |
| 642 | "libutils", |
| 643 | ], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 644 | cflags: [ |
| 645 | "-g", |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 646 | "-Wno-missing-field-initializers", |
| 647 | "-Wno-sign-compare", |
| 648 | "-O3", |
| 649 | ], |
| 650 | } |
Wei Wang | 78f2a37 | 2016-10-20 23:18:17 -0700 | [diff] [blame] | 651 | |
| 652 | cc_test { |
| 653 | name: "binderTextOutputTest", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 654 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 655 | srcs: ["binderTextOutputTest.cpp"], |
Wei Wang | 78f2a37 | 2016-10-20 23:18:17 -0700 | [diff] [blame] | 656 | shared_libs: [ |
| 657 | "libbinder", |
| 658 | "libutils", |
| 659 | "libbase", |
| 660 | ], |
Steven Moreland | 67812c2 | 2019-07-10 13:50:40 -0700 | [diff] [blame] | 661 | test_suites: ["device-tests"], |
Wei Wang | 78f2a37 | 2016-10-20 23:18:17 -0700 | [diff] [blame] | 662 | } |
Howard Chen | c135dbc | 2017-03-25 17:12:59 +0800 | [diff] [blame] | 663 | |
| 664 | cc_test { |
| 665 | name: "schd-dbg", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 666 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 667 | srcs: ["schd-dbg.cpp"], |
Howard Chen | c135dbc | 2017-03-25 17:12:59 +0800 | [diff] [blame] | 668 | shared_libs: [ |
| 669 | "libbinder", |
| 670 | "libutils", |
| 671 | "libbase", |
| 672 | ], |
| 673 | } |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 674 | |
| 675 | cc_test { |
| 676 | name: "binderSafeInterfaceTest", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 677 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 678 | srcs: ["binderSafeInterfaceTest.cpp"], |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 679 | |
| 680 | cppflags: [ |
Colin Cross | 1383d9f | 2019-11-06 13:33:40 -0800 | [diff] [blame] | 681 | "-Wextra", |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 682 | ], |
| 683 | |
| 684 | cpp_std: "experimental", |
| 685 | gnu_extensions: false, |
| 686 | |
| 687 | shared_libs: [ |
| 688 | "libbinder", |
Dan Stoza | 2537db7 | 2017-04-07 16:32:38 -0700 | [diff] [blame] | 689 | "libcutils", |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 690 | "liblog", |
| 691 | "libutils", |
| 692 | ], |
Steven Moreland | ea7659e | 2022-02-03 00:04:06 +0000 | [diff] [blame] | 693 | test_suites: [ |
| 694 | "device-tests", |
| 695 | "vts", |
| 696 | ], |
Dan Shi | 80ada59 | 2019-09-13 09:17:17 -0700 | [diff] [blame] | 697 | require_root: true, |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 698 | } |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 699 | |
Steven Moreland | f23dae2 | 2020-10-27 19:34:55 +0000 | [diff] [blame] | 700 | cc_test { |
| 701 | name: "binderClearBufTest", |
| 702 | defaults: ["binder_test_defaults"], |
| 703 | srcs: [ |
| 704 | "binderClearBufTest.cpp", |
| 705 | ], |
| 706 | |
| 707 | shared_libs: [ |
| 708 | "libbase", |
| 709 | "libbinder", |
| 710 | "liblog", |
| 711 | "libutils", |
| 712 | ], |
| 713 | |
| 714 | test_suites: ["general-tests"], |
| 715 | require_root: true, |
| 716 | } |
| 717 | |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 718 | aidl_interface { |
| 719 | name: "binderStabilityTestIface", |
Jiyong Park | 701fa1a | 2020-04-13 12:55:44 +0900 | [diff] [blame] | 720 | unstable: true, |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 721 | srcs: [ |
| 722 | "IBinderStabilityTest.aidl", |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 723 | ], |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 724 | backend: { |
| 725 | java: { |
| 726 | enabled: false, |
| 727 | }, |
| 728 | }, |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 729 | } |
| 730 | |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 731 | cc_test { |
| 732 | name: "binderStabilityTest", |
| 733 | defaults: ["binder_test_defaults"], |
| 734 | srcs: [ |
| 735 | "binderStabilityTest.cpp", |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 736 | ], |
| 737 | |
Steven Moreland | 13f8466 | 2020-07-23 21:30:41 +0000 | [diff] [blame] | 738 | // critical that libbinder/libbinder_ndk are shared for VTS |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 739 | shared_libs: [ |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 740 | "libbinder_ndk", |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 741 | "libbinder", |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 742 | "liblog", |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 743 | "libutils", |
| 744 | ], |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 745 | static_libs: [ |
| 746 | "binderStabilityTestIface-cpp", |
Jiyong Park | 9a9427c | 2021-08-09 09:01:15 +0900 | [diff] [blame] | 747 | "binderStabilityTestIface-ndk", |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 748 | ], |
| 749 | |
Steven Moreland | ea7659e | 2022-02-03 00:04:06 +0000 | [diff] [blame] | 750 | test_suites: [ |
| 751 | "device-tests", |
| 752 | "vts", |
| 753 | ], |
Dan Shi | 302709b | 2019-09-19 15:28:15 -0700 | [diff] [blame] | 754 | require_root: true, |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 755 | } |
Steven Moreland | 042ae82 | 2020-05-27 17:45:17 +0000 | [diff] [blame] | 756 | |
| 757 | cc_test { |
| 758 | name: "binderAllocationLimits", |
| 759 | defaults: ["binder_test_defaults"], |
| 760 | srcs: ["binderAllocationLimits.cpp"], |
| 761 | shared_libs: [ |
| 762 | "libbinder", |
| 763 | "liblog", |
Steven Moreland | 66acefe | 2022-09-09 00:34:40 +0000 | [diff] [blame] | 764 | "libcutils", |
Steven Moreland | 042ae82 | 2020-05-27 17:45:17 +0000 | [diff] [blame] | 765 | "libutils", |
| 766 | "libutilscallstack", |
| 767 | "libbase", |
| 768 | ], |
| 769 | test_suites: ["device-tests"], |
| 770 | require_root: true, |
| 771 | } |
Andy Hung | 73a1470 | 2020-11-24 13:04:46 -0800 | [diff] [blame] | 772 | |
| 773 | cc_benchmark { |
| 774 | name: "binderParcelBenchmark", |
| 775 | defaults: ["binder_test_defaults"], |
| 776 | srcs: ["binderParcelBenchmark.cpp"], |
| 777 | shared_libs: [ |
| 778 | "libbase", |
| 779 | "libbinder", |
| 780 | "liblog", |
| 781 | "libutils", |
| 782 | ], |
Steven Moreland | 9b254dd | 2023-05-11 00:37:55 +0000 | [diff] [blame] | 783 | test_suites: ["general-tests"], |
Andy Hung | 73a1470 | 2020-11-24 13:04:46 -0800 | [diff] [blame] | 784 | } |
Yifan Hong | af766e6 | 2021-06-14 13:24:19 -0700 | [diff] [blame] | 785 | |
| 786 | cc_test_host { |
| 787 | name: "binderUtilsHostTest", |
| 788 | defaults: ["binder_test_defaults"], |
| 789 | srcs: ["binderUtilsHostTest.cpp"], |
| 790 | shared_libs: [ |
| 791 | "libbase", |
| 792 | "libbinder", |
| 793 | ], |
| 794 | static_libs: [ |
| 795 | "libgmock", |
| 796 | ], |
| 797 | test_suites: ["general-tests"], |
Yifan Hong | 44dec54 | 2021-06-22 10:47:44 -0700 | [diff] [blame] | 798 | target: { |
| 799 | darwin: { |
| 800 | enabled: false, |
| 801 | }, |
| 802 | }, |
Yifan Hong | af766e6 | 2021-06-14 13:24:19 -0700 | [diff] [blame] | 803 | } |
Yifan Hong | 1b6f12f | 2021-06-03 20:01:57 -0700 | [diff] [blame] | 804 | |
| 805 | cc_test_host { |
| 806 | name: "binderHostDeviceTest", |
| 807 | defaults: ["binder_test_defaults"], |
| 808 | srcs: ["binderHostDeviceTest.cpp"], |
| 809 | test_config: "binderHostDeviceTest.xml", |
| 810 | shared_libs: [ |
| 811 | "libbase", |
| 812 | "libbinder", |
| 813 | "liblog", |
| 814 | "libutils", |
| 815 | ], |
| 816 | static_libs: [ |
| 817 | "libgmock", |
| 818 | ], |
| 819 | target_required: [ |
| 820 | "binderHostDeviceTestService", |
| 821 | ], |
| 822 | test_suites: ["general-tests"], |
| 823 | target: { |
| 824 | darwin: { |
| 825 | enabled: false, |
| 826 | }, |
| 827 | }, |
| 828 | test_options: { |
| 829 | unit_test: false, |
| 830 | }, |
| 831 | } |
| 832 | |
| 833 | cc_test { |
| 834 | name: "binderHostDeviceTestService", |
| 835 | // The binary is named differently from the module so that PushFilePreparer pushes the binary |
| 836 | // directly, not the test module directory. |
| 837 | stem: "binderHostDeviceTest-service", |
| 838 | defaults: ["binder_test_defaults"], |
| 839 | gtest: false, |
| 840 | auto_gen_config: false, |
| 841 | srcs: ["binderHostDeviceTestService.cpp"], |
| 842 | shared_libs: [ |
| 843 | "libbase", |
| 844 | "libbinder", |
| 845 | "liblog", |
| 846 | "libutils", |
| 847 | ], |
| 848 | test_suites: ["general-tests"], |
| 849 | } |
Pawan | f00fabb | 2022-08-04 17:56:18 +0000 | [diff] [blame] | 850 | |
| 851 | cc_defaults { |
| 852 | name: "service_fuzzer_defaults", |
| 853 | static_libs: [ |
| 854 | "libbase", |
| 855 | "libbinder_random_parcel", |
| 856 | "libcutils", |
| 857 | ], |
| 858 | target: { |
| 859 | android: { |
| 860 | shared_libs: [ |
| 861 | "libbinder_ndk", |
| 862 | "libbinder", |
| 863 | "libutils", |
| 864 | ], |
| 865 | }, |
| 866 | host: { |
| 867 | static_libs: [ |
| 868 | "libbinder_ndk", |
| 869 | "libbinder", |
| 870 | "libutils", |
| 871 | ], |
| 872 | }, |
| 873 | darwin: { |
| 874 | enabled: false, |
| 875 | }, |
| 876 | }, |
| 877 | fuzz_config: { |
| 878 | cc: [ |
| 879 | "smoreland@google.com", |
| 880 | "waghpawan@google.com", |
| 881 | ], |
Pawan Wagh | 595377b | 2022-11-16 08:42:20 +0000 | [diff] [blame] | 882 | // Adds bugs to hotlist "AIDL fuzzers bugs" on buganizer |
| 883 | hotlists: ["4637097"], |
Pawan Wagh | 813a06f | 2023-12-21 23:39:39 +0000 | [diff] [blame] | 884 | use_for_presubmit: true, |
Pawan | f00fabb | 2022-08-04 17:56:18 +0000 | [diff] [blame] | 885 | }, |
| 886 | } |
Pawan Wagh | 475f66c | 2023-05-05 21:46:07 +0000 | [diff] [blame] | 887 | |
| 888 | cc_defaults { |
| 889 | name: "fuzzer_disable_leaks", |
Pawan Wagh | 9e2d296 | 2023-06-20 23:43:24 +0000 | [diff] [blame] | 890 | fuzz_config: { |
| 891 | asan_options: [ |
| 892 | "detect_leaks=0", |
| 893 | ], |
| 894 | hwasan_options: [ |
| 895 | "detect_leaks=0", |
| 896 | ], |
| 897 | }, |
Pawan Wagh | 475f66c | 2023-05-05 21:46:07 +0000 | [diff] [blame] | 898 | } |