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", |
| 28 | cflags: [ |
| 29 | "-Wall", |
| 30 | "-Werror", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 31 | ], |
| 32 | } |
| 33 | |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 34 | cc_test { |
Hsin-Yi Chen | 6929575 | 2017-06-07 18:05:05 +0800 | [diff] [blame] | 35 | name: "binderDriverInterfaceTest_IPC_32", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 36 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 37 | srcs: ["binderDriverInterfaceTest.cpp"], |
Yifan Hong | 4e419d8 | 2021-04-26 11:32:56 -0700 | [diff] [blame] | 38 | header_libs: ["libbinder_headers"], |
Hsin-Yi Chen | 6929575 | 2017-06-07 18:05:05 +0800 | [diff] [blame] | 39 | compile_multilib: "32", |
Steven Moreland | f9f3de2 | 2020-05-06 17:14:39 -0700 | [diff] [blame] | 40 | multilib: { lib32: { suffix: "" } }, |
Hsin-Yi Chen | 6929575 | 2017-06-07 18:05:05 +0800 | [diff] [blame] | 41 | cflags: ["-DBINDER_IPC_32BIT=1"], |
Steven Moreland | f9f3de2 | 2020-05-06 17:14:39 -0700 | [diff] [blame] | 42 | test_suites: ["vts"], |
Hsin-Yi Chen | 6929575 | 2017-06-07 18:05:05 +0800 | [diff] [blame] | 43 | } |
| 44 | |
| 45 | cc_test { |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 46 | name: "binderDriverInterfaceTest", |
| 47 | defaults: ["binder_test_defaults"], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 48 | product_variables: { |
| 49 | binder32bit: { |
| 50 | cflags: ["-DBINDER_IPC_32BIT=1"], |
| 51 | }, |
| 52 | }, |
Yifan Hong | 4e419d8 | 2021-04-26 11:32:56 -0700 | [diff] [blame] | 53 | header_libs: ["libbinder_headers"], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 54 | srcs: ["binderDriverInterfaceTest.cpp"], |
Dan Shi | eb25b67 | 2020-03-26 11:43:04 -0700 | [diff] [blame] | 55 | test_suites: ["device-tests", "vts"], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 56 | } |
| 57 | |
| 58 | cc_test { |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 59 | name: "binderLibTest_IPC_32", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 60 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 61 | srcs: ["binderLibTest.cpp"], |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 62 | shared_libs: [ |
Yifan Hong | 84bedeb | 2021-04-21 21:37:17 -0700 | [diff] [blame] | 63 | "libbase", |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 64 | "libbinder", |
Yifan Hong | 8b89085 | 2021-06-10 13:44:09 -0700 | [diff] [blame] | 65 | "liblog", |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 66 | "libutils", |
| 67 | ], |
Yifan Hong | bbd2a0d | 2021-05-07 22:12:23 -0700 | [diff] [blame] | 68 | static_libs: [ |
| 69 | "libgmock", |
| 70 | ], |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 71 | compile_multilib: "32", |
Steven Moreland | f9f3de2 | 2020-05-06 17:14:39 -0700 | [diff] [blame] | 72 | multilib: { lib32: { suffix: "" } }, |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 73 | cflags: ["-DBINDER_IPC_32BIT=1"], |
Steven Moreland | f9f3de2 | 2020-05-06 17:14:39 -0700 | [diff] [blame] | 74 | test_suites: ["vts"], |
| 75 | require_root: true, |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 76 | } |
| 77 | |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 78 | // unit test only, which can run on host and doesn't use /dev/binder |
| 79 | cc_test { |
Steven Moreland | 2831860 | 2021-06-25 01:16:29 +0000 | [diff] [blame] | 80 | name: "binderUnitTest", |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 81 | host_supported: true, |
| 82 | target: { |
| 83 | darwin: { |
| 84 | enabled: false, |
| 85 | }, |
| 86 | }, |
Steven Moreland | 63a2d51 | 2021-06-25 01:10:15 +0000 | [diff] [blame] | 87 | srcs: ["binderParcelUnitTest.cpp", "binderBinderUnitTest.cpp"], |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 88 | shared_libs: [ |
| 89 | "libbinder", |
Steven Moreland | f80809b | 2021-10-07 18:09:20 -0700 | [diff] [blame^] | 90 | "libcutils", |
Steven Moreland | cefba61 | 2020-11-05 22:57:06 +0000 | [diff] [blame] | 91 | "libutils", |
| 92 | ], |
| 93 | test_suites: ["general-tests"], |
| 94 | } |
| 95 | |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 96 | cc_test { |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 97 | name: "binderLibTest", |
| 98 | defaults: ["binder_test_defaults"], |
Hsin-Yi Chen | ec18c02 | 2017-07-06 11:40:20 +0800 | [diff] [blame] | 99 | product_variables: { |
| 100 | binder32bit: { |
| 101 | cflags: ["-DBINDER_IPC_32BIT=1"], |
| 102 | }, |
| 103 | }, |
| 104 | |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 105 | srcs: ["binderLibTest.cpp"], |
| 106 | shared_libs: [ |
Yifan Hong | 84bedeb | 2021-04-21 21:37:17 -0700 | [diff] [blame] | 107 | "libbase", |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 108 | "libbinder", |
Yifan Hong | 8b89085 | 2021-06-10 13:44:09 -0700 | [diff] [blame] | 109 | "liblog", |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 110 | "libutils", |
| 111 | ], |
Yifan Hong | bbd2a0d | 2021-05-07 22:12:23 -0700 | [diff] [blame] | 112 | static_libs: [ |
| 113 | "libgmock", |
| 114 | ], |
Dan Shi | eb25b67 | 2020-03-26 11:43:04 -0700 | [diff] [blame] | 115 | test_suites: ["device-tests", "vts"], |
Dan Shi | 80ada59 | 2019-09-13 09:17:17 -0700 | [diff] [blame] | 116 | require_root: true, |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 117 | } |
| 118 | |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 119 | aidl_interface { |
| 120 | name: "binderRpcTestIface", |
| 121 | host_supported: true, |
| 122 | unstable: true, |
| 123 | srcs: [ |
Yifan Hong | 1deca4b | 2021-09-10 16:16:44 -0700 | [diff] [blame] | 124 | "BinderRpcTestClientInfo.aidl", |
| 125 | "BinderRpcTestServerInfo.aidl", |
Steven Moreland | 659416d | 2021-05-11 00:47:50 +0000 | [diff] [blame] | 126 | "IBinderRpcCallback.aidl", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 127 | "IBinderRpcSession.aidl", |
| 128 | "IBinderRpcTest.aidl", |
Yifan Hong | 1deca4b | 2021-09-10 16:16:44 -0700 | [diff] [blame] | 129 | "ParcelableCertificateData.aidl", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 130 | ], |
| 131 | backend: { |
| 132 | java: { |
| 133 | enabled: false, |
| 134 | }, |
| 135 | }, |
| 136 | } |
| 137 | |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 138 | cc_library_static { |
| 139 | name: "libbinder_tls_test_utils", |
| 140 | host_supported: true, |
| 141 | target: { |
| 142 | darwin: { |
| 143 | enabled: false, |
| 144 | }, |
| 145 | }, |
| 146 | defaults: [ |
| 147 | "binder_test_defaults", |
| 148 | "libbinder_tls_shared_deps", |
| 149 | ], |
| 150 | shared_libs: [ |
| 151 | "libbinder", |
| 152 | "libbase", |
| 153 | "liblog", |
| 154 | ], |
| 155 | static_libs: [ |
| 156 | "libbinder_tls_static", |
| 157 | ], |
| 158 | srcs: [ |
| 159 | "RpcTlsTestUtils.cpp", |
| 160 | ], |
| 161 | export_include_dirs: [ |
| 162 | "include_tls_test_utils", |
| 163 | ], |
| 164 | visibility: [ |
| 165 | ":__subpackages__", |
| 166 | ], |
| 167 | } |
| 168 | |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 169 | cc_test { |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 170 | name: "binderRpcTest", |
Steven Moreland | f6ec463 | 2021-04-01 16:20:47 +0000 | [diff] [blame] | 171 | host_supported: true, |
| 172 | target: { |
| 173 | darwin: { |
| 174 | enabled: false, |
| 175 | }, |
Steven Moreland | 1d448af | 2021-04-20 01:05:18 +0000 | [diff] [blame] | 176 | android: { |
| 177 | test_suites: ["vts"], |
| 178 | }, |
Steven Moreland | f6ec463 | 2021-04-01 16:20:47 +0000 | [diff] [blame] | 179 | }, |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 180 | defaults: [ |
| 181 | "binder_test_defaults", |
| 182 | "libbinder_ndk_host_user", |
Yifan Hong | 9240975 | 2021-07-30 21:25:32 -0700 | [diff] [blame] | 183 | "libbinder_tls_shared_deps", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 184 | ], |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 185 | |
| 186 | srcs: [ |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 187 | "binderRpcTest.cpp", |
| 188 | ], |
| 189 | shared_libs: [ |
| 190 | "libbinder", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 191 | "libbinder_ndk", |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 192 | "libbase", |
| 193 | "libutils", |
| 194 | "libcutils", |
| 195 | "liblog", |
| 196 | ], |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 197 | static_libs: [ |
Yifan Hong | 9240975 | 2021-07-30 21:25:32 -0700 | [diff] [blame] | 198 | "libbinder_tls_static", |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 199 | "libbinder_tls_test_utils", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 200 | "binderRpcTestIface-cpp", |
Jiyong Park | 9a9427c | 2021-08-09 09:01:15 +0900 | [diff] [blame] | 201 | "binderRpcTestIface-ndk", |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 202 | ], |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 203 | test_suites: ["general-tests"], |
| 204 | require_root: true, |
| 205 | } |
| 206 | |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 207 | cc_test { |
| 208 | name: "RpcTlsUtilsTest", |
| 209 | host_supported: true, |
| 210 | target: { |
| 211 | darwin: { |
| 212 | enabled: false, |
| 213 | }, |
| 214 | android: { |
| 215 | test_suites: ["vts"], |
| 216 | }, |
| 217 | }, |
| 218 | defaults: [ |
| 219 | "binder_test_defaults", |
| 220 | "libbinder_tls_shared_deps", |
| 221 | ], |
| 222 | srcs: [ |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 223 | "RpcTlsUtilsTest.cpp", |
| 224 | ], |
| 225 | shared_libs: [ |
| 226 | "libbinder", |
| 227 | "libbase", |
| 228 | "libutils", |
| 229 | "liblog", |
| 230 | ], |
| 231 | static_libs: [ |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 232 | "libbinder_tls_test_utils", |
Yifan Hong | ff73aa9 | 2021-09-17 21:28:01 -0700 | [diff] [blame] | 233 | "libbinder_tls_static", |
| 234 | ], |
| 235 | test_suites: ["general-tests", "device-tests"], |
| 236 | } |
| 237 | |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 238 | cc_benchmark { |
| 239 | name: "binderRpcBenchmark", |
Yifan Hong | aecdd17 | 2021-09-21 14:53:13 -0700 | [diff] [blame] | 240 | defaults: [ |
| 241 | "binder_test_defaults", |
| 242 | "libbinder_tls_shared_deps", |
| 243 | ], |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 244 | host_supported: true, |
Steven Moreland | 722b490 | 2021-04-16 16:30:18 +0000 | [diff] [blame] | 245 | target: { |
| 246 | darwin: { |
| 247 | enabled: false, |
| 248 | }, |
| 249 | }, |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 250 | srcs: [ |
| 251 | "binderRpcBenchmark.cpp", |
| 252 | "IBinderRpcBenchmark.aidl", |
| 253 | ], |
| 254 | shared_libs: [ |
| 255 | "libbase", |
| 256 | "libbinder", |
| 257 | "liblog", |
| 258 | "libutils", |
| 259 | ], |
Yifan Hong | aecdd17 | 2021-09-21 14:53:13 -0700 | [diff] [blame] | 260 | static_libs: [ |
Yifan Hong | e0e5328 | 2021-09-23 18:37:21 -0700 | [diff] [blame] | 261 | "libbinder_tls_test_utils", |
Yifan Hong | aecdd17 | 2021-09-21 14:53:13 -0700 | [diff] [blame] | 262 | "libbinder_tls_static", |
| 263 | ], |
Steven Moreland | cda6085 | 2021-04-14 23:45:32 +0000 | [diff] [blame] | 264 | } |
| 265 | |
Steven Moreland | 5553ac4 | 2020-11-11 02:14:45 +0000 | [diff] [blame] | 266 | cc_test { |
Steven Moreland | 59640db | 2021-07-22 17:19:31 -0700 | [diff] [blame] | 267 | name: "binderRpcWireProtocolTest", |
| 268 | host_supported: true, |
| 269 | target: { |
| 270 | darwin: { |
| 271 | enabled: false, |
| 272 | }, |
| 273 | android: { |
| 274 | test_suites: ["vts"], |
| 275 | }, |
| 276 | }, |
| 277 | defaults: [ |
| 278 | "binder_test_defaults", |
| 279 | ], |
| 280 | srcs: [ |
| 281 | "binderRpcWireProtocolTest.cpp", |
| 282 | ], |
| 283 | shared_libs: [ |
| 284 | "libbinder", |
| 285 | "libbase", |
| 286 | "libutils", |
| 287 | "libcutils", |
| 288 | "liblog", |
| 289 | ], |
| 290 | test_suites: ["general-tests"], |
| 291 | } |
| 292 | |
| 293 | cc_test { |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 294 | name: "binderThroughputTest", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 295 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 296 | srcs: ["binderThroughputTest.cpp"], |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 297 | shared_libs: [ |
| 298 | "libbinder", |
| 299 | "libutils", |
| 300 | ], |
| 301 | clang: true, |
| 302 | cflags: [ |
| 303 | "-g", |
Dan Willemsen | 59e086f | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 304 | "-Wno-missing-field-initializers", |
| 305 | "-Wno-sign-compare", |
| 306 | "-O3", |
| 307 | ], |
| 308 | } |
Wei Wang | 78f2a37 | 2016-10-20 23:18:17 -0700 | [diff] [blame] | 309 | |
| 310 | cc_test { |
| 311 | name: "binderTextOutputTest", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 312 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 313 | srcs: ["binderTextOutputTest.cpp"], |
Wei Wang | 78f2a37 | 2016-10-20 23:18:17 -0700 | [diff] [blame] | 314 | shared_libs: [ |
| 315 | "libbinder", |
| 316 | "libutils", |
| 317 | "libbase", |
| 318 | ], |
Steven Moreland | 67812c2 | 2019-07-10 13:50:40 -0700 | [diff] [blame] | 319 | test_suites: ["device-tests"], |
Wei Wang | 78f2a37 | 2016-10-20 23:18:17 -0700 | [diff] [blame] | 320 | } |
Howard Chen | c135dbc | 2017-03-25 17:12:59 +0800 | [diff] [blame] | 321 | |
| 322 | cc_test { |
| 323 | name: "schd-dbg", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 324 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 325 | srcs: ["schd-dbg.cpp"], |
Howard Chen | c135dbc | 2017-03-25 17:12:59 +0800 | [diff] [blame] | 326 | shared_libs: [ |
| 327 | "libbinder", |
| 328 | "libutils", |
| 329 | "libbase", |
| 330 | ], |
| 331 | } |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 332 | |
| 333 | cc_test { |
| 334 | name: "binderSafeInterfaceTest", |
Chih-Hung Hsieh | d1acbbc | 2017-10-05 13:38:28 -0700 | [diff] [blame] | 335 | defaults: ["binder_test_defaults"], |
Steven Moreland | c7a30c8 | 2019-07-10 13:12:23 -0700 | [diff] [blame] | 336 | srcs: ["binderSafeInterfaceTest.cpp"], |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 337 | |
| 338 | cppflags: [ |
Colin Cross | 1383d9f | 2019-11-06 13:33:40 -0800 | [diff] [blame] | 339 | "-Wextra", |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 340 | ], |
| 341 | |
| 342 | cpp_std: "experimental", |
| 343 | gnu_extensions: false, |
| 344 | |
| 345 | shared_libs: [ |
| 346 | "libbinder", |
Dan Stoza | 2537db7 | 2017-04-07 16:32:38 -0700 | [diff] [blame] | 347 | "libcutils", |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 348 | "liblog", |
| 349 | "libutils", |
| 350 | ], |
Dan Shi | eb25b67 | 2020-03-26 11:43:04 -0700 | [diff] [blame] | 351 | test_suites: ["device-tests", "vts"], |
Dan Shi | 80ada59 | 2019-09-13 09:17:17 -0700 | [diff] [blame] | 352 | require_root: true, |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 353 | } |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 354 | |
Steven Moreland | f23dae2 | 2020-10-27 19:34:55 +0000 | [diff] [blame] | 355 | cc_test { |
| 356 | name: "binderClearBufTest", |
| 357 | defaults: ["binder_test_defaults"], |
| 358 | srcs: [ |
| 359 | "binderClearBufTest.cpp", |
| 360 | ], |
| 361 | |
| 362 | shared_libs: [ |
| 363 | "libbase", |
| 364 | "libbinder", |
| 365 | "liblog", |
| 366 | "libutils", |
| 367 | ], |
| 368 | |
| 369 | test_suites: ["general-tests"], |
| 370 | require_root: true, |
| 371 | } |
| 372 | |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 373 | aidl_interface { |
| 374 | name: "binderStabilityTestIface", |
Jiyong Park | 701fa1a | 2020-04-13 12:55:44 +0900 | [diff] [blame] | 375 | unstable: true, |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 376 | srcs: [ |
| 377 | "IBinderStabilityTest.aidl", |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 378 | ], |
Steven Moreland | 37aff18 | 2021-03-26 02:04:16 +0000 | [diff] [blame] | 379 | backend: { |
| 380 | java: { |
| 381 | enabled: false, |
| 382 | }, |
| 383 | }, |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 384 | } |
| 385 | |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 386 | cc_test { |
| 387 | name: "binderStabilityTest", |
| 388 | defaults: ["binder_test_defaults"], |
| 389 | srcs: [ |
| 390 | "binderStabilityTest.cpp", |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 391 | ], |
| 392 | |
Steven Moreland | 13f8466 | 2020-07-23 21:30:41 +0000 | [diff] [blame] | 393 | // critical that libbinder/libbinder_ndk are shared for VTS |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 394 | shared_libs: [ |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 395 | "libbinder_ndk", |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 396 | "libbinder", |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 397 | "liblog", |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 398 | "libutils", |
| 399 | ], |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 400 | static_libs: [ |
| 401 | "binderStabilityTestIface-cpp", |
Jiyong Park | 9a9427c | 2021-08-09 09:01:15 +0900 | [diff] [blame] | 402 | "binderStabilityTestIface-ndk", |
Steven Moreland | 12300a0 | 2019-08-02 13:27:15 -0700 | [diff] [blame] | 403 | ], |
| 404 | |
Steven Moreland | 13f8466 | 2020-07-23 21:30:41 +0000 | [diff] [blame] | 405 | test_suites: ["device-tests", "vts"], |
Dan Shi | 302709b | 2019-09-19 15:28:15 -0700 | [diff] [blame] | 406 | require_root: true, |
Steven Moreland | dea3cf9 | 2019-07-16 18:06:55 -0700 | [diff] [blame] | 407 | } |
Steven Moreland | 042ae82 | 2020-05-27 17:45:17 +0000 | [diff] [blame] | 408 | |
| 409 | cc_test { |
| 410 | name: "binderAllocationLimits", |
| 411 | defaults: ["binder_test_defaults"], |
| 412 | srcs: ["binderAllocationLimits.cpp"], |
| 413 | shared_libs: [ |
| 414 | "libbinder", |
| 415 | "liblog", |
| 416 | "libutils", |
| 417 | "libutilscallstack", |
| 418 | "libbase", |
| 419 | ], |
| 420 | test_suites: ["device-tests"], |
| 421 | require_root: true, |
| 422 | } |
Andy Hung | 73a1470 | 2020-11-24 13:04:46 -0800 | [diff] [blame] | 423 | |
| 424 | cc_benchmark { |
| 425 | name: "binderParcelBenchmark", |
| 426 | defaults: ["binder_test_defaults"], |
| 427 | srcs: ["binderParcelBenchmark.cpp"], |
| 428 | shared_libs: [ |
| 429 | "libbase", |
| 430 | "libbinder", |
| 431 | "liblog", |
| 432 | "libutils", |
| 433 | ], |
| 434 | } |
Yifan Hong | af766e6 | 2021-06-14 13:24:19 -0700 | [diff] [blame] | 435 | |
| 436 | cc_test_host { |
| 437 | name: "binderUtilsHostTest", |
| 438 | defaults: ["binder_test_defaults"], |
| 439 | srcs: ["binderUtilsHostTest.cpp"], |
| 440 | shared_libs: [ |
| 441 | "libbase", |
| 442 | "libbinder", |
| 443 | ], |
| 444 | static_libs: [ |
| 445 | "libgmock", |
| 446 | ], |
| 447 | test_suites: ["general-tests"], |
Yifan Hong | 44dec54 | 2021-06-22 10:47:44 -0700 | [diff] [blame] | 448 | target: { |
| 449 | darwin: { |
| 450 | enabled: false, |
| 451 | }, |
| 452 | }, |
Yifan Hong | af766e6 | 2021-06-14 13:24:19 -0700 | [diff] [blame] | 453 | } |
Yifan Hong | 1b6f12f | 2021-06-03 20:01:57 -0700 | [diff] [blame] | 454 | |
| 455 | cc_test_host { |
| 456 | name: "binderHostDeviceTest", |
| 457 | defaults: ["binder_test_defaults"], |
| 458 | srcs: ["binderHostDeviceTest.cpp"], |
| 459 | test_config: "binderHostDeviceTest.xml", |
| 460 | shared_libs: [ |
| 461 | "libbase", |
| 462 | "libbinder", |
| 463 | "liblog", |
| 464 | "libutils", |
| 465 | ], |
| 466 | static_libs: [ |
| 467 | "libgmock", |
| 468 | ], |
| 469 | target_required: [ |
| 470 | "binderHostDeviceTestService", |
| 471 | ], |
| 472 | test_suites: ["general-tests"], |
| 473 | target: { |
| 474 | darwin: { |
| 475 | enabled: false, |
| 476 | }, |
| 477 | }, |
| 478 | test_options: { |
| 479 | unit_test: false, |
| 480 | }, |
| 481 | } |
| 482 | |
| 483 | cc_test { |
| 484 | name: "binderHostDeviceTestService", |
| 485 | // The binary is named differently from the module so that PushFilePreparer pushes the binary |
| 486 | // directly, not the test module directory. |
| 487 | stem: "binderHostDeviceTest-service", |
| 488 | defaults: ["binder_test_defaults"], |
| 489 | gtest: false, |
| 490 | auto_gen_config: false, |
| 491 | srcs: ["binderHostDeviceTestService.cpp"], |
| 492 | shared_libs: [ |
| 493 | "libbase", |
| 494 | "libbinder", |
| 495 | "liblog", |
| 496 | "libutils", |
| 497 | ], |
| 498 | test_suites: ["general-tests"], |
| 499 | } |