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

Side by Side Diff: content/browser/net/quota_policy_cookie_store_unittest.cc

Issue 1874893002: Convert //content/browser from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/bind.h" 5 #include "base/bind.h"
6 #include "base/files/file_util.h" 6 #include "base/files/file_util.h"
7 #include "base/files/scoped_temp_dir.h" 7 #include "base/files/scoped_temp_dir.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 114
115 void SetUp() override { 115 void SetUp() override {
116 ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); 116 ASSERT_TRUE(temp_dir_.CreateUniqueTempDir());
117 } 117 }
118 118
119 void TearDown() override { 119 void TearDown() override {
120 DestroyStore(); 120 DestroyStore();
121 } 121 }
122 122
123 TestBrowserThreadBundle bundle_; 123 TestBrowserThreadBundle bundle_;
124 scoped_ptr<base::SequencedWorkerPoolOwner> pool_owner_; 124 std::unique_ptr<base::SequencedWorkerPoolOwner> pool_owner_;
125 base::WaitableEvent loaded_event_; 125 base::WaitableEvent loaded_event_;
126 base::WaitableEvent destroy_event_; 126 base::WaitableEvent destroy_event_;
127 base::ScopedTempDir temp_dir_; 127 base::ScopedTempDir temp_dir_;
128 scoped_refptr<QuotaPolicyCookieStore> store_; 128 scoped_refptr<QuotaPolicyCookieStore> store_;
129 CanonicalCookieVector cookies_; 129 CanonicalCookieVector cookies_;
130 }; 130 };
131 131
132 // Test if data is stored as expected in the QuotaPolicy database. 132 // Test if data is stored as expected in the QuotaPolicy database.
133 TEST_F(QuotaPolicyCookieStoreTest, TestPersistence) { 133 TEST_F(QuotaPolicyCookieStoreTest, TestPersistence) {
134 CanonicalCookieVector cookies; 134 CanonicalCookieVector cookies;
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 // Reload and test for persistence. 280 // Reload and test for persistence.
281 STLDeleteElements(&cookies); 281 STLDeleteElements(&cookies);
282 CreateAndLoad(storage_policy.get(), &cookies); 282 CreateAndLoad(storage_policy.get(), &cookies);
283 EXPECT_EQ(0U, cookies.size()); 283 EXPECT_EQ(0U, cookies.size());
284 284
285 STLDeleteElements(&cookies); 285 STLDeleteElements(&cookies);
286 } 286 }
287 287
288 } // namespace 288 } // namespace
289 } // namespace content 289 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/net/quota_policy_cookie_store.cc ('k') | content/browser/net/view_blob_internals_job_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698