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 #include "build/build_config.h" | 5 #include "build/build_config.h" |
6 | 6 |
7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
8 #include <windows.h> | 8 #include <windows.h> |
9 #elif defined(OS_POSIX) | 9 #elif defined(OS_POSIX) |
10 #include <sys/types.h> | 10 #include <sys/types.h> |
11 #include <unistd.h> | 11 #include <unistd.h> |
12 #endif | 12 #endif |
13 | 13 |
14 #include <stdio.h> | 14 #include <stdio.h> |
15 #include <string> | 15 #include <string> |
16 #include <utility> | 16 #include <utility> |
17 | 17 |
18 #include "base/base_switches.h" | |
19 #include "base/command_line.h" | 18 #include "base/command_line.h" |
20 #include "base/debug/debug_on_start_win.h" | |
21 #include "base/perftimer.h" | |
22 #include "base/pickle.h" | 19 #include "base/pickle.h" |
23 #include "base/test/perf_test_suite.h" | |
24 #include "base/test/test_suite.h" | |
25 #include "base/threading/thread.h" | 20 #include "base/threading/thread.h" |
26 #include "base/time.h" | 21 #include "base/time.h" |
27 #include "ipc/ipc_descriptors.h" | 22 #include "ipc/ipc_descriptors.h" |
28 #include "ipc/ipc_channel.h" | 23 #include "ipc/ipc_channel.h" |
29 #include "ipc/ipc_channel_proxy.h" | 24 #include "ipc/ipc_channel_proxy.h" |
30 #include "ipc/ipc_message_utils.h" | 25 #include "ipc/ipc_message_utils.h" |
31 #include "ipc/ipc_multiprocess_test.h" | 26 #include "ipc/ipc_multiprocess_test.h" |
32 #include "ipc/ipc_sender.h" | 27 #include "ipc/ipc_sender.h" |
33 #include "ipc/ipc_switches.h" | 28 #include "ipc/ipc_switches.h" |
34 #include "ipc/ipc_test_base.h" | 29 #include "ipc/ipc_test_base.h" |
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
327 // setup IPC channel | 322 // setup IPC channel |
328 IPC::Channel chan(kTestClientChannel, IPC::Channel::MODE_CLIENT, | 323 IPC::Channel chan(kTestClientChannel, IPC::Channel::MODE_CLIENT, |
329 &channel_listener); | 324 &channel_listener); |
330 CHECK(chan.Connect()); | 325 CHECK(chan.Connect()); |
331 channel_listener.Init(&chan); | 326 channel_listener.Init(&chan); |
332 Send(&chan, "hello from child"); | 327 Send(&chan, "hello from child"); |
333 // run message loop | 328 // run message loop |
334 MessageLoop::current()->Run(); | 329 MessageLoop::current()->Run(); |
335 return 0; | 330 return 0; |
336 } | 331 } |
OLD | NEW |