Index: content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
diff --git a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
index 2ccddb24be0181e797ce68c28eed90738c45ed3b..0da99fbab737c560a75ea2eaf40735879c553bfa 100644 |
--- a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
+++ b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
@@ -512,8 +512,9 @@ class RenderWidgetHostViewAuraTest : public testing::Test { |
browser_context_.reset(); |
aura_test_helper_->TearDown(); |
- message_loop_.DeleteSoon(FROM_HERE, browser_context_.release()); |
- message_loop_.RunUntilIdle(); |
+ message_loop_.task_runner()->DeleteSoon(FROM_HERE, |
+ browser_context_.release()); |
+ base::RunLoop().RunUntilIdle(); |
ImageTransportFactory::Terminate(); |
} |
@@ -2459,21 +2460,21 @@ TEST_F(RenderWidgetHostViewAuraTest, DiscardDelegatedFramesWithMemoryPressure) { |
// If we hide one, it should not get evicted. |
views[0]->Hide(); |
- message_loop_.RunUntilIdle(); |
+ base::RunLoop().RunUntilIdle(); |
EXPECT_TRUE(views[0]->HasFrameData()); |
// Using a lesser memory pressure event however, should evict. |
SimulateMemoryPressure( |
base::MemoryPressureListener::MEMORY_PRESSURE_LEVEL_MODERATE); |
- message_loop_.RunUntilIdle(); |
+ base::RunLoop().RunUntilIdle(); |
EXPECT_FALSE(views[0]->HasFrameData()); |
// Check the same for a higher pressure event. |
views[1]->Hide(); |
- message_loop_.RunUntilIdle(); |
+ base::RunLoop().RunUntilIdle(); |
EXPECT_TRUE(views[1]->HasFrameData()); |
SimulateMemoryPressure( |
base::MemoryPressureListener::MEMORY_PRESSURE_LEVEL_CRITICAL); |
- message_loop_.RunUntilIdle(); |
+ base::RunLoop().RunUntilIdle(); |
EXPECT_FALSE(views[1]->HasFrameData()); |
for (size_t i = 0; i < renderer_count; ++i) { |
@@ -3320,7 +3321,7 @@ TEST_F(RenderWidgetHostViewAuraOverscrollTest, |
base::ThreadTaskRunnerHandle::Get()->PostDelayedTask( |
FROM_HERE, base::MessageLoop::QuitWhenIdleClosure(), |
base::TimeDelta::FromMilliseconds(15)); |
- base::MessageLoop::current()->Run(); |
+ base::RunLoop().Run(); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_mode()); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_delegate()->current_mode()); |
@@ -3427,7 +3428,7 @@ TEST_F(RenderWidgetHostViewAuraOverscrollTest, OverscrollWithTouchEvents) { |
base::ThreadTaskRunnerHandle::Get()->PostDelayedTask( |
FROM_HERE, base::MessageLoop::QuitWhenIdleClosure(), |
base::TimeDelta::FromMilliseconds(10)); |
- base::MessageLoop::current()->Run(); |
+ base::RunLoop().Run(); |
EXPECT_EQ(1U, sink_->message_count()); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_mode()); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_delegate()->current_mode()); |
@@ -3473,7 +3474,7 @@ TEST_F(RenderWidgetHostViewAuraOverscrollTest, |
base::ThreadTaskRunnerHandle::Get()->PostDelayedTask( |
FROM_HERE, base::MessageLoop::QuitWhenIdleClosure(), |
base::TimeDelta::FromMilliseconds(10)); |
- base::MessageLoop::current()->Run(); |
+ base::RunLoop().Run(); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_mode()); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_delegate()->current_mode()); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_delegate()->completed_mode()); |
@@ -3508,7 +3509,7 @@ TEST_F(RenderWidgetHostViewAuraOverscrollTest, |
base::ThreadTaskRunnerHandle::Get()->PostDelayedTask( |
FROM_HERE, base::MessageLoop::QuitWhenIdleClosure(), |
base::TimeDelta::FromMilliseconds(10)); |
- base::MessageLoop::current()->Run(); |
+ base::RunLoop().Run(); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_mode()); |
EXPECT_EQ(OVERSCROLL_NONE, overscroll_delegate()->current_mode()); |
EXPECT_EQ(OVERSCROLL_EAST, overscroll_delegate()->completed_mode()); |