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

Unified Diff: base/message_loop/message_loop_unittest.cc

Issue 1223193004: Revert of base: Make it possible to replace the MessageLoop's task runner (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 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_loop.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_loop/message_loop_unittest.cc
diff --git a/base/message_loop/message_loop_unittest.cc b/base/message_loop/message_loop_unittest.cc
index 9c1701756882febefde91d667e3b38312da8cb11..48c82c4792b51a5e0d67e9ca7737bd24a885e4bb 100644
--- a/base/message_loop/message_loop_unittest.cc
+++ b/base/message_loop/message_loop_unittest.cc
@@ -15,7 +15,6 @@
#include "base/posix/eintr_wrapper.h"
#include "base/run_loop.h"
#include "base/synchronization/waitable_event.h"
-#include "base/test/test_simple_task_runner.h"
#include "base/thread_task_runner_handle.h"
#include "base/threading/platform_thread.h"
#include "base/threading/thread.h"
@@ -1012,26 +1011,4 @@
}
#endif // defined(OS_WIN)
-TEST(MessageLoopTest, SetTaskRunner) {
- MessageLoop loop;
- scoped_refptr<SingleThreadTaskRunner> new_runner(new TestSimpleTaskRunner());
-
- loop.SetTaskRunner(new_runner);
- EXPECT_EQ(new_runner, loop.task_runner());
- EXPECT_EQ(new_runner, ThreadTaskRunnerHandle::Get());
-}
-
-TEST(MessageLoopTest, OriginalRunnerWorks) {
- MessageLoop loop;
- scoped_refptr<SingleThreadTaskRunner> new_runner(new TestSimpleTaskRunner());
- scoped_refptr<SingleThreadTaskRunner> original_runner(loop.task_runner());
- loop.SetTaskRunner(new_runner);
-
- scoped_refptr<Foo> foo(new Foo());
- original_runner->PostTask(FROM_HERE,
- Bind(&Foo::Test1ConstRef, foo.get(), "a"));
- loop.RunUntilIdle();
- EXPECT_EQ(1, foo->test_count());
-}
-
} // namespace base
« no previous file with comments | « base/message_loop/message_loop.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698