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

Unified Diff: extensions/browser/guest_view/web_view/web_view_apitest.cc

Issue 2702503002: Block renderer-initiated main frame navigations to data URLs (Closed)
Patch Set: Re-block data to data navigations, rebase, address nasko comments Created 3 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 side-by-side diff with in-line comments
Download patch
Index: extensions/browser/guest_view/web_view/web_view_apitest.cc
diff --git a/extensions/browser/guest_view/web_view/web_view_apitest.cc b/extensions/browser/guest_view/web_view/web_view_apitest.cc
index fe742323629f736b579110c7d4204ea8ed21c9f2..96c0cd52ff8135dea3e03e0fc7b3635202263e40 100644
--- a/extensions/browser/guest_view/web_view/web_view_apitest.cc
+++ b/extensions/browser/guest_view/web_view/web_view_apitest.cc
@@ -544,8 +544,10 @@ IN_PROC_BROWSER_TEST_F(WebViewAPITest, TestExecuteScriptFail) {
IN_PROC_BROWSER_TEST_F(
WebViewAPITest,
MAYBE_TestExecuteScriptIsAbortedWhenWebViewSourceIsChanged) {
- RunTest("testExecuteScriptIsAbortedWhenWebViewSourceIsChanged",
- "web_view/apitest");
+ std::string app_location = "web_view/apitest";
+ StartTestServer(app_location);
+ RunTest("testExecuteScriptIsAbortedWhenWebViewSourceIsChanged", app_location);
+ StopTestServer();
}
IN_PROC_BROWSER_TEST_F(WebViewAPITest, TestFindAPI) {
@@ -640,6 +642,11 @@ IN_PROC_BROWSER_TEST_F(WebViewAPITest, TestNewWindow) {
StopTestServer();
}
+IN_PROC_BROWSER_TEST_F(WebViewAPITest,
+ TestContentInitiatedNavigationToDataUrlBlocked) {
+ RunTest("testContentInitiatedNavigationToDataUrlBlocked", "web_view/apitest");
+}
+
IN_PROC_BROWSER_TEST_F(WebViewAPITest, TestNewWindowNoPreventDefault) {
std::string app_location = "web_view/apitest";
StartTestServer(app_location);

Powered by Google App Engine
This is Rietveld 408576698