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

Unified Diff: base/message_loop/message_pump_io_ios_unittest.cc

Issue 2695593009: Use the location where FileDescriptorWatcher is created to track the libevent handlers (Closed)
Patch Set: fix mac. 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
« no previous file with comments | « base/message_loop/message_pump_io_ios.cc ('k') | base/message_loop/message_pump_libevent.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_loop/message_pump_io_ios_unittest.cc
diff --git a/base/message_loop/message_pump_io_ios_unittest.cc b/base/message_loop/message_pump_io_ios_unittest.cc
index 19519aa751b3ab4d53a4b89ea8d95432d2868385..6976ee8ae19082d99f4d7618af06184488d3f2b1 100644
--- a/base/message_loop/message_pump_io_ios_unittest.cc
+++ b/base/message_loop/message_pump_io_ios_unittest.cc
@@ -76,7 +76,7 @@ class StupidWatcher : public MessagePumpIOSForIO::Watcher {
// Test to make sure that we catch calling WatchFileDescriptor off of the wrong
// thread.
TEST_F(MessagePumpIOSForIOTest, TestWatchingFromBadThread) {
- MessagePumpIOSForIO::FileDescriptorWatcher watcher;
+ MessagePumpIOSForIO::FileDescriptorWatcher watcher(FROM_HERE);
StupidWatcher delegate;
ASSERT_DCHECK_DEATH(
@@ -120,7 +120,7 @@ class DeleteWatcher : public BaseWatcher {
TEST_F(MessagePumpIOSForIOTest, DeleteWatcher) {
std::unique_ptr<MessagePumpIOSForIO> pump(new MessagePumpIOSForIO);
MessagePumpIOSForIO::FileDescriptorWatcher* watcher =
- new MessagePumpIOSForIO::FileDescriptorWatcher;
+ new MessagePumpIOSForIO::FileDescriptorWatcher(FROM_HERE);
DeleteWatcher delegate(watcher);
pump->WatchFileDescriptor(pipefds_[1],
false, MessagePumpIOSForIO::WATCH_READ_WRITE, watcher, &delegate);
@@ -155,7 +155,7 @@ class StopWatcher : public BaseWatcher {
TEST_F(MessagePumpIOSForIOTest, StopWatcher) {
std::unique_ptr<MessagePumpIOSForIO> pump(new MessagePumpIOSForIO);
- MessagePumpIOSForIO::FileDescriptorWatcher watcher;
+ MessagePumpIOSForIO::FileDescriptorWatcher watcher(FROM_HERE);
StopWatcher delegate(&watcher, pump.get());
pump->WatchFileDescriptor(pipefds_[1],
false, MessagePumpIOSForIO::WATCH_READ_WRITE, &watcher, &delegate);
@@ -166,7 +166,7 @@ TEST_F(MessagePumpIOSForIOTest, StopWatcher) {
TEST_F(MessagePumpIOSForIOTest, StopWatcherAndWatchSomethingElse) {
std::unique_ptr<MessagePumpIOSForIO> pump(new MessagePumpIOSForIO);
- MessagePumpIOSForIO::FileDescriptorWatcher watcher;
+ MessagePumpIOSForIO::FileDescriptorWatcher watcher(FROM_HERE);
StopWatcher delegate(&watcher, pump.get(), alternate_pipefds_[1]);
pump->WatchFileDescriptor(pipefds_[1],
false, MessagePumpIOSForIO::WATCH_READ_WRITE, &watcher, &delegate);
« no previous file with comments | « base/message_loop/message_pump_io_ios.cc ('k') | base/message_loop/message_pump_libevent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698