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

Unified Diff: net/cookies/cookie_monster_store_test.cc

Issue 1893083002: Change scoped_ptr to std::unique_ptr in //net. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptr-net-all: iwyu Created 4 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
« no previous file with comments | « net/cookies/cookie_monster_store_test.h ('k') | net/cookies/cookie_monster_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cookies/cookie_monster_store_test.cc
diff --git a/net/cookies/cookie_monster_store_test.cc b/net/cookies/cookie_monster_store_test.cc
index 4573d4ad881d2464b3f7712d85f92673d4e0776f..5fef35cddd22950d0b085386a3a2f9756c2cde65 100644
--- a/net/cookies/cookie_monster_store_test.cc
+++ b/net/cookies/cookie_monster_store_test.cc
@@ -6,6 +6,7 @@
#include "base/bind.h"
#include "base/location.h"
+#include "base/memory/ptr_util.h"
#include "base/single_thread_task_runner.h"
#include "base/strings/stringprintf.h"
#include "base/thread_task_runner_handle.h"
@@ -123,7 +124,7 @@ void MockCookieMonsterDelegate::OnCookieChanged(
MockCookieMonsterDelegate::~MockCookieMonsterDelegate() {
}
-scoped_ptr<CanonicalCookie> BuildCanonicalCookie(
+std::unique_ptr<CanonicalCookie> BuildCanonicalCookie(
const GURL& url,
const std::string& cookie_line,
const base::Time& creation_time) {
@@ -151,7 +152,7 @@ void AddCookieToList(const GURL& url,
const std::string& cookie_line,
const base::Time& creation_time,
std::vector<CanonicalCookie*>* out_list) {
- scoped_ptr<CanonicalCookie> cookie(
+ std::unique_ptr<CanonicalCookie> cookie(
BuildCanonicalCookie(url, cookie_line, creation_time));
out_list->push_back(cookie.release());
@@ -219,7 +220,7 @@ void MockSimplePersistentCookieStore::Flush(const base::Closure& callback) {
void MockSimplePersistentCookieStore::SetForceKeepSessionState() {
}
-scoped_ptr<CookieMonster> CreateMonsterFromStoreForGC(
+std::unique_ptr<CookieMonster> CreateMonsterFromStoreForGC(
int num_secure_cookies,
int num_old_secure_cookies,
int num_non_secure_cookies,
@@ -258,7 +259,7 @@ scoped_ptr<CookieMonster> CreateMonsterFromStoreForGC(
store->AddCookie(cc);
}
- return make_scoped_ptr(new CookieMonster(store.get(), nullptr));
+ return base::WrapUnique(new CookieMonster(store.get(), nullptr));
}
MockSimplePersistentCookieStore::~MockSimplePersistentCookieStore() {
« no previous file with comments | « net/cookies/cookie_monster_store_test.h ('k') | net/cookies/cookie_monster_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698