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

Unified Diff: net/extras/sqlite/sqlite_persistent_cookie_store_perftest.cc

Issue 2383393002: Remove stl_util's deletion functions from net/cookies/ and net/extras/. (Closed)
Patch Set: removing Created 4 years, 2 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: net/extras/sqlite/sqlite_persistent_cookie_store_perftest.cc
diff --git a/net/extras/sqlite/sqlite_persistent_cookie_store_perftest.cc b/net/extras/sqlite/sqlite_persistent_cookie_store_perftest.cc
index 2af8d0371465d6defff9245a488a80ef481791db..60a03f5854a56a119fc20d27b714470fca1a2a21 100644
--- a/net/extras/sqlite/sqlite_persistent_cookie_store_perftest.cc
+++ b/net/extras/sqlite/sqlite_persistent_cookie_store_perftest.cc
@@ -39,13 +39,13 @@ class SQLitePersistentCookieStorePerfTest : public testing::Test {
key_loaded_event_(base::WaitableEvent::ResetPolicy::AUTOMATIC,
base::WaitableEvent::InitialState::NOT_SIGNALED) {}
- void OnLoaded(const std::vector<CanonicalCookie*>& cookies) {
- cookies_ = cookies;
+ void OnLoaded(std::vector<std::unique_ptr<CanonicalCookie>> cookies) {
+ cookies_.swap(cookies);
loaded_event_.Signal();
}
- void OnKeyLoaded(const std::vector<CanonicalCookie*>& cookies) {
- cookies_ = cookies;
+ void OnKeyLoaded(std::vector<std::unique_ptr<CanonicalCookie>> cookies) {
+ cookies_.swap(cookies);
key_loaded_event_.Signal();
}
@@ -109,12 +109,12 @@ class SQLitePersistentCookieStorePerfTest : public testing::Test {
std::unique_ptr<base::SequencedWorkerPoolOwner> pool_owner_;
base::WaitableEvent loaded_event_;
base::WaitableEvent key_loaded_event_;
- std::vector<CanonicalCookie*> cookies_;
+ std::vector<std::unique_ptr<CanonicalCookie>> cookies_;
base::ScopedTempDir temp_dir_;
scoped_refptr<SQLitePersistentCookieStore> store_;
};
-// Test the performance of priority load of cookies for a specfic domain key
+// Test the performance of priority load of cookies for a specific domain key
TEST_F(SQLitePersistentCookieStorePerfTest, TestLoadForKeyPerformance) {
for (int domain_num = 0; domain_num < 3; ++domain_num) {
std::string domain_name(base::StringPrintf("domain_%d.com", domain_num));
« no previous file with comments | « net/extras/sqlite/sqlite_persistent_cookie_store.cc ('k') | net/extras/sqlite/sqlite_persistent_cookie_store_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698