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

Unified Diff: chrome/browser/prefs/profile_pref_store_manager_unittest.cc

Issue 2664753002: Remove base::StringValue (Closed)
Patch Set: Rebase Created 3 years, 9 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
« no previous file with comments | « chrome/browser/prefs/chrome_pref_service_unittest.cc ('k') | chrome/browser/prefs/proxy_policy_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/prefs/profile_pref_store_manager_unittest.cc
diff --git a/chrome/browser/prefs/profile_pref_store_manager_unittest.cc b/chrome/browser/prefs/profile_pref_store_manager_unittest.cc
index 49d38849602f9beb115998d9257b749e3bdcc2d1..701c8fe8ce15c8c5dc3b6a493b2fb206336e71df 100644
--- a/chrome/browser/prefs/profile_pref_store_manager_unittest.cc
+++ b/chrome/browser/prefs/profile_pref_store_manager_unittest.cc
@@ -198,14 +198,13 @@ class ProfilePrefStoreManagerTest : public testing::Test {
pref_store->AddObserver(&registry_verifier_);
PersistentPrefStore::PrefReadError error = pref_store->ReadPrefs();
EXPECT_EQ(PersistentPrefStore::PREF_READ_ERROR_NO_FILE, error);
- pref_store->SetValue(kTrackedAtomic,
- base::MakeUnique<base::StringValue>(kFoobar),
+ pref_store->SetValue(kTrackedAtomic, base::MakeUnique<base::Value>(kFoobar),
WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS);
pref_store->SetValue(kProtectedAtomic,
- base::MakeUnique<base::StringValue>(kHelloWorld),
+ base::MakeUnique<base::Value>(kHelloWorld),
WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS);
pref_store->SetValue(kUnprotectedPref,
- base::MakeUnique<base::StringValue>(kFoobar),
+ base::MakeUnique<base::Value>(kFoobar),
WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS);
pref_store->RemoveObserver(&registry_verifier_);
pref_store->CommitPendingWrite();
@@ -321,8 +320,8 @@ TEST_F(ProfilePrefStoreManagerTest, ProtectValues) {
TEST_F(ProfilePrefStoreManagerTest, InitializePrefsFromMasterPrefs) {
auto master_prefs = base::MakeUnique<base::DictionaryValue>();
- master_prefs->Set(kTrackedAtomic, new base::StringValue(kFoobar));
- master_prefs->Set(kProtectedAtomic, new base::StringValue(kHelloWorld));
+ master_prefs->Set(kTrackedAtomic, new base::Value(kFoobar));
+ master_prefs->Set(kProtectedAtomic, new base::Value(kHelloWorld));
EXPECT_TRUE(
manager_->InitializePrefsFromMasterPrefs(std::move(master_prefs)));
@@ -483,7 +482,7 @@ TEST_F(ProfilePrefStoreManagerTest, ProtectedToUnprotected) {
// Trigger the logic that migrates it back to the unprotected preferences
// file.
pref_store_->SetValue(kProtectedAtomic,
- base::WrapUnique(new base::StringValue(kGoodbyeWorld)),
+ base::WrapUnique(new base::Value(kGoodbyeWorld)),
WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS);
LoadExistingPrefs();
ExpectStringValueEquals(kProtectedAtomic, kGoodbyeWorld);
« no previous file with comments | « chrome/browser/prefs/chrome_pref_service_unittest.cc ('k') | chrome/browser/prefs/proxy_policy_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698