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

Unified Diff: chrome/browser/download/chrome_download_manager_delegate_unittest.cc

Issue 14197014: Add TestBrowserThreadBundle into RenderViewHostTestHarness. Kill some unnecessary real threads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge to head, address jyasskin's comments. Created 7 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
Index: chrome/browser/download/chrome_download_manager_delegate_unittest.cc
diff --git a/chrome/browser/download/chrome_download_manager_delegate_unittest.cc b/chrome/browser/download/chrome_download_manager_delegate_unittest.cc
index d2dc590f5fc5c774fa5de28df305cee63fed589e..bd4d8e4cd779dac0e5e35ac4fce4a6958d39d2fb 100644
--- a/chrome/browser/download/chrome_download_manager_delegate_unittest.cc
+++ b/chrome/browser/download/chrome_download_manager_delegate_unittest.cc
@@ -167,18 +167,13 @@ class ChromeDownloadManagerDelegateTest :
TestingPrefServiceSyncable* pref_service_;
base::ScopedTempDir test_download_dir_;
- content::TestBrowserThread ui_thread_;
- content::TestBrowserThread file_thread_;
scoped_ptr<content::MockDownloadManager> download_manager_;
scoped_refptr<TestChromeDownloadManagerDelegate> delegate_;
MockWebContentsDelegate web_contents_delegate_;
};
ChromeDownloadManagerDelegateTest::ChromeDownloadManagerDelegateTest()
- : ChromeRenderViewHostTestHarness(),
- ui_thread_(content::BrowserThread::UI, &message_loop_),
- file_thread_(content::BrowserThread::FILE, &message_loop_),
- download_manager_(new ::testing::NiceMock<content::MockDownloadManager>) {
+ : download_manager_(new ::testing::NiceMock<content::MockDownloadManager>) {
}
void ChromeDownloadManagerDelegateTest::SetUp() {
@@ -195,7 +190,7 @@ void ChromeDownloadManagerDelegateTest::SetUp() {
}
void ChromeDownloadManagerDelegateTest::TearDown() {
- message_loop_.RunUntilIdle();
+ base::RunLoop().RunUntilIdle();
delegate_->Shutdown();
ChromeRenderViewHostTestHarness::TearDown();
}

Powered by Google App Engine
This is Rietveld 408576698