Commit 59379011 authored by Tarun Bansal's avatar Tarun Bansal Committed by Commit Bot

Enable ClientHintsPersistent feature (Accept-CH-Lifetime header).

blink-dev i2s thread: https://groups.google.com/a/chromium.org/d/topic/blink-dev/8RBFue7RMXQ/discussion

Bug: 735518,782381,816661
Change-Id: Ic7c8a6a0eaf323d3ab736ac8e3ad2d23104ae0cb
Reviewed-on: https://chromium-review.googlesource.com/969407Reviewed-by: default avatarKinuko Yasuda <kinuko@chromium.org>
Commit-Queue: Tarun Bansal <tbansal@chromium.org>
Cr-Commit-Position: refs/heads/master@{#544285}
parent 052b968e
......@@ -721,6 +721,10 @@ IN_PROC_BROWSER_TEST_F(ClientHintsBrowserTest,
->GetSettingsForOneType(CONTENT_SETTINGS_TYPE_CLIENT_HINTS, std::string(),
&host_settings);
EXPECT_EQ(1u, host_settings.size());
// Clear settings.
HostContentSettingsMapFactory::GetForProfile(browser()->profile())
->ClearSettingsForOneType(CONTENT_SETTINGS_TYPE_JAVASCRIPT);
}
// Ensure that when the JavaScript is blocked, persisted client hints are not
......@@ -848,6 +852,10 @@ IN_PROC_BROWSER_TEST_F(ClientHintsBrowserTest,
EXPECT_EQ(3u, count_client_hints_headers_seen());
EXPECT_EQ(3u, third_party_request_count_seen());
EXPECT_EQ(0u, third_party_client_hints_count_seen());
// Clear settings.
HostContentSettingsMapFactory::GetForProfile(browser()->profile())
->ClearSettingsForOneType(CONTENT_SETTINGS_TYPE_JAVASCRIPT);
}
// Ensure that when the cookies is blocked, client hints are not attached to the
......@@ -905,6 +913,10 @@ IN_PROC_BROWSER_TEST_F(ClientHintsBrowserTest,
EXPECT_EQ(3u, count_client_hints_headers_seen());
EXPECT_EQ(3u, third_party_request_count_seen());
EXPECT_EQ(0u, third_party_client_hints_count_seen());
// Clear settings.
HostContentSettingsMapFactory::GetForProfile(browser()->profile())
->ClearSettingsForOneType(CONTENT_SETTINGS_TYPE_COOKIES);
}
// Check the client hints for the given URL in an incognito window.
......
......@@ -188,7 +188,7 @@
},
{
name: "ClientHintsPersistent",
status: "experimental",
status: "stable",
},
{
name: "ClientPlaceholdersForServerLoFi",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment