| 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 "third_party/mojo/src/mojo/edk/embedder/embedder.h" | 5 #include "third_party/mojo/src/mojo/edk/embedder/embedder.h" |
| 6 | 6 |
| 7 #include <string.h> | 7 #include <string.h> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| 11 #include "base/location.h" | 11 #include "base/location.h" |
| 12 #include "base/logging.h" | 12 #include "base/logging.h" |
| 13 #include "base/message_loop/message_loop.h" | 13 #include "base/message_loop/message_loop.h" |
| 14 #include "base/synchronization/waitable_event.h" | 14 #include "base/synchronization/waitable_event.h" |
| 15 #include "base/test/test_io_thread.h" | 15 #include "base/test/test_io_thread.h" |
| 16 #include "base/test/test_timeouts.h" | 16 #include "base/test/test_timeouts.h" |
| 17 #include "mojo/public/c/system/core.h" |
| 18 #include "mojo/public/cpp/system/handle.h" |
| 19 #include "mojo/public/cpp/system/macros.h" |
| 20 #include "mojo/public/cpp/system/message_pipe.h" |
| 17 #include "testing/gtest/include/gtest/gtest.h" | 21 #include "testing/gtest/include/gtest/gtest.h" |
| 18 #include "third_party/mojo/src/mojo/edk/embedder/platform_channel_pair.h" | 22 #include "third_party/mojo/src/mojo/edk/embedder/platform_channel_pair.h" |
| 19 #include "third_party/mojo/src/mojo/edk/embedder/test_embedder.h" | 23 #include "third_party/mojo/src/mojo/edk/embedder/test_embedder.h" |
| 20 #include "third_party/mojo/src/mojo/edk/system/mutex.h" | 24 #include "third_party/mojo/src/mojo/edk/system/mutex.h" |
| 21 #include "third_party/mojo/src/mojo/edk/system/test_utils.h" | 25 #include "third_party/mojo/src/mojo/edk/system/test_utils.h" |
| 22 #include "third_party/mojo/src/mojo/edk/test/multiprocess_test_helper.h" | 26 #include "third_party/mojo/src/mojo/edk/test/multiprocess_test_helper.h" |
| 23 #include "third_party/mojo/src/mojo/edk/test/scoped_ipc_support.h" | 27 #include "third_party/mojo/src/mojo/edk/test/scoped_ipc_support.h" |
| 24 #include "third_party/mojo/src/mojo/public/c/system/core.h" | |
| 25 #include "third_party/mojo/src/mojo/public/cpp/system/handle.h" | |
| 26 #include "third_party/mojo/src/mojo/public/cpp/system/macros.h" | |
| 27 #include "third_party/mojo/src/mojo/public/cpp/system/message_pipe.h" | |
| 28 | 28 |
| 29 namespace mojo { | 29 namespace mojo { |
| 30 namespace embedder { | 30 namespace embedder { |
| 31 namespace { | 31 namespace { |
| 32 | 32 |
| 33 const MojoHandleSignals kSignalReadadableWritable = | 33 const MojoHandleSignals kSignalReadadableWritable = |
| 34 MOJO_HANDLE_SIGNAL_READABLE | MOJO_HANDLE_SIGNAL_WRITABLE; | 34 MOJO_HANDLE_SIGNAL_READABLE | MOJO_HANDLE_SIGNAL_WRITABLE; |
| 35 | 35 |
| 36 const MojoHandleSignals kSignalAll = MOJO_HANDLE_SIGNAL_READABLE | | 36 const MojoHandleSignals kSignalAll = MOJO_HANDLE_SIGNAL_READABLE | |
| 37 MOJO_HANDLE_SIGNAL_WRITABLE | | 37 MOJO_HANDLE_SIGNAL_WRITABLE | |
| (...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 809 | 809 |
| 810 EXPECT_TRUE(test::Shutdown()); | 810 EXPECT_TRUE(test::Shutdown()); |
| 811 } | 811 } |
| 812 | 812 |
| 813 // TODO(vtl): Test immediate write & close. | 813 // TODO(vtl): Test immediate write & close. |
| 814 // TODO(vtl): Test broken-connection cases. | 814 // TODO(vtl): Test broken-connection cases. |
| 815 | 815 |
| 816 } // namespace | 816 } // namespace |
| 817 } // namespace embedder | 817 } // namespace embedder |
| 818 } // namespace mojo | 818 } // namespace mojo |
| OLD | NEW |