blob: a03835b34cbb8899e1d7db5dbb8f77e15dcf73c8 [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
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070017cc_defaults {
18 name: "binder_test_defaults",
19 cflags: [
20 "-Wall",
21 "-Werror",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070022 ],
23}
24
Dan Willemsen59e086f2016-07-25 17:13:45 -070025cc_test {
Hsin-Yi Chen69295752017-06-07 18:05:05 +080026 name: "binderDriverInterfaceTest_IPC_32",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070027 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -070028 srcs: ["binderDriverInterfaceTest.cpp"],
Hsin-Yi Chen69295752017-06-07 18:05:05 +080029 compile_multilib: "32",
Steven Morelandf9f3de22020-05-06 17:14:39 -070030 multilib: { lib32: { suffix: "" } },
Hsin-Yi Chen69295752017-06-07 18:05:05 +080031 cflags: ["-DBINDER_IPC_32BIT=1"],
Steven Morelandf9f3de22020-05-06 17:14:39 -070032 test_suites: ["vts"],
Hsin-Yi Chen69295752017-06-07 18:05:05 +080033}
34
35cc_test {
Steven Morelandc7a30c82019-07-10 13:12:23 -070036 name: "binderDriverInterfaceTest",
37 defaults: ["binder_test_defaults"],
Dan Willemsen59e086f2016-07-25 17:13:45 -070038 product_variables: {
39 binder32bit: {
40 cflags: ["-DBINDER_IPC_32BIT=1"],
41 },
42 },
43
Dan Willemsen59e086f2016-07-25 17:13:45 -070044 srcs: ["binderDriverInterfaceTest.cpp"],
Dan Shieb25b672020-03-26 11:43:04 -070045 test_suites: ["device-tests", "vts"],
Dan Willemsen59e086f2016-07-25 17:13:45 -070046}
47
48cc_test {
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080049 name: "binderLibTest_IPC_32",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070050 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -070051 srcs: ["binderLibTest.cpp"],
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080052 shared_libs: [
53 "libbinder",
54 "libutils",
55 ],
56 compile_multilib: "32",
Steven Morelandf9f3de22020-05-06 17:14:39 -070057 multilib: { lib32: { suffix: "" } },
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080058 cflags: ["-DBINDER_IPC_32BIT=1"],
Steven Morelandf9f3de22020-05-06 17:14:39 -070059 test_suites: ["vts"],
60 require_root: true,
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080061}
62
63cc_test {
Steven Morelandc7a30c82019-07-10 13:12:23 -070064 name: "binderLibTest",
65 defaults: ["binder_test_defaults"],
Hsin-Yi Chenec18c022017-07-06 11:40:20 +080066 product_variables: {
67 binder32bit: {
68 cflags: ["-DBINDER_IPC_32BIT=1"],
69 },
70 },
71
Dan Willemsen59e086f2016-07-25 17:13:45 -070072 srcs: ["binderLibTest.cpp"],
73 shared_libs: [
74 "libbinder",
75 "libutils",
76 ],
Dan Shieb25b672020-03-26 11:43:04 -070077 test_suites: ["device-tests", "vts"],
Dan Shi80ada592019-09-13 09:17:17 -070078 require_root: true,
Dan Willemsen59e086f2016-07-25 17:13:45 -070079}
80
81cc_test {
82 name: "binderThroughputTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -070083 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -070084 srcs: ["binderThroughputTest.cpp"],
Dan Willemsen59e086f2016-07-25 17:13:45 -070085 shared_libs: [
86 "libbinder",
87 "libutils",
88 ],
89 clang: true,
90 cflags: [
91 "-g",
Dan Willemsen59e086f2016-07-25 17:13:45 -070092 "-Wno-missing-field-initializers",
93 "-Wno-sign-compare",
94 "-O3",
95 ],
96}
Wei Wang78f2a372016-10-20 23:18:17 -070097
98cc_test {
99 name: "binderTextOutputTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700100 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700101 srcs: ["binderTextOutputTest.cpp"],
Wei Wang78f2a372016-10-20 23:18:17 -0700102 shared_libs: [
103 "libbinder",
104 "libutils",
105 "libbase",
106 ],
Steven Moreland67812c22019-07-10 13:50:40 -0700107 test_suites: ["device-tests"],
Wei Wang78f2a372016-10-20 23:18:17 -0700108}
Howard Chenc135dbc2017-03-25 17:12:59 +0800109
110cc_test {
111 name: "schd-dbg",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700112 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700113 srcs: ["schd-dbg.cpp"],
Howard Chenc135dbc2017-03-25 17:12:59 +0800114 shared_libs: [
115 "libbinder",
116 "libutils",
117 "libbase",
118 ],
119}
Dan Stozad630e522016-12-01 15:16:31 -0800120
121cc_test {
122 name: "binderSafeInterfaceTest",
Chih-Hung Hsiehd1acbbc2017-10-05 13:38:28 -0700123 defaults: ["binder_test_defaults"],
Steven Morelandc7a30c82019-07-10 13:12:23 -0700124 srcs: ["binderSafeInterfaceTest.cpp"],
Dan Stozad630e522016-12-01 15:16:31 -0800125
126 cppflags: [
Colin Cross1383d9f2019-11-06 13:33:40 -0800127 "-Wextra",
Dan Stozad630e522016-12-01 15:16:31 -0800128 ],
129
130 cpp_std: "experimental",
131 gnu_extensions: false,
132
133 shared_libs: [
134 "libbinder",
Dan Stoza2537db72017-04-07 16:32:38 -0700135 "libcutils",
Dan Stozad630e522016-12-01 15:16:31 -0800136 "liblog",
137 "libutils",
138 ],
Dan Shieb25b672020-03-26 11:43:04 -0700139 test_suites: ["device-tests", "vts"],
Dan Shi80ada592019-09-13 09:17:17 -0700140 require_root: true,
Dan Stozad630e522016-12-01 15:16:31 -0800141}
Steven Morelanddea3cf92019-07-16 18:06:55 -0700142
Steven Moreland12300a02019-08-02 13:27:15 -0700143aidl_interface {
144 name: "binderStabilityTestIface",
Jiyong Park701fa1a2020-04-13 12:55:44 +0900145 unstable: true,
Steven Moreland12300a02019-08-02 13:27:15 -0700146 srcs: [
147 "IBinderStabilityTest.aidl",
Steven Moreland12300a02019-08-02 13:27:15 -0700148 ],
149}
150
Steven Morelanddea3cf92019-07-16 18:06:55 -0700151cc_test {
152 name: "binderStabilityTest",
153 defaults: ["binder_test_defaults"],
154 srcs: [
155 "binderStabilityTest.cpp",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700156 ],
157
Steven Moreland13f84662020-07-23 21:30:41 +0000158 // critical that libbinder/libbinder_ndk are shared for VTS
Steven Morelanddea3cf92019-07-16 18:06:55 -0700159 shared_libs: [
Steven Moreland12300a02019-08-02 13:27:15 -0700160 "libbinder_ndk",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700161 "libbinder",
Steven Moreland12300a02019-08-02 13:27:15 -0700162 "liblog",
Steven Morelanddea3cf92019-07-16 18:06:55 -0700163 "libutils",
164 ],
Steven Moreland12300a02019-08-02 13:27:15 -0700165 static_libs: [
166 "binderStabilityTestIface-cpp",
167 "binderStabilityTestIface-ndk_platform",
168 ],
169
Steven Moreland13f84662020-07-23 21:30:41 +0000170 test_suites: ["device-tests", "vts"],
Dan Shi302709b2019-09-19 15:28:15 -0700171 require_root: true,
Steven Morelanddea3cf92019-07-16 18:06:55 -0700172}
Steven Moreland042ae822020-05-27 17:45:17 +0000173
174cc_test {
175 name: "binderAllocationLimits",
176 defaults: ["binder_test_defaults"],
177 srcs: ["binderAllocationLimits.cpp"],
178 shared_libs: [
179 "libbinder",
180 "liblog",
181 "libutils",
182 "libutilscallstack",
183 "libbase",
184 ],
185 test_suites: ["device-tests"],
186 require_root: true,
187}