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

Unified Diff: chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc

Issue 2740143002: Change base::Value::ListStorage to std::vector<base::Value> (Closed)
Patch Set: Rebase 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/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc
diff --git a/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc b/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc
index 20013f9ef37f015fb3eea040f98b56f9baefca09..a249299a36d1757967f5e55024ab0d4267c657ab 100644
--- a/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc
+++ b/chrome/browser/chromeos/extensions/quick_unlock_private/quick_unlock_private_api_unittest.cc
@@ -114,10 +114,9 @@ class QuickUnlockPrivateUnitTest : public ExtensionApiUnittest {
base::ListValue* list = nullptr;
EXPECT_TRUE(result->GetAsList(&list));
- // Consume the unique_ptr by reference so we don't take ownership.
- for (const std::unique_ptr<base::Value>& value : (*list)) {
+ for (const base::Value& value : *list) {
std::string mode;
- EXPECT_TRUE(value->GetAsString(&mode));
+ EXPECT_TRUE(value.GetAsString(&mode));
modes.push_back(quick_unlock_private::ParseQuickUnlockMode(mode));
}
@@ -134,9 +133,9 @@ class QuickUnlockPrivateUnitTest : public ExtensionApiUnittest {
base::ListValue* list = nullptr;
EXPECT_TRUE(result->GetAsList(&list));
- for (const std::unique_ptr<base::Value>& value : *list) {
+ for (const base::Value& value : *list) {
std::string mode;
- EXPECT_TRUE(value->GetAsString(&mode));
+ EXPECT_TRUE(value.GetAsString(&mode));
modes.push_back(quick_unlock_private::ParseQuickUnlockMode(mode));
}

Powered by Google App Engine
This is Rietveld 408576698