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

Unified Diff: chrome/browser/content_settings/cookie_settings_unittest.cc

Issue 8479027: Make third-party cookie blocking strict by default (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 9 years, 1 month 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 | « chrome/browser/content_settings/cookie_settings.cc ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/content_settings/cookie_settings_unittest.cc
diff --git a/chrome/browser/content_settings/cookie_settings_unittest.cc b/chrome/browser/content_settings/cookie_settings_unittest.cc
index af8421992d74212154ff460e15acaa44e9a1f1e5..d68f446ce4e8664dab0a460ec39095b4895a357d 100644
--- a/chrome/browser/content_settings/cookie_settings_unittest.cc
+++ b/chrome/browser/content_settings/cookie_settings_unittest.cc
@@ -54,7 +54,7 @@ TEST_F(CookieSettingsTest, CookiesBlockThirdParty) {
TestingProfile profile;
CookieSettings* cookie_settings = CookieSettings::GetForProfile(&profile);
profile.GetPrefs()->SetBoolean(prefs::kBlockThirdPartyCookies, true);
- EXPECT_TRUE(cookie_settings->IsReadingCookieAllowed(
+ EXPECT_FALSE(cookie_settings->IsReadingCookieAllowed(
kBlockedSite, kFirstPartySite));
EXPECT_FALSE(cookie_settings->IsCookieSessionOnly(kBlockedSite));
EXPECT_FALSE(cookie_settings->IsSettingCookieAllowed(
@@ -62,9 +62,9 @@ TEST_F(CookieSettingsTest, CookiesBlockThirdParty) {
CommandLine* cmd = CommandLine::ForCurrentProcess();
AutoReset<CommandLine> auto_reset(cmd, *cmd);
- cmd->AppendSwitch(switches::kBlockReadingThirdPartyCookies);
+ cmd->AppendSwitch(switches::kOnlyBlockSettingThirdPartyCookies);
- EXPECT_FALSE(cookie_settings->IsReadingCookieAllowed(
+ EXPECT_TRUE(cookie_settings->IsReadingCookieAllowed(
kBlockedSite, kFirstPartySite));
EXPECT_FALSE(cookie_settings->IsSettingCookieAllowed(
kBlockedSite, kFirstPartySite));
@@ -136,14 +136,6 @@ TEST_F(CookieSettingsTest, CookiesThirdPartyBlockedExplicitAllow) {
EXPECT_TRUE(cookie_settings->IsSettingCookieAllowed(
kAllowedSite, kExtensionURL));
- CommandLine* cmd = CommandLine::ForCurrentProcess();
- AutoReset<CommandLine> auto_reset(cmd, *cmd);
- cmd->AppendSwitch(switches::kBlockReadingThirdPartyCookies);
-
- EXPECT_TRUE(cookie_settings->IsReadingCookieAllowed(
- kAllowedSite, kFirstPartySite));
- EXPECT_FALSE(cookie_settings->IsCookieSessionOnly(kAllowedSite));
-
// Extensions should always be allowed to use cookies.
EXPECT_TRUE(cookie_settings->IsReadingCookieAllowed(
kAllowedSite, kExtensionURL));
« no previous file with comments | « chrome/browser/content_settings/cookie_settings.cc ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698