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

Unified Diff: mojo/edk/system/platform_handle_dispatcher_unittest.cc

Issue 1946423002: EDK: Remove Core::AddDispatcher(). (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/edk/system/platform_handle_dispatcher.cc ('k') | mojo/edk/system/remote_data_pipe_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/system/platform_handle_dispatcher_unittest.cc
diff --git a/mojo/edk/system/platform_handle_dispatcher_unittest.cc b/mojo/edk/system/platform_handle_dispatcher_unittest.cc
index 8b47bd335297627ff8b0df1578285c5d971a9898..626991a1dac5cb66c3435434231c011833f6ca7c 100644
--- a/mojo/edk/system/platform_handle_dispatcher_unittest.cc
+++ b/mojo/edk/system/platform_handle_dispatcher_unittest.cc
@@ -97,11 +97,8 @@ TEST(PlatformHandleDispatcherTest, CreateEquivalentDispatcherAndClose) {
auto dispatcher =
PlatformHandleDispatcher::Create(PlatformHandleFromFILE(std::move(fp)));
- // TODO(vtl): Are these the correct rights for a |PlatformHandleDispatcher|?
- const MojoHandleRights kRights = MOJO_HANDLE_RIGHT_TRANSFER |
- MOJO_HANDLE_RIGHT_READ |
- MOJO_HANDLE_RIGHT_WRITE;
- Handle handle(std::move(dispatcher), kRights);
+ Handle handle(std::move(dispatcher),
+ PlatformHandleDispatcher::kDefaultHandleRights);
HandleTransport transport(test::HandleTryStartTransport(handle));
EXPECT_TRUE(transport.is_valid());
@@ -111,7 +108,8 @@ TEST(PlatformHandleDispatcherTest, CreateEquivalentDispatcherAndClose) {
Handle equivalent_handle =
transport.CreateEquivalentHandleAndClose(nullptr, 0u);
ASSERT_TRUE(equivalent_handle.dispatcher);
- EXPECT_EQ(kRights, equivalent_handle.rights);
+ EXPECT_EQ(PlatformHandleDispatcher::kDefaultHandleRights,
+ equivalent_handle.rights);
transport.End();
EXPECT_TRUE(handle.dispatcher->HasOneRef());
« no previous file with comments | « mojo/edk/system/platform_handle_dispatcher.cc ('k') | mojo/edk/system/remote_data_pipe_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698