OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "ipc/mojo/ipc_mojo_bootstrap.h" | 5 #include "ipc/mojo/ipc_mojo_bootstrap.h" |
6 | 6 |
7 #include "base/base_paths.h" | 7 #include "base/base_paths.h" |
8 #include "base/files/file.h" | 8 #include "base/files/file.h" |
9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
10 #include "ipc/ipc_test_base.h" | 10 #include "ipc/ipc_test_base.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 EXPECT_TRUE(WaitForClientShutdown()); | 63 EXPECT_TRUE(WaitForClientShutdown()); |
64 } | 64 } |
65 | 65 |
66 // A long running process that connects to us. | 66 // A long running process that connects to us. |
67 MULTIPROCESS_IPC_TEST_CLIENT_MAIN(IPCMojoBootstrapTestClient) { | 67 MULTIPROCESS_IPC_TEST_CLIENT_MAIN(IPCMojoBootstrapTestClient) { |
68 base::MessageLoopForIO main_message_loop; | 68 base::MessageLoopForIO main_message_loop; |
69 | 69 |
70 TestingDelegate delegate; | 70 TestingDelegate delegate; |
71 scoped_ptr<IPC::MojoBootstrap> bootstrap = IPC::MojoBootstrap::Create( | 71 scoped_ptr<IPC::MojoBootstrap> bootstrap = IPC::MojoBootstrap::Create( |
72 IPCTestBase::GetChannelName("IPCMojoBootstrapTestClient"), | 72 IPCTestBase::GetChannelName("IPCMojoBootstrapTestClient"), |
73 IPC::Channel::MODE_CLIENT, | 73 IPC::Channel::MODE_CLIENT, &delegate, nullptr); |
74 &delegate, | |
75 nullptr); | |
76 | 74 |
77 bootstrap->Connect(); | 75 bootstrap->Connect(); |
78 | 76 |
79 base::MessageLoop::current()->Run(); | 77 base::MessageLoop::current()->Run(); |
80 | 78 |
81 EXPECT_TRUE(delegate.passed()); | 79 EXPECT_TRUE(delegate.passed()); |
82 | 80 |
83 return 0; | 81 return 0; |
84 } | 82 } |
85 | 83 |
86 } // namespace | 84 } // namespace |
OLD | NEW |