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

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

Issue 1958903007: EDK: Add tests for ..._RIGHTS_NONE in HandleTest.HasAllRights. (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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/system/handle_unittest.cc
diff --git a/mojo/edk/system/handle_unittest.cc b/mojo/edk/system/handle_unittest.cc
index 141b3905865aa61324ee00358039677607d2162e..e1022f507e4cbff4687597349157fe39708ff79f 100644
--- a/mojo/edk/system/handle_unittest.cc
+++ b/mojo/edk/system/handle_unittest.cc
@@ -118,6 +118,7 @@ TEST(HandleTest, HasAllRights) {
{
Handle h;
+ EXPECT_TRUE(h.has_all_rights(MOJO_HANDLE_RIGHT_NONE));
EXPECT_FALSE(h.has_all_rights(MOJO_HANDLE_RIGHT_DUPLICATE));
EXPECT_FALSE(h.has_all_rights(MOJO_HANDLE_RIGHT_TRANSFER));
EXPECT_FALSE(h.has_all_rights(MOJO_HANDLE_RIGHT_READ));
@@ -128,6 +129,7 @@ TEST(HandleTest, HasAllRights) {
Handle h(MakeRefCounted<test::MockSimpleDispatcher>(),
MOJO_HANDLE_RIGHT_DUPLICATE | MOJO_HANDLE_RIGHT_READ);
+ EXPECT_TRUE(h.has_all_rights(MOJO_HANDLE_RIGHT_NONE));
EXPECT_TRUE(h.has_all_rights(MOJO_HANDLE_RIGHT_DUPLICATE));
EXPECT_FALSE(h.has_all_rights(MOJO_HANDLE_RIGHT_TRANSFER));
EXPECT_TRUE(h.has_all_rights(MOJO_HANDLE_RIGHT_READ));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698