Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(365)

Side by Side Diff: ipc/mojo/ipc_mojo_perftest.cc

Issue 843113003: MultiProcessTest: Update SpawnChild* to return a Process. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ipc/mojo/ipc_mojo_bootstrap_unittest.cc ('k') | ipc/sync_socket_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "base/lazy_instance.h" 5 #include "base/lazy_instance.h"
6 #include "ipc/ipc_perftest_support.h" 6 #include "ipc/ipc_perftest_support.h"
7 #include "ipc/mojo/ipc_channel_mojo.h" 7 #include "ipc/mojo/ipc_channel_mojo.h"
8 #include "ipc/mojo/ipc_channel_mojo_host.h" 8 #include "ipc/mojo/ipc_channel_mojo_host.h"
9 #include "mojo/edk/embedder/test_embedder.h" 9 #include "mojo/edk/embedder/test_embedder.h"
10 10
(...skipping 22 matching lines...) Expand all
33 const IPC::ChannelHandle& handle, 33 const IPC::ChannelHandle& handle,
34 base::TaskRunner* runner) override { 34 base::TaskRunner* runner) override {
35 host_.reset(new IPC::ChannelMojoHost(task_runner())); 35 host_.reset(new IPC::ChannelMojoHost(task_runner()));
36 return IPC::ChannelMojo::CreateServerFactory(host_->channel_delegate(), 36 return IPC::ChannelMojo::CreateServerFactory(host_->channel_delegate(),
37 handle); 37 handle);
38 } 38 }
39 39
40 bool DidStartClient() override { 40 bool DidStartClient() override {
41 bool ok = IPCTestBase::DidStartClient(); 41 bool ok = IPCTestBase::DidStartClient();
42 DCHECK(ok); 42 DCHECK(ok);
43 host_->OnClientLaunched(client_process()); 43 host_->OnClientLaunched(client_process().Handle());
44 return ok; 44 return ok;
45 } 45 }
46 46
47 void set_io_thread_task_runner(base::TaskRunner* runner) { 47 void set_io_thread_task_runner(base::TaskRunner* runner) {
48 io_thread_task_runner_ = runner; 48 io_thread_task_runner_ = runner;
49 } 49 }
50 50
51 private: 51 private:
52 base::TaskRunner* io_thread_task_runner_; 52 base::TaskRunner* io_thread_task_runner_;
53 scoped_ptr<IPC::ChannelMojoHost> host_; 53 scoped_ptr<IPC::ChannelMojoHost> host_;
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 IPC::Channel::MODE_CLIENT, 88 IPC::Channel::MODE_CLIENT,
89 listener)); 89 listener));
90 } 90 }
91 91
92 MULTIPROCESS_IPC_TEST_CLIENT_MAIN(PerformanceClient) { 92 MULTIPROCESS_IPC_TEST_CLIENT_MAIN(PerformanceClient) {
93 MojoTestClient client; 93 MojoTestClient client;
94 return client.RunMain(); 94 return client.RunMain();
95 } 95 }
96 96
97 } // namespace 97 } // namespace
OLDNEW
« no previous file with comments | « ipc/mojo/ipc_mojo_bootstrap_unittest.cc ('k') | ipc/sync_socket_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698