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

Unified Diff: components/user_prefs/tracked/tracked_preferences_migration_unittest.cc

Issue 2297373002: Refactor PrefHashStore's BeginTransaction to take a rawptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments on #1 Created 4 years, 3 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 | « components/user_prefs/tracked/tracked_preferences_migration.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/user_prefs/tracked/tracked_preferences_migration_unittest.cc
diff --git a/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc b/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc
index 3c6258f0890fdcf1a16010231dfd0543f0490dc0..3340649fe7d55b85739ff3cf3794d75f58ca5831 100644
--- a/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc
+++ b/components/user_prefs/tracked/tracked_preferences_migration_unittest.cc
@@ -162,10 +162,8 @@ class TrackedPreferencesMigrationTest : public testing::Test {
DCHECK(store);
base::StringValue string_value(value);
- pref_hash_store
- ->BeginTransaction(std::unique_ptr<HashStoreContents>(
- new DictionaryHashStoreContents(store)))
- ->StoreHash(key, &string_value);
+ DictionaryHashStoreContents contents(store);
+ pref_hash_store->BeginTransaction(&contents)->StoreHash(key, &string_value);
}
// Returns true if the store opposite to |store_id| is observed for its next
« no previous file with comments | « components/user_prefs/tracked/tracked_preferences_migration.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698