| OLD | NEW |
| (Empty) |
| 1 <html> | |
| 2 <head> | |
| 3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto
r-protocol-test.js"></script> | |
| 4 <script> | |
| 5 | |
| 6 function load() | |
| 7 { | |
| 8 document.querySelector("iframe").src = "../resources/blank.html"; | |
| 9 } | |
| 10 | |
| 11 function test() | |
| 12 { | |
| 13 InspectorTest.eventHandler["Page.frameScheduledNavigation"] = onScheduled; | |
| 14 InspectorTest.eventHandler["Page.frameStartedLoading"] = onStarted; | |
| 15 InspectorTest.eventHandler["Page.frameClearedScheduledNavigation"] = onClear
ed; | |
| 16 InspectorTest.sendCommand("Page.enable", {}); | |
| 17 | |
| 18 function onScheduled(msg) | |
| 19 { | |
| 20 InspectorTest.log("Scheduled navigation with delay " + msg.params.delay)
; | |
| 21 } | |
| 22 | |
| 23 function onStarted(msg) | |
| 24 { | |
| 25 // This event should be received before the scheduled navigation is clea
red. | |
| 26 InspectorTest.log("Started loading"); | |
| 27 } | |
| 28 | |
| 29 function onCleared(msg) | |
| 30 { | |
| 31 InspectorTest.log("Cleared scheduled navigation"); | |
| 32 InspectorTest.completeTest(); | |
| 33 } | |
| 34 | |
| 35 InspectorTest.sendCommand("Runtime.evaluate", { "expression": "load()" }); | |
| 36 } | |
| 37 | |
| 38 </script> | |
| 39 </head> | |
| 40 <body onload="runTest()"> | |
| 41 <iframe> | |
| 42 </body> | |
| 43 </html> | |
| OLD | NEW |