Index: content/test/render_thread_impl_browser_test_ipc_helper.cc |
diff --git a/content/test/render_thread_impl_browser_test_ipc_helper.cc b/content/test/render_thread_impl_browser_test_ipc_helper.cc |
index 59d09c240fb33da6f6d07c0f608adf1e2b0f38aa..f3e536d959c02bb80761647c9aa37e6b56d21ea8 100644 |
--- a/content/test/render_thread_impl_browser_test_ipc_helper.cc |
+++ b/content/test/render_thread_impl_browser_test_ipc_helper.cc |
@@ -23,7 +23,18 @@ RenderThreadImplBrowserIPCTestHelper::RenderThreadImplBrowserIPCTestHelper() { |
SetupIpcThread(); |
- if (IPC::ChannelMojo::ShouldBeUsed()) { |
+ // TODO(crbug.com/451221): Mojo should be used here even for Android. |
+ // Currently SetupMojo() calls InitializeMojo() which can be called at most |
+ // once for each process. This implices that every test case using |
+ // RenderThreadImplBrowserIPCTestHelper has to run in a dedicated process, but |
+ // that is false on OS_ANDROID. There is no way to call InitializeMojo() only |
+ // if it isn't initialized yet. |
+#if defined(OS_ANDROID) |
sky
2015/01/23 00:43:49
Is there some other switch you can use rather than
|
+ bool use_mojo_channel = false; |
+#else |
+ bool use_mojo_channel = IPC::ChannelMojo::ShouldBeUsed(); |
+#endif |
+ if (use_mojo_channel) { |
SetupMojo(); |
} else { |
channel_ = IPC::ChannelProxy::Create(channel_id_, IPC::Channel::MODE_SERVER, |