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

Unified Diff: components/cryptauth/cryptauth_device_manager_unittest.cc

Issue 2782553004: Move TestingPrefService to use unique_ptr<Value> (Closed)
Patch Set: comments 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
Index: components/cryptauth/cryptauth_device_manager_unittest.cc
diff --git a/components/cryptauth/cryptauth_device_manager_unittest.cc b/components/cryptauth/cryptauth_device_manager_unittest.cc
index 6c6af53928a401e1fd0ad3064710fd4e46ffd7f8..7dcd284349e36fc1c798a05b0ab1df24763c665d 100644
--- a/components/cryptauth/cryptauth_device_manager_unittest.cc
+++ b/components/cryptauth/cryptauth_device_manager_unittest.cc
@@ -383,11 +383,13 @@ class CryptAuthDeviceManagerTest
CryptAuthDeviceManager::RegisterPrefs(pref_service_.registry());
pref_service_.SetUserPref(
prefs::kCryptAuthDeviceSyncIsRecoveringFromFailure,
- new base::Value(false));
- pref_service_.SetUserPref(prefs::kCryptAuthDeviceSyncLastSyncTimeSeconds,
- new base::Value(kLastSyncTimeSeconds));
- pref_service_.SetUserPref(prefs::kCryptAuthDeviceSyncReason,
- new base::Value(INVOCATION_REASON_UNKNOWN));
+ base::MakeUnique<base::Value>(false));
+ pref_service_.SetUserPref(
+ prefs::kCryptAuthDeviceSyncLastSyncTimeSeconds,
+ base::MakeUnique<base::Value>(kLastSyncTimeSeconds));
+ pref_service_.SetUserPref(
+ prefs::kCryptAuthDeviceSyncReason,
+ base::MakeUnique<base::Value>(INVOCATION_REASON_UNKNOWN));
std::unique_ptr<base::DictionaryValue> device_dictionary(
new base::DictionaryValue());

Powered by Google App Engine
This is Rietveld 408576698