| <script src="../../http/tests/inspector/resources/protocol-test.js"></script> |
| <script src="resources/breakpoint.js"></script> |
| // Put this here instead of on <body onload> to prevent an extra Debugger.scriptParsed event. |
| // This test setting 2 breakpoints in DFG compiled functions: one inlined, |
| InspectorProtocol.sendCommand("Debugger.enable", {}); |
| var breakpointFound = false; |
| InspectorProtocol.eventHandler["Debugger.scriptParsed"] = function(messageObject) |
| if (/resources\/breakpoint\.js$/.test(messageObject.params.url)) { |
| ProtocolTest.log("Found breakpoint.js"); |
| InspectorProtocol.sendCommand("Runtime.evaluate", { |
| expression: "debuggerStatement();" |
| }, function(responseObject) { |
| ProtocolTest.log("PASS"); |
| ProtocolTest.completeTest(); |
| InspectorProtocol.eventHandler["Debugger.paused"] = function(messageObject) |
| ProtocolTest.log("Broke at debugger statement\n"); |
| InspectorProtocol.sendCommand("Debugger.resume", {}); |
| <p>Debugger statement should break in debugger.</p> |