summaryrefslogtreecommitdiffstats
path: root/chrome/test
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/test')
-rw-r--r--chrome/test/reliability/page_load_test.cc8
-rw-r--r--chrome/test/testing_profile.h7
2 files changed, 3 insertions, 12 deletions
diff --git a/chrome/test/reliability/page_load_test.cc b/chrome/test/reliability/page_load_test.cc
index eca9df2..e39d342 100644
--- a/chrome/test/reliability/page_load_test.cc
+++ b/chrome/test/reliability/page_load_test.cc
@@ -530,12 +530,8 @@ class PageLoadTest : public UITest {
FilePath local_state_path = user_data_dir()
.Append(chrome::kLocalStateFilename);
- PrefService* local_state(new PrefService(new PrefValueStore(
- NULL, /* no managed preference values */
- new JsonPrefStore( /* user defined preference values */
- local_state_path,
- ChromeThread::GetMessageLoopProxyForThread(ChromeThread::FILE)),
- NULL /* no advised preference values */)));
+ PrefService* local_state = PrefService::CreateUserPrefService(
+ local_state_path);
return local_state;
}
diff --git a/chrome/test/testing_profile.h b/chrome/test/testing_profile.h
index c810a53..67f85a2 100644
--- a/chrome/test/testing_profile.h
+++ b/chrome/test/testing_profile.h
@@ -154,12 +154,7 @@ class TestingProfile : public Profile {
FilePath prefs_filename =
path_.Append(FILE_PATH_LITERAL("TestPreferences"));
- prefs_.reset(new PrefService(new PrefValueStore(
- NULL, /* no managed preference values */
- new JsonPrefStore( /* user defined preference values */
- prefs_filename,
- ChromeThread::GetMessageLoopProxyForThread(ChromeThread::FILE)),
- NULL /* no suggested preference values */)));
+ prefs_.reset(PrefService::CreateUserPrefService(prefs_filename));
Profile::RegisterUserPrefs(prefs_.get());
browser::RegisterAllPrefs(prefs_.get(), prefs_.get());
}