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

Side by Side Diff: chrome/browser/browsing_data/browsing_data_remover_impl_unittest.cc

Issue 2633663003: Implements strict secure cookies as the default behavior in //net (Closed)
Patch Set: Rebase on ToT Created 3 years, 10 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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 7
8 #include <list> 8 #include <list>
9 #include <memory> 9 #include <memory>
10 #include <set> 10 #include <set>
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 base::Time remove_end; 122 base::Time remove_end;
123 StoragePartition::OriginMatcherFunction origin_matcher; 123 StoragePartition::OriginMatcherFunction origin_matcher;
124 StoragePartition::CookieMatcherFunction cookie_matcher; 124 StoragePartition::CookieMatcherFunction cookie_matcher;
125 125
126 StoragePartitionRemovalData() {} 126 StoragePartitionRemovalData() {}
127 }; 127 };
128 128
129 net::CanonicalCookie CreateCookieWithHost(const GURL& source) { 129 net::CanonicalCookie CreateCookieWithHost(const GURL& source) {
130 std::unique_ptr<net::CanonicalCookie> cookie(net::CanonicalCookie::Create( 130 std::unique_ptr<net::CanonicalCookie> cookie(net::CanonicalCookie::Create(
131 source, "A", "1", std::string(), "/", base::Time::Now(), 131 source, "A", "1", std::string(), "/", base::Time::Now(),
132 base::Time::Now(), false, false, net::CookieSameSite::DEFAULT_MODE, false, 132 base::Time::Now(), false, false, net::CookieSameSite::DEFAULT_MODE,
133 net::COOKIE_PRIORITY_MEDIUM)); 133 net::COOKIE_PRIORITY_MEDIUM));
134 EXPECT_TRUE(cookie); 134 EXPECT_TRUE(cookie);
135 return *cookie; 135 return *cookie;
136 } 136 }
137 137
138 class TestStoragePartition : public StoragePartition { 138 class TestStoragePartition : public StoragePartition {
139 public: 139 public:
140 TestStoragePartition() {} 140 TestStoragePartition() {}
141 ~TestStoragePartition() override {} 141 ~TestStoragePartition() override {}
142 142
(...skipping 1568 matching lines...) Expand 10 before | Expand all | Expand 10 after
1711 EXPECT_TRUE(remover->is_removing()); 1711 EXPECT_TRUE(remover->is_removing());
1712 1712
1713 // Add one more deletion and wait for it. 1713 // Add one more deletion and wait for it.
1714 BlockUntilBrowsingDataRemoved( 1714 BlockUntilBrowsingDataRemoved(
1715 base::Time(), base::Time::Max(), 1715 base::Time(), base::Time::Max(),
1716 BrowsingDataRemover::REMOVE_COOKIES, 1716 BrowsingDataRemover::REMOVE_COOKIES,
1717 BrowsingDataHelper::UNPROTECTED_WEB); 1717 BrowsingDataHelper::UNPROTECTED_WEB);
1718 1718
1719 EXPECT_FALSE(remover->is_removing()); 1719 EXPECT_FALSE(remover->is_removing());
1720 } 1720 }
OLDNEW
« no previous file with comments | « chrome/browser/android/cookies/cookies_fetcher.cc ('k') | chrome/browser/chromeos/login/profile_auth_data.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698