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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/inspector/security/security-blocked-mixed-content-and-malicious.html

Issue 2542533004: Override DevTools security summary when a Safe Browsing warning shows. (Closed)
Patch Set: Address review feedback Created 4 years 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: third_party/WebKit/LayoutTests/http/tests/inspector/security/security-blocked-mixed-content-and-malicious.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/security/security-all-resources-secure.html b/third_party/WebKit/LayoutTests/http/tests/inspector/security/security-blocked-mixed-content-and-malicious.html
similarity index 72%
copy from third_party/WebKit/LayoutTests/http/tests/inspector/security/security-all-resources-secure.html
copy to third_party/WebKit/LayoutTests/http/tests/inspector/security/security-blocked-mixed-content-and-malicious.html
index 68aad98e81591bb00186ee267c72efe61466ebba..90980a54e9ee9638089d6532b4a7cdfe3fc802b7 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/security/security-all-resources-secure.html
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/security/security-blocked-mixed-content-and-malicious.html
@@ -7,20 +7,24 @@ function test()
{
/** @type {!Protocol.Security.InsecureContentStatus} */
var insecureContentStatus = { ranMixedContent: false, displayedMixedContent: false, ranContentWithCertErrors: false, displayedContentWithCertErrors: false, ranInsecureContentStyle: Protocol.Security.SecurityState.Insecure, displayedInsecureContentStyle: Protocol.Security.SecurityState.Neutral };
-
- InspectorTest.mainTarget.model(Security.SecurityModel).dispatchEventToListeners(Security.SecurityModel.Events.SecurityStateChanged, new Security.PageSecurityState(Protocol.Security.SecurityState.Secure, [], insecureContentStatus, true));
+ InspectorTest.mainTarget.model(Security.SecurityModel).dispatchEventToListeners(Security.SecurityModel.Events.SecurityStateChanged, new Security.PageSecurityState(Protocol.Security.SecurityState.Secure, true, [], insecureContentStatus, "Test: Summary Override Text"));
var request = new SDK.NetworkRequest(InspectorTest.mainTarget, 0, "http://foo.test", "https://foo.test", 0, 0, null);
+ request.setBlockedReason(Protocol.Network.BlockedReason.MixedContent);
+ request.mixedContentType = "blockable";
InspectorTest.dispatchRequestFinished(request);
+ InspectorTest.dumpDeepInnerHTML(Security.SecurityPanel._instance()._mainView.contentElement.getElementsByClassName("security-summary-text")[0]);
+
var explanations = Security.SecurityPanel._instance()._mainView.contentElement.getElementsByClassName("security-explanation");
for (var i = 0; i < explanations.length; i++)
InspectorTest.dumpDeepInnerHTML(explanations[i]);
+
InspectorTest.completeTest();
}
</script>
</head>
<body onload="runTest()">
-<p>Tests addition of explanation when all page resources are transferred securely (no-mixed-content).</p>
+<p>Tests active mixed content blocking in the security panel when page is classified as malicious.</p>
</body>
</html>

Powered by Google App Engine
This is Rietveld 408576698