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

Unified Diff: mojo/public/cpp/bindings/tests/array_unittest.cc

Issue 265793015: Mojo: Replace RemotePtr with InterfacePtr and InterfaceImpl (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 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
Index: mojo/public/cpp/bindings/tests/array_unittest.cc
diff --git a/mojo/public/cpp/bindings/tests/array_unittest.cc b/mojo/public/cpp/bindings/tests/array_unittest.cc
index dccd7167e9ecfe1ba50c4bb6736e7ddb0375133e..31ad6738e6b914f4cd7dfc9911dd0e70f431803f 100644
--- a/mojo/public/cpp/bindings/tests/array_unittest.cc
+++ b/mojo/public/cpp/bindings/tests/array_unittest.cc
@@ -141,31 +141,6 @@ TEST(ArrayTest, MessagePipeHandlesAreClosed) {
EXPECT_EQ(MOJO_RESULT_INVALID_ARGUMENT, MojoClose(pipe1_value));
}
-// Tests that Array<InterfaceHandle<S>> supports closing handles.
-TEST(ArrayTest, InterfaceHandlesAreClosed) {
- Environment env;
-
- InterfacePipe<sample::Port, sample::Port> pipe;
-
- MojoHandle pipe0_value = pipe.handle_to_self.get().value();
- MojoHandle pipe1_value = pipe.handle_to_peer.get().value();
-
- {
- AllocationScope scope;
-
- Array<sample::PortHandle>::Builder handles_builder(2);
- handles_builder[0] = pipe.handle_to_self.Pass();
- handles_builder[1].reset(pipe.handle_to_peer.release());
-
- MOJO_ALLOW_UNUSED Array<sample::PortHandle> handles =
- handles_builder.Finish();
- }
-
- // We expect the pipes to have been closed.
- EXPECT_EQ(MOJO_RESULT_INVALID_ARGUMENT, MojoClose(pipe0_value));
- EXPECT_EQ(MOJO_RESULT_INVALID_ARGUMENT, MojoClose(pipe1_value));
-}
-
} // namespace
} // namespace test
} // namespace mojo

Powered by Google App Engine
This is Rietveld 408576698