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

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

Issue 2725133002: Mojo: Armed Watchers (Closed)
Patch Set: . Created 3 years, 10 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/edk/system/data_pipe_unittest.cc
diff --git a/mojo/edk/system/data_pipe_unittest.cc b/mojo/edk/system/data_pipe_unittest.cc
index f444621355c527a449e5867605a755d3531d9660..c9ed8778c02884ddfa0c946e02f98d6b8a098ba4 100644
--- a/mojo/edk/system/data_pipe_unittest.cc
+++ b/mojo/edk/system/data_pipe_unittest.cc
@@ -1932,12 +1932,14 @@ DEFINE_TEST_CLIENT_TEST_WITH_PIPE(DataPipeStatusChangeInTransitClient,
loop->Quit();
},
&run_loop, &count);
- Watcher producer_watcher(FROM_HERE), consumer_watcher(FROM_HERE);
+ Watcher producer_watcher(FROM_HERE, Watcher::ArmingPolicy::AUTOMATIC);
+ Watcher consumer_watcher(FROM_HERE, Watcher::ArmingPolicy::AUTOMATIC);
producer_watcher.Start(
Handle(producers[1]), MOJO_HANDLE_SIGNAL_PEER_CLOSED, callback);
consumer_watcher.Start(
Handle(consumers[1]), MOJO_HANDLE_SIGNAL_PEER_CLOSED, callback);
run_loop.Run();
+ EXPECT_EQ(2, count);
}
// Wait on producer 2 by polling with MojoWriteData.

Powered by Google App Engine
This is Rietveld 408576698