blob: 5db31873201fbfd3d6b1397e0dd195c745a2924e [file] [log] [blame]
Dan Willemsen59e086f2016-07-25 17:13:45 -07001//
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 Badour3c538232021-02-12 21:26:48 -080017package {
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 Hsiehd1acbbc2017-10-05 13:38:28 -070026cc_defaults {
27 name: "binder_test_defaults",
28 cflags: [
29 "-Wall",
30 "-Werror",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070031 ],
32}
33
Dan Willemsen59e086f2016-07-25 17:13:45 -070034cc_test {
Hsin-Yi Chen69295752017-06-07 18:05:05 +080035 name: "binderDriverInterfaceTest_IPC_32",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070036 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -070037 srcs: ["binderDriverInterfaceTest.cpp"],
Yifan Hong4e419d82021-04-26 11:32:56 -070038 header_libs: ["libbinder_headers"],
Hsin-Yi Chen69295752017-06-07 18:05:05 +080039 compile_multilib: "32",
Steven Morelandea7659e2022-02-03 00:04:06 +000040 multilib: {
41 lib32: {
42 suffix: "",
43 },
44 },
Hsin-Yi Chen69295752017-06-07 18:05:05 +080045 cflags: ["-DBINDER_IPC_32BIT=1"],
Steven Morelandf9f3de22020-05-06 17:14:39 -070046 test_suites: ["vts"],
Hsin-Yi Chen69295752017-06-07 18:05:05 +080047}
48
49cc_test {
Steven Morelandc7a30c82019-07-10 13:12:23 -070050 name: "binderDriverInterfaceTest",
51 defaults: ["binder_test_defaults"],
Dan Willemsen59e086f2016-07-25 17:13:45 -070052 product_variables: {
53 binder32bit: {
54 cflags: ["-DBINDER_IPC_32BIT=1"],
55 },
56 },
Yifan Hong4e419d82021-04-26 11:32:56 -070057 header_libs: ["libbinder_headers"],
Dan Willemsen59e086f2016-07-25 17:13:45 -070058 srcs: ["binderDriverInterfaceTest.cpp"],
Steven Morelandea7659e2022-02-03 00:04:06 +000059 test_suites: [
60 "device-tests",
61 "vts",
62 ],
Dan Willemsen59e086f2016-07-25 17:13:45 -070063}
64
65cc_test {
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080066 name: "binderLibTest_IPC_32",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070067 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -070068 srcs: ["binderLibTest.cpp"],
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080069 shared_libs: [
Yifan Hong84bedeb2021-04-21 21:37:17 -070070 "libbase",
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080071 "libbinder",
Yifan Hong8b890852021-06-10 13:44:09 -070072 "liblog",
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080073 "libutils",
74 ],
Yifan Hongbbd2a0d2021-05-07 22:12:23 -070075 static_libs: [
76 "libgmock",
77 ],
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080078 compile_multilib: "32",
Steven Morelandea7659e2022-02-03 00:04:06 +000079 multilib: {
80 lib32: {
81 suffix: "",
82 },
83 },
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080084 cflags: ["-DBINDER_IPC_32BIT=1"],
Steven Morelandf9f3de22020-05-06 17:14:39 -070085 test_suites: ["vts"],
86 require_root: true,
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080087}
88
Steven Morelandcefba612020-11-05 22:57:06 +000089// unit test only, which can run on host and doesn't use /dev/binder
90cc_test {
Steven Moreland28318602021-06-25 01:16:29 +000091 name: "binderUnitTest",
Steven Morelandcefba612020-11-05 22:57:06 +000092 host_supported: true,
93 target: {
94 darwin: {
95 enabled: false,
96 },
97 },
Steven Morelandea7659e2022-02-03 00:04:06 +000098 srcs: [
99 "binderParcelUnitTest.cpp",
100 "binderBinderUnitTest.cpp",
Steven Morelandcf373692022-01-21 23:55:15 +0000101 "binderStatusUnitTest.cpp",
Atneya Nair7ade4f42022-02-07 18:16:48 -0500102 "binderMemoryHeapBaseUnitTest.cpp",
Fabián Cañas08bdc772023-01-02 15:02:56 -0500103 "binderRecordedTransactionTest.cpp",
Steven Morelandea7659e2022-02-03 00:04:06 +0000104 ],
Steven Morelandcefba612020-11-05 22:57:06 +0000105 shared_libs: [
106 "libbinder",
Steven Morelandf80809b2021-10-07 18:09:20 -0700107 "libcutils",
Steven Morelandcefba612020-11-05 22:57:06 +0000108 "libutils",
109 ],
110 test_suites: ["general-tests"],
111}
112
Hsin-Yi Chenec18c022017-07-06 11:40:20 +0800113cc_test {
Steven Morelandc7a30c82019-07-10 13:12:23 -0700114 name: "binderLibTest",
115 defaults: ["binder_test_defaults"],
Hsin-Yi Chenec18c022017-07-06 11:40:20 +0800116 product_variables: {
117 binder32bit: {
118 cflags: ["-DBINDER_IPC_32BIT=1"],
119 },
120 },
121
Dan Willemsen59e086f2016-07-25 17:13:45 -0700122 srcs: ["binderLibTest.cpp"],
123 shared_libs: [
Yifan Hong84bedeb2021-04-21 21:37:17 -0700124 "libbase",
Dan Willemsen59e086f2016-07-25 17:13:45 -0700125 "libbinder",
Yifan Hong8b890852021-06-10 13:44:09 -0700126 "liblog",
Dan Willemsen59e086f2016-07-25 17:13:45 -0700127 "libutils",
128 ],
Yifan Hongbbd2a0d2021-05-07 22:12:23 -0700129 static_libs: [
130 "libgmock",
131 ],
Steven Morelandea7659e2022-02-03 00:04:06 +0000132 test_suites: [
133 "device-tests",
134 "vts",
135 ],
Dan Shi80ada592019-09-13 09:17:17 -0700136 require_root: true,
Dan Willemsen59e086f2016-07-25 17:13:45 -0700137}
138
Steven Moreland37aff182021-03-26 02:04:16 +0000139aidl_interface {
140 name: "binderRpcTestIface",
141 host_supported: true,
142 unstable: true,
143 srcs: [
Yifan Hong1deca4b2021-09-10 16:16:44 -0700144 "BinderRpcTestClientInfo.aidl",
Andrei Homescu2a298012022-06-15 01:08:54 +0000145 "BinderRpcTestServerConfig.aidl",
Yifan Hong1deca4b2021-09-10 16:16:44 -0700146 "BinderRpcTestServerInfo.aidl",
Steven Moreland659416d2021-05-11 00:47:50 +0000147 "IBinderRpcCallback.aidl",
Steven Moreland37aff182021-03-26 02:04:16 +0000148 "IBinderRpcSession.aidl",
149 "IBinderRpcTest.aidl",
Yifan Hong1deca4b2021-09-10 16:16:44 -0700150 "ParcelableCertificateData.aidl",
Steven Moreland37aff182021-03-26 02:04:16 +0000151 ],
152 backend: {
153 java: {
154 enabled: false,
155 },
156 },
157}
158
Yifan Honge0e53282021-09-23 18:37:21 -0700159cc_library_static {
160 name: "libbinder_tls_test_utils",
161 host_supported: true,
162 target: {
163 darwin: {
164 enabled: false,
165 },
166 },
167 defaults: [
168 "binder_test_defaults",
169 "libbinder_tls_shared_deps",
170 ],
171 shared_libs: [
Yifan Honge0e53282021-09-23 18:37:21 -0700172 "libbase",
173 "liblog",
174 ],
175 static_libs: [
176 "libbinder_tls_static",
177 ],
178 srcs: [
179 "RpcTlsTestUtils.cpp",
180 ],
181 export_include_dirs: [
182 "include_tls_test_utils",
183 ],
184 visibility: [
185 ":__subpackages__",
186 ],
187}
188
Andrei Homescu12106de2022-04-27 04:42:21 +0000189cc_defaults {
Andrei Homescu2a298012022-06-15 01:08:54 +0000190 name: "binderRpcTest_common_defaults",
Steven Morelandf6ec4632021-04-01 16:20:47 +0000191 host_supported: true,
192 target: {
193 darwin: {
194 enabled: false,
195 },
196 },
Steven Moreland37aff182021-03-26 02:04:16 +0000197 defaults: [
198 "binder_test_defaults",
Steven Moreland37aff182021-03-26 02:04:16 +0000199 ],
Steven Moreland5553ac42020-11-11 02:14:45 +0000200
Andrei Homescu12106de2022-04-27 04:42:21 +0000201 static_libs: [
202 "libbinder_tls_static",
203 "libbinder_tls_test_utils",
204 "binderRpcTestIface-cpp",
205 "binderRpcTestIface-ndk",
206 ],
Andrei Homescu2a298012022-06-15 01:08:54 +0000207}
208
209cc_defaults {
210 name: "binderRpcTest_service_defaults",
211 defaults: [
212 "binderRpcTest_common_defaults",
213 ],
214 gtest: false,
215 auto_gen_config: false,
216 srcs: [
217 "binderRpcTestCommon.cpp",
218 "binderRpcTestService.cpp",
219 ],
220}
221
222cc_defaults {
223 name: "binderRpcTest_defaults",
224 target: {
225 android: {
226 test_suites: ["vts"],
227 },
228 },
229 defaults: [
230 "binderRpcTest_common_defaults",
231 ],
232
233 srcs: [
234 "binderRpcTest.cpp",
235 "binderRpcTestCommon.cpp",
Andrei Homescu9a9b1b42022-10-14 01:40:59 +0000236 "binderRpcUniversalTests.cpp",
Andrei Homescu2a298012022-06-15 01:08:54 +0000237 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000238
239 test_suites: ["general-tests"],
240 require_root: true,
Andrei Homescu2a298012022-06-15 01:08:54 +0000241
242 data_bins: [
243 "binder_rpc_test_service",
244 "binder_rpc_test_service_no_kernel",
245 "binder_rpc_test_service_single_threaded",
246 "binder_rpc_test_service_single_threaded_no_kernel",
247 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000248}
249
Andrei Homescu2a298012022-06-15 01:08:54 +0000250cc_defaults {
251 name: "binderRpcTest_shared_defaults",
Andrei Homescu12106de2022-04-27 04:42:21 +0000252 cflags: [
253 "-DBINDER_WITH_KERNEL_IPC",
254 ],
255
Steven Moreland5553ac42020-11-11 02:14:45 +0000256 shared_libs: [
257 "libbinder",
Steven Moreland37aff182021-03-26 02:04:16 +0000258 "libbinder_ndk",
Steven Moreland5553ac42020-11-11 02:14:45 +0000259 "libbase",
260 "libutils",
261 "libcutils",
262 "liblog",
263 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000264}
265
266cc_defaults {
267 name: "binderRpcTest_static_defaults",
268
269 shared_libs: [
270 "libutils",
271 // libcrypto_static is not visible to this module
272 "libcrypto",
Steven Moreland37aff182021-03-26 02:04:16 +0000273 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000274 static_libs: [
275 "libbase",
276 "libcutils",
277 "liblog",
278 "libssl",
279 ],
280
281 cflags: [
282 // Disable tests that require shared libraries,
283 // e.g., libbinder.so or libbinder_ndk.so
284 "-DBINDER_TEST_NO_SHARED_LIBS",
285 ],
286}
287
288cc_test {
Andrei Homescu2a298012022-06-15 01:08:54 +0000289 // The module name cannot start with "binderRpcTest" because
290 // then atest tries to execute it as part of binderRpcTest
291 name: "binder_rpc_test_service",
292 defaults: [
293 "binderRpcTest_service_defaults",
294 "binderRpcTest_shared_defaults",
295 "libbinder_tls_shared_deps",
296 ],
297}
298
299cc_test {
300 name: "binder_rpc_test_service_no_kernel",
301 defaults: [
302 "binderRpcTest_service_defaults",
303 "binderRpcTest_static_defaults",
304 ],
305 static_libs: [
306 "libbinder_rpc_no_kernel",
307 ],
308}
309
310cc_test {
311 name: "binder_rpc_test_service_single_threaded",
312 defaults: [
313 "binderRpcTest_service_defaults",
314 "binderRpcTest_static_defaults",
315 ],
316 cflags: [
317 "-DBINDER_RPC_SINGLE_THREADED",
318 "-DBINDER_WITH_KERNEL_IPC",
319 ],
320 static_libs: [
321 "libbinder_rpc_single_threaded",
322 ],
323}
324
325cc_test {
326 name: "binder_rpc_test_service_single_threaded_no_kernel",
327 defaults: [
328 "binderRpcTest_service_defaults",
329 "binderRpcTest_static_defaults",
330 ],
331 cflags: [
332 "-DBINDER_RPC_SINGLE_THREADED",
333 ],
334 static_libs: [
335 "libbinder_rpc_single_threaded_no_kernel",
336 ],
337}
338
339cc_test {
340 name: "binderRpcTest",
341 defaults: [
342 "binderRpcTest_defaults",
343 "binderRpcTest_shared_defaults",
344 "libbinder_tls_shared_deps",
345 ],
Andrei Homescu875996f2022-08-24 04:25:11 +0000346
347 // Add the Trusty mock library as a fake dependency so it gets built
348 required: [
349 "libbinder_on_trusty_mock",
350 ],
Andrei Homescu2a298012022-06-15 01:08:54 +0000351}
352
353cc_test {
Andrei Homescu12106de2022-04-27 04:42:21 +0000354 name: "binderRpcTestNoKernel",
355 defaults: [
356 "binderRpcTest_defaults",
357 "binderRpcTest_static_defaults",
358 ],
359 static_libs: [
360 "libbinder_rpc_no_kernel",
361 ],
362}
363
364cc_test {
365 name: "binderRpcTestSingleThreaded",
366 defaults: [
367 "binderRpcTest_defaults",
368 "binderRpcTest_static_defaults",
369 ],
370 cflags: [
371 "-DBINDER_RPC_SINGLE_THREADED",
372 "-DBINDER_WITH_KERNEL_IPC",
373 ],
374 static_libs: [
375 "libbinder_rpc_single_threaded",
376 ],
377}
378
379cc_test {
380 name: "binderRpcTestSingleThreadedNoKernel",
381 defaults: [
382 "binderRpcTest_defaults",
383 "binderRpcTest_static_defaults",
384 ],
385 cflags: [
386 "-DBINDER_RPC_SINGLE_THREADED",
387 ],
388 static_libs: [
389 "libbinder_rpc_single_threaded_no_kernel",
390 ],
Steven Moreland5553ac42020-11-11 02:14:45 +0000391}
392
Yifan Hongff73aa92021-09-17 21:28:01 -0700393cc_test {
394 name: "RpcTlsUtilsTest",
395 host_supported: true,
396 target: {
397 darwin: {
398 enabled: false,
399 },
400 android: {
401 test_suites: ["vts"],
402 },
403 },
404 defaults: [
405 "binder_test_defaults",
406 "libbinder_tls_shared_deps",
407 ],
408 srcs: [
Yifan Hongff73aa92021-09-17 21:28:01 -0700409 "RpcTlsUtilsTest.cpp",
410 ],
411 shared_libs: [
412 "libbinder",
413 "libbase",
414 "libutils",
415 "liblog",
416 ],
417 static_libs: [
Yifan Honge0e53282021-09-23 18:37:21 -0700418 "libbinder_tls_test_utils",
Yifan Hongff73aa92021-09-17 21:28:01 -0700419 "libbinder_tls_static",
420 ],
Steven Morelandea7659e2022-02-03 00:04:06 +0000421 test_suites: [
422 "general-tests",
423 "device-tests",
424 ],
Yifan Hongff73aa92021-09-17 21:28:01 -0700425}
426
Steven Morelandcda60852021-04-14 23:45:32 +0000427cc_benchmark {
428 name: "binderRpcBenchmark",
Yifan Hongaecdd172021-09-21 14:53:13 -0700429 defaults: [
430 "binder_test_defaults",
431 "libbinder_tls_shared_deps",
432 ],
Steven Morelandcda60852021-04-14 23:45:32 +0000433 host_supported: true,
Steven Moreland722b4902021-04-16 16:30:18 +0000434 target: {
435 darwin: {
436 enabled: false,
437 },
438 },
Steven Morelandcda60852021-04-14 23:45:32 +0000439 srcs: [
440 "binderRpcBenchmark.cpp",
441 "IBinderRpcBenchmark.aidl",
442 ],
443 shared_libs: [
444 "libbase",
445 "libbinder",
446 "liblog",
447 "libutils",
448 ],
Yifan Hongaecdd172021-09-21 14:53:13 -0700449 static_libs: [
Yifan Honge0e53282021-09-23 18:37:21 -0700450 "libbinder_tls_test_utils",
Yifan Hongaecdd172021-09-21 14:53:13 -0700451 "libbinder_tls_static",
452 ],
Steven Morelandcda60852021-04-14 23:45:32 +0000453}
454
Steven Moreland5553ac42020-11-11 02:14:45 +0000455cc_test {
Steven Moreland59640db2021-07-22 17:19:31 -0700456 name: "binderRpcWireProtocolTest",
457 host_supported: true,
458 target: {
459 darwin: {
460 enabled: false,
461 },
462 android: {
463 test_suites: ["vts"],
464 },
465 },
466 defaults: [
467 "binder_test_defaults",
468 ],
469 srcs: [
470 "binderRpcWireProtocolTest.cpp",
471 ],
472 shared_libs: [
473 "libbinder",
474 "libbase",
475 "libutils",
476 "libcutils",
477 "liblog",
478 ],
479 test_suites: ["general-tests"],
480}
481
482cc_test {
Dan Willemsen59e086f2016-07-25 17:13:45 -0700483 name: "binderThroughputTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700484 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700485 srcs: ["binderThroughputTest.cpp"],
Dan Willemsen59e086f2016-07-25 17:13:45 -0700486 shared_libs: [
487 "libbinder",
488 "libutils",
489 ],
Dan Willemsen59e086f2016-07-25 17:13:45 -0700490 cflags: [
491 "-g",
Dan Willemsen59e086f2016-07-25 17:13:45 -0700492 "-Wno-missing-field-initializers",
493 "-Wno-sign-compare",
494 "-O3",
495 ],
496}
Wei Wang78f2a372016-10-20 23:18:17 -0700497
498cc_test {
499 name: "binderTextOutputTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700500 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700501 srcs: ["binderTextOutputTest.cpp"],
Wei Wang78f2a372016-10-20 23:18:17 -0700502 shared_libs: [
503 "libbinder",
504 "libutils",
505 "libbase",
506 ],
Steven Moreland67812c22019-07-10 13:50:40 -0700507 test_suites: ["device-tests"],
Wei Wang78f2a372016-10-20 23:18:17 -0700508}
Howard Chenc135dbc2017-03-25 17:12:59 +0800509
510cc_test {
511 name: "schd-dbg",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700512 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700513 srcs: ["schd-dbg.cpp"],
Howard Chenc135dbc2017-03-25 17:12:59 +0800514 shared_libs: [
515 "libbinder",
516 "libutils",
517 "libbase",
518 ],
519}
Dan Stozad630e522016-12-01 15:16:31 -0800520
521cc_test {
522 name: "binderSafeInterfaceTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700523 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700524 srcs: ["binderSafeInterfaceTest.cpp"],
Dan Stozad630e522016-12-01 15:16:31 -0800525
526 cppflags: [
Colin Cross1383d9f2019-11-06 13:33:40 -0800527 "-Wextra",
Dan Stozad630e522016-12-01 15:16:31 -0800528 ],
529
530 cpp_std: "experimental",
531 gnu_extensions: false,
532
533 shared_libs: [
534 "libbinder",
Dan Stoza2537db72017-04-07 16:32:38 -0700535 "libcutils",
Dan Stozad630e522016-12-01 15:16:31 -0800536 "liblog",
537 "libutils",
538 ],
Steven Morelandea7659e2022-02-03 00:04:06 +0000539 test_suites: [
540 "device-tests",
541 "vts",
542 ],
Dan Shi80ada592019-09-13 09:17:17 -0700543 require_root: true,
Dan Stozad630e522016-12-01 15:16:31 -0800544}
Steven Morelanddea3cf92019-07-16 18:06:55 -0700545
Steven Morelandf23dae22020-10-27 19:34:55 +0000546cc_test {
547 name: "binderClearBufTest",
548 defaults: ["binder_test_defaults"],
549 srcs: [
550 "binderClearBufTest.cpp",
551 ],
552
553 shared_libs: [
554 "libbase",
555 "libbinder",
556 "liblog",
557 "libutils",
558 ],
559
560 test_suites: ["general-tests"],
561 require_root: true,
562}
563
Steven Moreland12300a02019-08-02 13:27:15 -0700564aidl_interface {
565 name: "binderStabilityTestIface",
Jiyong Park701fa1a2020-04-13 12:55:44 +0900566 unstable: true,
Steven Moreland12300a02019-08-02 13:27:15 -0700567 srcs: [
568 "IBinderStabilityTest.aidl",
Steven Moreland12300a02019-08-02 13:27:15 -0700569 ],
Steven Moreland37aff182021-03-26 02:04:16 +0000570 backend: {
571 java: {
572 enabled: false,
573 },
574 },
Steven Moreland12300a02019-08-02 13:27:15 -0700575}
576
Steven Morelanddea3cf92019-07-16 18:06:55 -0700577cc_test {
578 name: "binderStabilityTest",
579 defaults: ["binder_test_defaults"],
580 srcs: [
581 "binderStabilityTest.cpp",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700582 ],
583
Steven Moreland13f84662020-07-23 21:30:41 +0000584 // critical that libbinder/libbinder_ndk are shared for VTS
Steven Morelanddea3cf92019-07-16 18:06:55 -0700585 shared_libs: [
Steven Moreland12300a02019-08-02 13:27:15 -0700586 "libbinder_ndk",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700587 "libbinder",
Steven Moreland12300a02019-08-02 13:27:15 -0700588 "liblog",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700589 "libutils",
590 ],
Steven Moreland12300a02019-08-02 13:27:15 -0700591 static_libs: [
592 "binderStabilityTestIface-cpp",
Jiyong Park9a9427c2021-08-09 09:01:15 +0900593 "binderStabilityTestIface-ndk",
Steven Moreland12300a02019-08-02 13:27:15 -0700594 ],
595
Steven Morelandea7659e2022-02-03 00:04:06 +0000596 test_suites: [
597 "device-tests",
598 "vts",
599 ],
Dan Shi302709b2019-09-19 15:28:15 -0700600 require_root: true,
Steven Morelanddea3cf92019-07-16 18:06:55 -0700601}
Steven Moreland042ae822020-05-27 17:45:17 +0000602
603cc_test {
604 name: "binderAllocationLimits",
605 defaults: ["binder_test_defaults"],
606 srcs: ["binderAllocationLimits.cpp"],
607 shared_libs: [
608 "libbinder",
609 "liblog",
Steven Moreland66acefe2022-09-09 00:34:40 +0000610 "libcutils",
Steven Moreland042ae822020-05-27 17:45:17 +0000611 "libutils",
612 "libutilscallstack",
613 "libbase",
614 ],
615 test_suites: ["device-tests"],
616 require_root: true,
617}
Andy Hung73a14702020-11-24 13:04:46 -0800618
619cc_benchmark {
620 name: "binderParcelBenchmark",
621 defaults: ["binder_test_defaults"],
622 srcs: ["binderParcelBenchmark.cpp"],
623 shared_libs: [
624 "libbase",
625 "libbinder",
626 "liblog",
627 "libutils",
628 ],
629}
Yifan Hongaf766e62021-06-14 13:24:19 -0700630
631cc_test_host {
632 name: "binderUtilsHostTest",
633 defaults: ["binder_test_defaults"],
634 srcs: ["binderUtilsHostTest.cpp"],
635 shared_libs: [
636 "libbase",
637 "libbinder",
638 ],
639 static_libs: [
640 "libgmock",
641 ],
642 test_suites: ["general-tests"],
Yifan Hong44dec542021-06-22 10:47:44 -0700643 target: {
644 darwin: {
645 enabled: false,
646 },
647 },
Yifan Hongaf766e62021-06-14 13:24:19 -0700648}
Yifan Hong1b6f12f2021-06-03 20:01:57 -0700649
650cc_test_host {
651 name: "binderHostDeviceTest",
652 defaults: ["binder_test_defaults"],
653 srcs: ["binderHostDeviceTest.cpp"],
654 test_config: "binderHostDeviceTest.xml",
655 shared_libs: [
656 "libbase",
657 "libbinder",
658 "liblog",
659 "libutils",
660 ],
661 static_libs: [
662 "libgmock",
663 ],
664 target_required: [
665 "binderHostDeviceTestService",
666 ],
667 test_suites: ["general-tests"],
668 target: {
669 darwin: {
670 enabled: false,
671 },
672 },
673 test_options: {
674 unit_test: false,
675 },
676}
677
678cc_test {
679 name: "binderHostDeviceTestService",
680 // The binary is named differently from the module so that PushFilePreparer pushes the binary
681 // directly, not the test module directory.
682 stem: "binderHostDeviceTest-service",
683 defaults: ["binder_test_defaults"],
684 gtest: false,
685 auto_gen_config: false,
686 srcs: ["binderHostDeviceTestService.cpp"],
687 shared_libs: [
688 "libbase",
689 "libbinder",
690 "liblog",
691 "libutils",
692 ],
693 test_suites: ["general-tests"],
694}
Pawanf00fabb2022-08-04 17:56:18 +0000695
696cc_defaults {
697 name: "service_fuzzer_defaults",
698 static_libs: [
699 "libbase",
700 "libbinder_random_parcel",
701 "libcutils",
702 ],
703 target: {
704 android: {
705 shared_libs: [
706 "libbinder_ndk",
707 "libbinder",
708 "libutils",
709 ],
710 },
711 host: {
712 static_libs: [
713 "libbinder_ndk",
714 "libbinder",
715 "libutils",
716 ],
717 },
718 darwin: {
719 enabled: false,
720 },
721 },
722 fuzz_config: {
723 cc: [
724 "smoreland@google.com",
725 "waghpawan@google.com",
726 ],
Pawan Wagh595377b2022-11-16 08:42:20 +0000727 // Adds bugs to hotlist "AIDL fuzzers bugs" on buganizer
728 hotlists: ["4637097"],
Pawanf00fabb2022-08-04 17:56:18 +0000729 },
730}