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

Unified Diff: components/policy/core/browser/url_blacklist_manager_unittest.cc

Issue 1548203002: Convert Pass()→std::move() in //components/[n-z]* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix bad headers Created 5 years 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/policy/core/browser/url_blacklist_manager_unittest.cc
diff --git a/components/policy/core/browser/url_blacklist_manager_unittest.cc b/components/policy/core/browser/url_blacklist_manager_unittest.cc
index 734ae217b7a6683a845abf4c1164ef30bbe540b2..5e6e7f5fdad3f6ce7daf54fda7709e91b0263732 100644
--- a/components/policy/core/browser/url_blacklist_manager_unittest.cc
+++ b/components/policy/core/browser/url_blacklist_manager_unittest.cc
@@ -5,8 +5,8 @@
#include "components/policy/core/browser/url_blacklist_manager.h"
#include <stdint.h>
-
#include <ostream>
+#include <utility>
#include "base/bind.h"
#include "base/callback.h"
@@ -57,13 +57,13 @@ class TestingURLBlacklistManager : public URLBlacklistManager {
scoped_ptr<base::ListValue> block(new base::ListValue);
block->Append(new base::StringValue("example.com"));
scoped_ptr<base::ListValue> allow(new base::ListValue);
- URLBlacklistManager::UpdateOnIO(block.Pass(), allow.Pass());
+ URLBlacklistManager::UpdateOnIO(std::move(block), std::move(allow));
}
// URLBlacklistManager overrides:
void SetBlacklist(scoped_ptr<URLBlacklist> blacklist) override {
set_blacklist_called_ = true;
- URLBlacklistManager::SetBlacklist(blacklist.Pass());
+ URLBlacklistManager::SetBlacklist(std::move(blacklist));
}
void Update() override {
@@ -642,7 +642,7 @@ TEST_F(URLBlacklistManagerTest, DontBlockResources) {
scoped_ptr<base::ListValue> blocked(new base::ListValue);
blocked->Append(new base::StringValue("google.com"));
blacklist->Block(blocked.get());
- blacklist_manager_->SetBlacklist(blacklist.Pass());
+ blacklist_manager_->SetBlacklist(std::move(blacklist));
EXPECT_TRUE(blacklist_manager_->IsURLBlocked(GURL("http://google.com")));
int reason = net::ERR_UNEXPECTED;

Powered by Google App Engine
This is Rietveld 408576698