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