OLD | NEW |
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/config/nacl/config.gni") | 5 import("//build/config/nacl/config.gni") |
6 import("//testing/test.gni") | 6 import("//testing/test.gni") |
7 import("//tools/ipc_fuzzer/ipc_fuzzer.gni") | 7 import("//tools/ipc_fuzzer/ipc_fuzzer.gni") |
8 | 8 |
9 component("ipc") { | 9 component("ipc") { |
10 sources = [ | 10 sources = [ |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 } | 147 } |
148 | 148 |
149 # This is provided as a separate target so other targets can provide param | 149 # This is provided as a separate target so other targets can provide param |
150 # traits implementations without necessarily linking to all of IPC. | 150 # traits implementations without necessarily linking to all of IPC. |
151 source_set("param_traits") { | 151 source_set("param_traits") { |
152 public = [ | 152 public = [ |
153 "ipc_param_traits.h", | 153 "ipc_param_traits.h", |
154 ] | 154 ] |
155 } | 155 } |
156 | 156 |
157 test("ipc_tests") { | 157 if (!is_ios) { |
158 sources = [ | 158 test("ipc_tests") { |
159 "attachment_broker_mac_unittest.cc", | 159 sources = [ |
160 "attachment_broker_privileged_mac_unittest.cc", | 160 "attachment_broker_mac_unittest.cc", |
161 "attachment_broker_privileged_win_unittest.cc", | 161 "attachment_broker_privileged_mac_unittest.cc", |
162 "ipc_channel_posix_unittest.cc", | 162 "attachment_broker_privileged_win_unittest.cc", |
163 "ipc_channel_proxy_unittest.cc", | 163 "ipc_channel_posix_unittest.cc", |
164 "ipc_channel_reader_unittest.cc", | 164 "ipc_channel_proxy_unittest.cc", |
165 "ipc_channel_unittest.cc", | 165 "ipc_channel_reader_unittest.cc", |
166 "ipc_fuzzing_tests.cc", | 166 "ipc_fuzzing_tests.cc", |
167 "ipc_message_attachment_set_posix_unittest.cc", | 167 "ipc_message_attachment_set_posix_unittest.cc", |
168 "ipc_message_unittest.cc", | 168 "ipc_message_unittest.cc", |
169 "ipc_message_utils_unittest.cc", | 169 "ipc_message_utils_unittest.cc", |
170 "ipc_send_fds_test.cc", | 170 "ipc_sync_channel_unittest.cc", |
171 "ipc_sync_channel_unittest.cc", | 171 "ipc_sync_message_unittest.cc", |
172 "ipc_sync_message_unittest.cc", | 172 "ipc_sync_message_unittest.h", |
173 "ipc_sync_message_unittest.h", | 173 "ipc_test_message_generator.cc", |
174 "ipc_test_message_generator.cc", | 174 "ipc_test_message_generator.h", |
175 "ipc_test_message_generator.h", | 175 "ipc_test_messages.h", |
176 "ipc_test_messages.h", | 176 "run_all_unittests.cc", |
177 "run_all_unittests.cc", | 177 "sync_socket_unittest.cc", |
178 "sync_socket_unittest.cc", | 178 ] |
179 "unix_domain_socket_util_unittest.cc", | |
180 ] | |
181 | 179 |
182 if (is_win || is_ios) { | 180 if (!is_win && !is_ios) { |
183 sources -= [ "unix_domain_socket_util_unittest.cc" ] | 181 sources += [ "unix_domain_socket_util_unittest.cc" ] |
| 182 } |
| 183 |
| 184 if (!is_android) { |
| 185 sources += [ "ipc_channel_unittest.cc" ] |
| 186 } |
| 187 |
| 188 if (!is_ios) { |
| 189 sources += [ "ipc_send_fds_test.cc" ] |
| 190 } |
| 191 |
| 192 # TODO(brettw) hook up Android testing. |
| 193 #if (is_android && gtest_target_type == "shared_library") { |
| 194 # deps += "/testing/android/native_test.gyp:native_testNative_code" |
| 195 #} |
| 196 |
| 197 deps = [ |
| 198 ":ipc", |
| 199 ":test_support", |
| 200 "//base", |
| 201 "//base:i18n", |
| 202 "//base/test:test_support", |
| 203 "//crypto", |
| 204 "//testing/gtest", |
| 205 ] |
| 206 |
| 207 if (is_mac) { |
| 208 deps += [ "//sandbox/mac:seatbelt" ] |
| 209 } |
184 } | 210 } |
185 | 211 |
186 if (is_android) { | 212 test("ipc_perftests") { |
187 # These multiprocess tests don't work on Android. | 213 sources = [ |
188 sources -= [ "ipc_channel_unittest.cc" ] | 214 "ipc_perftests.cc", |
| 215 ] |
| 216 |
| 217 # TODO(brettw) hook up Android testing. |
| 218 #if (is_android && gtest_target_type == "shared_library") { |
| 219 # deps += "/testing/android/native_test.gyp:native_testNative_code" |
| 220 #} |
| 221 |
| 222 deps = [ |
| 223 ":ipc", |
| 224 ":test_support", |
| 225 "//base", |
| 226 "//base:i18n", |
| 227 "//base/test:test_support", |
| 228 "//base/test:test_support_perf", |
| 229 "//testing/gtest", |
| 230 ] |
189 } | 231 } |
190 | 232 |
191 # TODO(brettw) hook up Android testing. | 233 source_set("test_support") { |
192 #if (is_android && gtest_target_type == "shared_library") { | 234 testonly = true |
193 # deps += "/testing/android/native_test.gyp:native_testNative_code" | 235 sources = [ |
194 #} | 236 "ipc_multiprocess_test.cc", |
195 | 237 "ipc_multiprocess_test.h", |
196 deps = [ | 238 "ipc_perftest_support.cc", |
197 ":ipc", | 239 "ipc_perftest_support.h", |
198 ":test_support", | 240 "ipc_security_test_util.cc", |
199 "//base", | 241 "ipc_security_test_util.h", |
200 "//base:i18n", | 242 "ipc_test_base.cc", |
201 "//base/test:test_support", | 243 "ipc_test_base.h", |
202 "//crypto", | 244 "ipc_test_channel_listener.cc", |
203 "//testing/gtest", | 245 "ipc_test_channel_listener.h", |
204 ] | 246 "ipc_test_sink.cc", |
205 | 247 "ipc_test_sink.h", |
206 if (is_mac) { | 248 "test_util_mac.cc", |
207 deps += [ "//sandbox/mac:seatbelt" ] | 249 "test_util_mac.h", |
| 250 ] |
| 251 public_deps = [ |
| 252 ":ipc", |
| 253 ] |
| 254 deps = [ |
| 255 "//base", |
| 256 "//base/test:test_support", |
| 257 "//testing/gtest", |
| 258 ] |
208 } | 259 } |
209 } | 260 } |
210 | |
211 test("ipc_perftests") { | |
212 sources = [ | |
213 "ipc_perftests.cc", | |
214 ] | |
215 | |
216 # TODO(brettw) hook up Android testing. | |
217 #if (is_android && gtest_target_type == "shared_library") { | |
218 # deps += "/testing/android/native_test.gyp:native_testNative_code" | |
219 #} | |
220 | |
221 deps = [ | |
222 ":ipc", | |
223 ":test_support", | |
224 "//base", | |
225 "//base:i18n", | |
226 "//base/test:test_support", | |
227 "//base/test:test_support_perf", | |
228 "//testing/gtest", | |
229 ] | |
230 } | |
231 | |
232 source_set("test_support") { | |
233 testonly = true | |
234 sources = [ | |
235 "ipc_multiprocess_test.cc", | |
236 "ipc_multiprocess_test.h", | |
237 "ipc_perftest_support.cc", | |
238 "ipc_perftest_support.h", | |
239 "ipc_security_test_util.cc", | |
240 "ipc_security_test_util.h", | |
241 "ipc_test_base.cc", | |
242 "ipc_test_base.h", | |
243 "ipc_test_channel_listener.cc", | |
244 "ipc_test_channel_listener.h", | |
245 "ipc_test_sink.cc", | |
246 "ipc_test_sink.h", | |
247 "test_util_mac.cc", | |
248 "test_util_mac.h", | |
249 ] | |
250 public_deps = [ | |
251 ":ipc", | |
252 ] | |
253 deps = [ | |
254 "//base", | |
255 "//base/test:test_support", | |
256 "//testing/gtest", | |
257 ] | |
258 } | |
OLD | NEW |