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

Unified Diff: chrome/browser/extensions/test_extension_prefs.cc

Issue 64193003: Clean up PrefServiceBuilder (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix memory ownership bug in ProxyPolicyTest Created 7 years, 1 month 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/extensions/test_extension_prefs.cc
diff --git a/chrome/browser/extensions/test_extension_prefs.cc b/chrome/browser/extensions/test_extension_prefs.cc
index 6118f617688e4e56d6f312210e9a565529c652d6..62eba69890f0e3284af6f13c969fe8d37cc49f87 100644
--- a/chrome/browser/extensions/test_extension_prefs.cc
+++ b/chrome/browser/extensions/test_extension_prefs.cc
@@ -19,7 +19,7 @@
#include "chrome/browser/extensions/extension_pref_store.h"
#include "chrome/browser/extensions/extension_pref_value_map.h"
#include "chrome/browser/extensions/extension_prefs.h"
-#include "chrome/browser/prefs/pref_service_mock_builder.h"
+#include "chrome/browser/prefs/pref_service_mock_factory.h"
#include "chrome/browser/prefs/pref_service_syncable.h"
#include "components/user_prefs/pref_registry_syncable.h"
#include "content/public/browser/browser_thread.h"
@@ -103,11 +103,11 @@ void TestExtensionPrefs::RecreateExtensionPrefs() {
}
extension_pref_value_map_.reset(new ExtensionPrefValueMap);
- PrefServiceMockBuilder builder;
- builder.WithUserFilePrefs(preferences_file_, task_runner_.get());
- builder.WithExtensionPrefs(
+ PrefServiceMockFactory factory;
+ factory.SetUserPrefsFile(preferences_file_, task_runner_.get());
+ factory.set_extension_prefs(
new ExtensionPrefStore(extension_pref_value_map_.get(), false));
- pref_service_.reset(builder.CreateSyncable(pref_registry_.get()));
+ pref_service_ = factory.CreateSyncable(pref_registry_.get()).Pass();
prefs_.reset(ExtensionPrefs::Create(
pref_service_.get(),
« no previous file with comments | « chrome/browser/extensions/extension_service_unittest.cc ('k') | chrome/browser/net/pref_proxy_config_tracker_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698