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

Unified Diff: chrome/browser/storage_monitor/test_storage_monitor.cc

Issue 16703025: [StorageMonitor] Move StorageMonitor ownership to BrowserProcessImpl (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 7 years, 6 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/storage_monitor/test_storage_monitor.cc
diff --git a/chrome/browser/storage_monitor/test_storage_monitor.cc b/chrome/browser/storage_monitor/test_storage_monitor.cc
index e28ce2c91529b84667f0ea699928d6c2c454ceb0..beb37556a72cec1ff392ccf6aa3349399ff76396 100644
--- a/chrome/browser/storage_monitor/test_storage_monitor.cc
+++ b/chrome/browser/storage_monitor/test_storage_monitor.cc
@@ -5,6 +5,7 @@
#include "chrome/browser/storage_monitor/test_storage_monitor.h"
#include "chrome/browser/storage_monitor/storage_info.h"
+#include "chrome/test/base/testing_browser_process.h"
#if defined(OS_LINUX)
#include "chrome/browser/storage_monitor/test_media_transfer_protocol_manager_linux.h"
@@ -25,6 +26,13 @@ TestStorageMonitor::TestStorageMonitor()
TestStorageMonitor::~TestStorageMonitor() {}
+void TestStorageMonitor::RemoveSingleton() {
Lei Zhang 2013/06/27 00:09:38 Why do we have this and RemoveSingletonForTesting?
Greg Billock 2013/06/27 18:25:43 Getting rid of the StorageMonitor singleton will l
+ StorageMonitor::RemoveSingletonForTesting();
+ TestingBrowserProcess* browser_process = TestingBrowserProcess::GetGlobal();
+ if (browser_process)
+ browser_process->SetStorageMonitor(NULL);
+}
+
TestStorageMonitor*
TestStorageMonitor::CreateForBrowserTests() {
StorageMonitor::RemoveSingletonForTesting();

Powered by Google App Engine
This is Rietveld 408576698