OLD | NEW |
1 <html> | 1 <html> |
2 <head> | 2 <head> |
3 <script src="../inspector-test.js"></script> | 3 <script src="../inspector-test.js"></script> |
4 <script src="../security-test.js"></script> | 4 <script src="../security-test.js"></script> |
5 <script> | 5 <script> |
6 function test() | 6 function test() |
7 { | 7 { |
8 var request1 = new SDK.NetworkRequest(InspectorTest.mainTarget, 0, "https://
foo.test/", "https://foo.test", 0, 0, null); | 8 var request1 = new SDK.NetworkRequest(InspectorTest.networkManager, Inspecto
rTest.NetworkAgent, 0, "https://foo.test/", "https://foo.test", 0, 0, null); |
9 request1.setSecurityState(Protocol.Security.SecurityState.Secure); | 9 request1.setSecurityState(Protocol.Security.SecurityState.Secure); |
10 InspectorTest.dispatchRequestFinished(request1); | 10 InspectorTest.dispatchRequestFinished(request1); |
11 | 11 |
12 InspectorTest.addResult("Before selecting origin view:"); | 12 InspectorTest.addResult("Before selecting origin view:"); |
13 InspectorTest.dumpDeepInnerHTML(Security.SecurityPanel._instance()._visibleV
iew.contentElement); | 13 InspectorTest.dumpDeepInnerHTML(Security.SecurityPanel._instance()._visibleV
iew.contentElement); |
14 | 14 |
15 Security.SecurityPanel._instance()._sidebarTree._elementsByOrigin.get("https
://foo.test").select(); | 15 Security.SecurityPanel._instance()._sidebarTree._elementsByOrigin.get("https
://foo.test").select(); |
16 | 16 |
17 InspectorTest.addResult("Panel on origin view before interstitial:"); | 17 InspectorTest.addResult("Panel on origin view before interstitial:"); |
18 InspectorTest.dumpDeepInnerHTML(Security.SecurityPanel._instance()._visibleV
iew.contentElement); | 18 InspectorTest.dumpDeepInnerHTML(Security.SecurityPanel._instance()._visibleV
iew.contentElement); |
19 | 19 |
20 // Test that the panel transitions to an origin view when an interstitial is
shown. https://crbug.com/559150 | 20 // Test that the panel transitions to an origin view when an interstitial is
shown. https://crbug.com/559150 |
21 InspectorTest.mainTarget.model(SDK.ResourceTreeModel).dispatchEventToListene
rs(SDK.ResourceTreeModel.Events.InterstitialShown); | 21 InspectorTest.mainTarget.model(SDK.ResourceTreeModel).dispatchEventToListene
rs(SDK.ResourceTreeModel.Events.InterstitialShown); |
22 InspectorTest.addResult("After interstitial is shown:"); | 22 InspectorTest.addResult("After interstitial is shown:"); |
23 InspectorTest.dumpDeepInnerHTML(Security.SecurityPanel._instance()._visibleV
iew.contentElement); | 23 InspectorTest.dumpDeepInnerHTML(Security.SecurityPanel._instance()._visibleV
iew.contentElement); |
24 | 24 |
25 InspectorTest.completeTest(); | 25 InspectorTest.completeTest(); |
26 } | 26 } |
27 </script> | 27 </script> |
28 </head> | 28 </head> |
29 <body onload="runTest()"> | 29 <body onload="runTest()"> |
30 <p>Tests that the panel transitions to the overview view when navigating | 30 <p>Tests that the panel transitions to the overview view when navigating |
31 to an interstitial. Regression test for https://crbug.com/638601</p> | 31 to an interstitial. Regression test for https://crbug.com/638601</p> |
32 </body> | 32 </body> |
33 </html> | 33 </html> |
OLD | NEW |