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

Unified Diff: chrome/browser/component_updater/supervised_user_whitelist_installer_unittest.cc

Issue 2777063003: Stop passing raw pointers to base::Value API in c/b/chromeos and c/b/extensions (Closed)
Patch Set: Fix SupervisedUserWhitelistInstaller Created 3 years, 8 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: chrome/browser/component_updater/supervised_user_whitelist_installer_unittest.cc
diff --git a/chrome/browser/component_updater/supervised_user_whitelist_installer_unittest.cc b/chrome/browser/component_updater/supervised_user_whitelist_installer_unittest.cc
index e1f0eb273feed97ad0613814cf71b298bd17812b..b418ad34cb72ea6c0094c18e81f2125506faa4a8 100644
--- a/chrome/browser/component_updater/supervised_user_whitelist_installer_unittest.cc
+++ b/chrome/browser/component_updater/supervised_user_whitelist_installer_unittest.cc
@@ -3,6 +3,7 @@
// found in the LICENSE file.
#include <stddef.h>
+#include <utility>
jdoerrie 2017/04/06 14:25:49 Nit: missing new line
vabr (Chromium) 2017/04/07 20:40:39 Done.
#include "base/bind.h"
#include "base/callback.h"
@@ -236,13 +237,13 @@ class SupervisedUserWhitelistInstallerTest : public testing::Test {
std::unique_ptr<base::DictionaryValue> whitelist_dict(
new base::DictionaryValue);
whitelist_dict->SetString("sites", kWhitelistFile);
- manifest_.Set("whitelisted_content", whitelist_dict.release());
+ manifest_.Set("whitelisted_content", std::move(whitelist_dict));
large_icon_path_ = whitelist_version_directory_.AppendASCII(kLargeIconFile);
std::unique_ptr<base::DictionaryValue> icons_dict(
new base::DictionaryValue);
icons_dict->SetString("128", kLargeIconFile);
- manifest_.Set("icons", icons_dict.release());
+ manifest_.Set("icons", std::move(icons_dict));
manifest_.SetString("version", kVersion);
@@ -251,8 +252,8 @@ class SupervisedUserWhitelistInstallerTest : public testing::Test {
std::unique_ptr<base::ListValue> clients(new base::ListValue);
clients->AppendString(kClientId);
clients->AppendString(kOtherClientId);
- crx_dict->Set("clients", clients.release());
- pref_.Set(kCrxId, crx_dict.release());
+ crx_dict->Set("clients", std::move(clients));
+ pref_.Set(kCrxId, std::move(crx_dict));
}
protected:

Powered by Google App Engine
This is Rietveld 408576698