diff options
author | viettrungluu <viettrungluu@chromium.org> | 2014-09-24 12:23:09 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-24 19:23:29 +0000 |
commit | 23ae8173cca87c9dd9ca71cf3142f75a88e43919 (patch) | |
tree | d5b218afedf74134a50a71e67e751f6f7c3c80a0 /mojo/system/message_pipe_test_utils.h | |
parent | faa99f8c03c439f26c5ff497d3804b0818f1cf2f (diff) | |
download | chromium_src-23ae8173cca87c9dd9ca71cf3142f75a88e43919.zip chromium_src-23ae8173cca87c9dd9ca71cf3142f75a88e43919.tar.gz chromium_src-23ae8173cca87c9dd9ca71cf3142f75a88e43919.tar.bz2 |
Mojo: Have |ProxyMessagePipeEndpoint|s constructed with a |ChannelEndpoint|.
This eliminates the need for |ProxyMessagePipeEndpoint::Attach()|.
R=brettw@chromium.org
Review URL: https://codereview.chromium.org/588193004
Cr-Commit-Position: refs/heads/master@{#296485}
Diffstat (limited to 'mojo/system/message_pipe_test_utils.h')
-rw-r--r-- | mojo/system/message_pipe_test_utils.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/mojo/system/message_pipe_test_utils.h b/mojo/system/message_pipe_test_utils.h index 4db7bdc..1d1f861 100644 --- a/mojo/system/message_pipe_test_utils.h +++ b/mojo/system/message_pipe_test_utils.h @@ -9,11 +9,15 @@ #include "mojo/common/test/multiprocess_test_helper.h" #include "mojo/embedder/simple_platform_support.h" #include "mojo/system/channel.h" -#include "mojo/system/message_pipe.h" #include "mojo/system/test_utils.h" namespace mojo { namespace system { + +class Channel; +class ChannelEndpoint; +class MessagePipe; + namespace test { MojoResult WaitIfNecessary(scoped_refptr<MessagePipe> mp, @@ -26,12 +30,12 @@ class ChannelThread { ~ChannelThread(); void Start(embedder::ScopedPlatformHandle platform_handle, - scoped_refptr<MessagePipe> message_pipe); + scoped_refptr<ChannelEndpoint> channel_endpoint); void Stop(); private: void InitChannelOnIOThread(embedder::ScopedPlatformHandle platform_handle, - scoped_refptr<MessagePipe> message_pipe); + scoped_refptr<ChannelEndpoint> channel_endpoint); void ShutdownChannelOnIOThread(); embedder::PlatformSupport* const platform_support_; @@ -48,7 +52,7 @@ class MultiprocessMessagePipeTestBase : public testing::Test { virtual ~MultiprocessMessagePipeTestBase(); protected: - void Init(scoped_refptr<MessagePipe> mp); + void Init(scoped_refptr<ChannelEndpoint> ep); embedder::PlatformSupport* platform_support() { return &platform_support_; } mojo::test::MultiprocessTestHelper* helper() { return &helper_; } |