blob: a999d59d358bf76c8c9e3bcbe29cd6d674b3ea03 [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",
Steven Morelandea7659e2022-02-03 00:04:06 +0000103 ],
Steven Morelandcefba612020-11-05 22:57:06 +0000104 shared_libs: [
105 "libbinder",
Steven Morelandf80809b2021-10-07 18:09:20 -0700106 "libcutils",
Steven Morelandcefba612020-11-05 22:57:06 +0000107 "libutils",
108 ],
109 test_suites: ["general-tests"],
110}
111
Hsin-Yi Chenec18c022017-07-06 11:40:20 +0800112cc_test {
Steven Morelandc7a30c82019-07-10 13:12:23 -0700113 name: "binderLibTest",
114 defaults: ["binder_test_defaults"],
Hsin-Yi Chenec18c022017-07-06 11:40:20 +0800115 product_variables: {
116 binder32bit: {
117 cflags: ["-DBINDER_IPC_32BIT=1"],
118 },
119 },
120
Dan Willemsen59e086f2016-07-25 17:13:45 -0700121 srcs: ["binderLibTest.cpp"],
122 shared_libs: [
Yifan Hong84bedeb2021-04-21 21:37:17 -0700123 "libbase",
Dan Willemsen59e086f2016-07-25 17:13:45 -0700124 "libbinder",
Yifan Hong8b890852021-06-10 13:44:09 -0700125 "liblog",
Dan Willemsen59e086f2016-07-25 17:13:45 -0700126 "libutils",
127 ],
Yifan Hongbbd2a0d2021-05-07 22:12:23 -0700128 static_libs: [
129 "libgmock",
130 ],
Steven Morelandea7659e2022-02-03 00:04:06 +0000131 test_suites: [
132 "device-tests",
133 "vts",
134 ],
Dan Shi80ada592019-09-13 09:17:17 -0700135 require_root: true,
Dan Willemsen59e086f2016-07-25 17:13:45 -0700136}
137
Steven Moreland37aff182021-03-26 02:04:16 +0000138aidl_interface {
139 name: "binderRpcTestIface",
140 host_supported: true,
141 unstable: true,
142 srcs: [
Yifan Hong1deca4b2021-09-10 16:16:44 -0700143 "BinderRpcTestClientInfo.aidl",
Andrei Homescu2a298012022-06-15 01:08:54 +0000144 "BinderRpcTestServerConfig.aidl",
Yifan Hong1deca4b2021-09-10 16:16:44 -0700145 "BinderRpcTestServerInfo.aidl",
Steven Moreland659416d2021-05-11 00:47:50 +0000146 "IBinderRpcCallback.aidl",
Steven Moreland37aff182021-03-26 02:04:16 +0000147 "IBinderRpcSession.aidl",
148 "IBinderRpcTest.aidl",
Yifan Hong1deca4b2021-09-10 16:16:44 -0700149 "ParcelableCertificateData.aidl",
Steven Moreland37aff182021-03-26 02:04:16 +0000150 ],
151 backend: {
152 java: {
153 enabled: false,
154 },
155 },
156}
157
Yifan Honge0e53282021-09-23 18:37:21 -0700158cc_library_static {
159 name: "libbinder_tls_test_utils",
160 host_supported: true,
161 target: {
162 darwin: {
163 enabled: false,
164 },
165 },
166 defaults: [
167 "binder_test_defaults",
168 "libbinder_tls_shared_deps",
169 ],
170 shared_libs: [
Yifan Honge0e53282021-09-23 18:37:21 -0700171 "libbase",
172 "liblog",
173 ],
174 static_libs: [
175 "libbinder_tls_static",
176 ],
177 srcs: [
178 "RpcTlsTestUtils.cpp",
179 ],
180 export_include_dirs: [
181 "include_tls_test_utils",
182 ],
183 visibility: [
184 ":__subpackages__",
185 ],
186}
187
Andrei Homescu12106de2022-04-27 04:42:21 +0000188cc_defaults {
Andrei Homescu2a298012022-06-15 01:08:54 +0000189 name: "binderRpcTest_common_defaults",
Steven Morelandf6ec4632021-04-01 16:20:47 +0000190 host_supported: true,
191 target: {
192 darwin: {
193 enabled: false,
194 },
195 },
Steven Moreland37aff182021-03-26 02:04:16 +0000196 defaults: [
197 "binder_test_defaults",
Steven Moreland37aff182021-03-26 02:04:16 +0000198 ],
Steven Moreland5553ac42020-11-11 02:14:45 +0000199
Andrei Homescu12106de2022-04-27 04:42:21 +0000200 static_libs: [
201 "libbinder_tls_static",
202 "libbinder_tls_test_utils",
203 "binderRpcTestIface-cpp",
204 "binderRpcTestIface-ndk",
205 ],
Andrei Homescu2a298012022-06-15 01:08:54 +0000206}
207
208cc_defaults {
209 name: "binderRpcTest_service_defaults",
210 defaults: [
211 "binderRpcTest_common_defaults",
212 ],
213 gtest: false,
214 auto_gen_config: false,
215 srcs: [
216 "binderRpcTestCommon.cpp",
217 "binderRpcTestService.cpp",
218 ],
219}
220
221cc_defaults {
222 name: "binderRpcTest_defaults",
223 target: {
224 android: {
225 test_suites: ["vts"],
226 },
227 },
228 defaults: [
229 "binderRpcTest_common_defaults",
230 ],
231
232 srcs: [
233 "binderRpcTest.cpp",
234 "binderRpcTestCommon.cpp",
Andrei Homescu9a9b1b42022-10-14 01:40:59 +0000235 "binderRpcUniversalTests.cpp",
Andrei Homescu2a298012022-06-15 01:08:54 +0000236 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000237
238 test_suites: ["general-tests"],
239 require_root: true,
Andrei Homescu2a298012022-06-15 01:08:54 +0000240
241 data_bins: [
242 "binder_rpc_test_service",
243 "binder_rpc_test_service_no_kernel",
244 "binder_rpc_test_service_single_threaded",
245 "binder_rpc_test_service_single_threaded_no_kernel",
246 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000247}
248
Andrei Homescu2a298012022-06-15 01:08:54 +0000249cc_defaults {
250 name: "binderRpcTest_shared_defaults",
Andrei Homescu12106de2022-04-27 04:42:21 +0000251 cflags: [
252 "-DBINDER_WITH_KERNEL_IPC",
253 ],
254
Steven Moreland5553ac42020-11-11 02:14:45 +0000255 shared_libs: [
256 "libbinder",
Steven Moreland37aff182021-03-26 02:04:16 +0000257 "libbinder_ndk",
Steven Moreland5553ac42020-11-11 02:14:45 +0000258 "libbase",
259 "libutils",
260 "libcutils",
261 "liblog",
262 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000263}
264
265cc_defaults {
266 name: "binderRpcTest_static_defaults",
267
268 shared_libs: [
269 "libutils",
270 // libcrypto_static is not visible to this module
271 "libcrypto",
Steven Moreland37aff182021-03-26 02:04:16 +0000272 ],
Andrei Homescu12106de2022-04-27 04:42:21 +0000273 static_libs: [
274 "libbase",
275 "libcutils",
276 "liblog",
277 "libssl",
278 ],
279
280 cflags: [
281 // Disable tests that require shared libraries,
282 // e.g., libbinder.so or libbinder_ndk.so
283 "-DBINDER_TEST_NO_SHARED_LIBS",
284 ],
285}
286
287cc_test {
Andrei Homescu2a298012022-06-15 01:08:54 +0000288 // The module name cannot start with "binderRpcTest" because
289 // then atest tries to execute it as part of binderRpcTest
290 name: "binder_rpc_test_service",
291 defaults: [
292 "binderRpcTest_service_defaults",
293 "binderRpcTest_shared_defaults",
294 "libbinder_tls_shared_deps",
295 ],
296}
297
298cc_test {
299 name: "binder_rpc_test_service_no_kernel",
300 defaults: [
301 "binderRpcTest_service_defaults",
302 "binderRpcTest_static_defaults",
303 ],
304 static_libs: [
305 "libbinder_rpc_no_kernel",
306 ],
307}
308
309cc_test {
310 name: "binder_rpc_test_service_single_threaded",
311 defaults: [
312 "binderRpcTest_service_defaults",
313 "binderRpcTest_static_defaults",
314 ],
315 cflags: [
316 "-DBINDER_RPC_SINGLE_THREADED",
317 "-DBINDER_WITH_KERNEL_IPC",
318 ],
319 static_libs: [
320 "libbinder_rpc_single_threaded",
321 ],
322}
323
324cc_test {
325 name: "binder_rpc_test_service_single_threaded_no_kernel",
326 defaults: [
327 "binderRpcTest_service_defaults",
328 "binderRpcTest_static_defaults",
329 ],
330 cflags: [
331 "-DBINDER_RPC_SINGLE_THREADED",
332 ],
333 static_libs: [
334 "libbinder_rpc_single_threaded_no_kernel",
335 ],
336}
337
338cc_test {
339 name: "binderRpcTest",
340 defaults: [
341 "binderRpcTest_defaults",
342 "binderRpcTest_shared_defaults",
343 "libbinder_tls_shared_deps",
344 ],
Andrei Homescu875996f2022-08-24 04:25:11 +0000345
346 // Add the Trusty mock library as a fake dependency so it gets built
347 required: [
348 "libbinder_on_trusty_mock",
349 ],
Andrei Homescu2a298012022-06-15 01:08:54 +0000350}
351
352cc_test {
Andrei Homescu12106de2022-04-27 04:42:21 +0000353 name: "binderRpcTestNoKernel",
354 defaults: [
355 "binderRpcTest_defaults",
356 "binderRpcTest_static_defaults",
357 ],
358 static_libs: [
359 "libbinder_rpc_no_kernel",
360 ],
361}
362
363cc_test {
364 name: "binderRpcTestSingleThreaded",
365 defaults: [
366 "binderRpcTest_defaults",
367 "binderRpcTest_static_defaults",
368 ],
369 cflags: [
370 "-DBINDER_RPC_SINGLE_THREADED",
371 "-DBINDER_WITH_KERNEL_IPC",
372 ],
373 static_libs: [
374 "libbinder_rpc_single_threaded",
375 ],
376}
377
378cc_test {
379 name: "binderRpcTestSingleThreadedNoKernel",
380 defaults: [
381 "binderRpcTest_defaults",
382 "binderRpcTest_static_defaults",
383 ],
384 cflags: [
385 "-DBINDER_RPC_SINGLE_THREADED",
386 ],
387 static_libs: [
388 "libbinder_rpc_single_threaded_no_kernel",
389 ],
Steven Moreland5553ac42020-11-11 02:14:45 +0000390}
391
Yifan Hongff73aa92021-09-17 21:28:01 -0700392cc_test {
393 name: "RpcTlsUtilsTest",
394 host_supported: true,
395 target: {
396 darwin: {
397 enabled: false,
398 },
399 android: {
400 test_suites: ["vts"],
401 },
402 },
403 defaults: [
404 "binder_test_defaults",
405 "libbinder_tls_shared_deps",
406 ],
407 srcs: [
Yifan Hongff73aa92021-09-17 21:28:01 -0700408 "RpcTlsUtilsTest.cpp",
409 ],
410 shared_libs: [
411 "libbinder",
412 "libbase",
413 "libutils",
414 "liblog",
415 ],
416 static_libs: [
Yifan Honge0e53282021-09-23 18:37:21 -0700417 "libbinder_tls_test_utils",
Yifan Hongff73aa92021-09-17 21:28:01 -0700418 "libbinder_tls_static",
419 ],
Steven Morelandea7659e2022-02-03 00:04:06 +0000420 test_suites: [
421 "general-tests",
422 "device-tests",
423 ],
Yifan Hongff73aa92021-09-17 21:28:01 -0700424}
425
Steven Morelandcda60852021-04-14 23:45:32 +0000426cc_benchmark {
427 name: "binderRpcBenchmark",
Yifan Hongaecdd172021-09-21 14:53:13 -0700428 defaults: [
429 "binder_test_defaults",
430 "libbinder_tls_shared_deps",
431 ],
Steven Morelandcda60852021-04-14 23:45:32 +0000432 host_supported: true,
Steven Moreland722b4902021-04-16 16:30:18 +0000433 target: {
434 darwin: {
435 enabled: false,
436 },
437 },
Steven Morelandcda60852021-04-14 23:45:32 +0000438 srcs: [
439 "binderRpcBenchmark.cpp",
440 "IBinderRpcBenchmark.aidl",
441 ],
442 shared_libs: [
443 "libbase",
444 "libbinder",
445 "liblog",
446 "libutils",
447 ],
Yifan Hongaecdd172021-09-21 14:53:13 -0700448 static_libs: [
Yifan Honge0e53282021-09-23 18:37:21 -0700449 "libbinder_tls_test_utils",
Yifan Hongaecdd172021-09-21 14:53:13 -0700450 "libbinder_tls_static",
451 ],
Steven Morelandcda60852021-04-14 23:45:32 +0000452}
453
Steven Moreland5553ac42020-11-11 02:14:45 +0000454cc_test {
Steven Moreland59640db2021-07-22 17:19:31 -0700455 name: "binderRpcWireProtocolTest",
456 host_supported: true,
457 target: {
458 darwin: {
459 enabled: false,
460 },
461 android: {
462 test_suites: ["vts"],
463 },
464 },
465 defaults: [
466 "binder_test_defaults",
467 ],
468 srcs: [
469 "binderRpcWireProtocolTest.cpp",
470 ],
471 shared_libs: [
472 "libbinder",
473 "libbase",
474 "libutils",
475 "libcutils",
476 "liblog",
477 ],
478 test_suites: ["general-tests"],
479}
480
481cc_test {
Dan Willemsen59e086f2016-07-25 17:13:45 -0700482 name: "binderThroughputTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700483 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700484 srcs: ["binderThroughputTest.cpp"],
Dan Willemsen59e086f2016-07-25 17:13:45 -0700485 shared_libs: [
486 "libbinder",
487 "libutils",
488 ],
Dan Willemsen59e086f2016-07-25 17:13:45 -0700489 cflags: [
490 "-g",
Dan Willemsen59e086f2016-07-25 17:13:45 -0700491 "-Wno-missing-field-initializers",
492 "-Wno-sign-compare",
493 "-O3",
494 ],
495}
Wei Wang78f2a372016-10-20 23:18:17 -0700496
497cc_test {
498 name: "binderTextOutputTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700499 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700500 srcs: ["binderTextOutputTest.cpp"],
Wei Wang78f2a372016-10-20 23:18:17 -0700501 shared_libs: [
502 "libbinder",
503 "libutils",
504 "libbase",
505 ],
Steven Moreland67812c22019-07-10 13:50:40 -0700506 test_suites: ["device-tests"],
Wei Wang78f2a372016-10-20 23:18:17 -0700507}
Howard Chenc135dbc2017-03-25 17:12:59 +0800508
509cc_test {
510 name: "schd-dbg",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700511 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700512 srcs: ["schd-dbg.cpp"],
Howard Chenc135dbc2017-03-25 17:12:59 +0800513 shared_libs: [
514 "libbinder",
515 "libutils",
516 "libbase",
517 ],
518}
Dan Stozad630e522016-12-01 15:16:31 -0800519
520cc_test {
521 name: "binderSafeInterfaceTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700522 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700523 srcs: ["binderSafeInterfaceTest.cpp"],
Dan Stozad630e522016-12-01 15:16:31 -0800524
525 cppflags: [
Colin Cross1383d9f2019-11-06 13:33:40 -0800526 "-Wextra",
Dan Stozad630e522016-12-01 15:16:31 -0800527 ],
528
529 cpp_std: "experimental",
530 gnu_extensions: false,
531
532 shared_libs: [
533 "libbinder",
Dan Stoza2537db72017-04-07 16:32:38 -0700534 "libcutils",
Dan Stozad630e522016-12-01 15:16:31 -0800535 "liblog",
536 "libutils",
537 ],
Steven Morelandea7659e2022-02-03 00:04:06 +0000538 test_suites: [
539 "device-tests",
540 "vts",
541 ],
Dan Shi80ada592019-09-13 09:17:17 -0700542 require_root: true,
Dan Stozad630e522016-12-01 15:16:31 -0800543}
Steven Morelanddea3cf92019-07-16 18:06:55 -0700544
Steven Morelandf23dae22020-10-27 19:34:55 +0000545cc_test {
546 name: "binderClearBufTest",
547 defaults: ["binder_test_defaults"],
548 srcs: [
549 "binderClearBufTest.cpp",
550 ],
551
552 shared_libs: [
553 "libbase",
554 "libbinder",
555 "liblog",
556 "libutils",
557 ],
558
559 test_suites: ["general-tests"],
560 require_root: true,
561}
562
Steven Moreland12300a02019-08-02 13:27:15 -0700563aidl_interface {
564 name: "binderStabilityTestIface",
Jiyong Park701fa1a2020-04-13 12:55:44 +0900565 unstable: true,
Steven Moreland12300a02019-08-02 13:27:15 -0700566 srcs: [
567 "IBinderStabilityTest.aidl",
Steven Moreland12300a02019-08-02 13:27:15 -0700568 ],
Steven Moreland37aff182021-03-26 02:04:16 +0000569 backend: {
570 java: {
571 enabled: false,
572 },
573 },
Steven Moreland12300a02019-08-02 13:27:15 -0700574}
575
Steven Morelanddea3cf92019-07-16 18:06:55 -0700576cc_test {
577 name: "binderStabilityTest",
578 defaults: ["binder_test_defaults"],
579 srcs: [
580 "binderStabilityTest.cpp",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700581 ],
582
Steven Moreland13f84662020-07-23 21:30:41 +0000583 // critical that libbinder/libbinder_ndk are shared for VTS
Steven Morelanddea3cf92019-07-16 18:06:55 -0700584 shared_libs: [
Steven Moreland12300a02019-08-02 13:27:15 -0700585 "libbinder_ndk",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700586 "libbinder",
Steven Moreland12300a02019-08-02 13:27:15 -0700587 "liblog",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700588 "libutils",
589 ],
Steven Moreland12300a02019-08-02 13:27:15 -0700590 static_libs: [
591 "binderStabilityTestIface-cpp",
Jiyong Park9a9427c2021-08-09 09:01:15 +0900592 "binderStabilityTestIface-ndk",
Steven Moreland12300a02019-08-02 13:27:15 -0700593 ],
594
Steven Morelandea7659e2022-02-03 00:04:06 +0000595 test_suites: [
596 "device-tests",
597 "vts",
598 ],
Dan Shi302709b2019-09-19 15:28:15 -0700599 require_root: true,
Steven Morelanddea3cf92019-07-16 18:06:55 -0700600}
Steven Moreland042ae822020-05-27 17:45:17 +0000601
602cc_test {
603 name: "binderAllocationLimits",
604 defaults: ["binder_test_defaults"],
605 srcs: ["binderAllocationLimits.cpp"],
606 shared_libs: [
607 "libbinder",
608 "liblog",
Steven Moreland66acefe2022-09-09 00:34:40 +0000609 "libcutils",
Steven Moreland042ae822020-05-27 17:45:17 +0000610 "libutils",
611 "libutilscallstack",
612 "libbase",
613 ],
614 test_suites: ["device-tests"],
615 require_root: true,
616}
Andy Hung73a14702020-11-24 13:04:46 -0800617
618cc_benchmark {
619 name: "binderParcelBenchmark",
620 defaults: ["binder_test_defaults"],
621 srcs: ["binderParcelBenchmark.cpp"],
622 shared_libs: [
623 "libbase",
624 "libbinder",
625 "liblog",
626 "libutils",
627 ],
628}
Yifan Hongaf766e62021-06-14 13:24:19 -0700629
630cc_test_host {
631 name: "binderUtilsHostTest",
632 defaults: ["binder_test_defaults"],
633 srcs: ["binderUtilsHostTest.cpp"],
634 shared_libs: [
635 "libbase",
636 "libbinder",
637 ],
638 static_libs: [
639 "libgmock",
640 ],
641 test_suites: ["general-tests"],
Yifan Hong44dec542021-06-22 10:47:44 -0700642 target: {
643 darwin: {
644 enabled: false,
645 },
646 },
Yifan Hongaf766e62021-06-14 13:24:19 -0700647}
Yifan Hong1b6f12f2021-06-03 20:01:57 -0700648
649cc_test_host {
650 name: "binderHostDeviceTest",
651 defaults: ["binder_test_defaults"],
652 srcs: ["binderHostDeviceTest.cpp"],
653 test_config: "binderHostDeviceTest.xml",
654 shared_libs: [
655 "libbase",
656 "libbinder",
657 "liblog",
658 "libutils",
659 ],
660 static_libs: [
661 "libgmock",
662 ],
663 target_required: [
664 "binderHostDeviceTestService",
665 ],
666 test_suites: ["general-tests"],
667 target: {
668 darwin: {
669 enabled: false,
670 },
671 },
672 test_options: {
673 unit_test: false,
674 },
675}
676
677cc_test {
678 name: "binderHostDeviceTestService",
679 // The binary is named differently from the module so that PushFilePreparer pushes the binary
680 // directly, not the test module directory.
681 stem: "binderHostDeviceTest-service",
682 defaults: ["binder_test_defaults"],
683 gtest: false,
684 auto_gen_config: false,
685 srcs: ["binderHostDeviceTestService.cpp"],
686 shared_libs: [
687 "libbase",
688 "libbinder",
689 "liblog",
690 "libutils",
691 ],
692 test_suites: ["general-tests"],
693}
Pawanf00fabb2022-08-04 17:56:18 +0000694
695cc_defaults {
696 name: "service_fuzzer_defaults",
697 static_libs: [
698 "libbase",
699 "libbinder_random_parcel",
700 "libcutils",
701 ],
702 target: {
703 android: {
704 shared_libs: [
705 "libbinder_ndk",
706 "libbinder",
707 "libutils",
708 ],
709 },
710 host: {
711 static_libs: [
712 "libbinder_ndk",
713 "libbinder",
714 "libutils",
715 ],
716 },
717 darwin: {
718 enabled: false,
719 },
720 },
721 fuzz_config: {
722 cc: [
723 "smoreland@google.com",
724 "waghpawan@google.com",
725 ],
Pawan Wagh595377b2022-11-16 08:42:20 +0000726 // Adds bugs to hotlist "AIDL fuzzers bugs" on buganizer
727 hotlists: ["4637097"],
Pawanf00fabb2022-08-04 17:56:18 +0000728 },
729}