Index: third_party/WebKit/LayoutTests/inspector-protocol/debugger/stepping-with-blackbox-ranges.html |
diff --git a/third_party/WebKit/LayoutTests/inspector-protocol/debugger/stepping-with-blackboxed-ranges.html b/third_party/WebKit/LayoutTests/inspector-protocol/debugger/stepping-with-blackbox-ranges.html |
similarity index 83% |
rename from third_party/WebKit/LayoutTests/inspector-protocol/debugger/stepping-with-blackboxed-ranges.html |
rename to third_party/WebKit/LayoutTests/inspector-protocol/debugger/stepping-with-blackbox-ranges.html |
index e31f5967256066e6ecd2de62c035983efa50f194..8c7830f5621a9c9d90feb87e0b524a96be1063d9 100644 |
--- a/third_party/WebKit/LayoutTests/inspector-protocol/debugger/stepping-with-blackboxed-ranges.html |
+++ b/third_party/WebKit/LayoutTests/inspector-protocol/debugger/stepping-with-blackbox-ranges.html |
@@ -19,9 +19,17 @@ function foo() |
<script> |
function test() |
{ |
+ var scriptIdToHash = new Map(); |
+ |
InspectorTest.eventHandler["Debugger.paused"] = setBlackboxedScriptRanges; |
+ InspectorTest.eventHandler["Debugger.scriptParsed"] = scriptParsed; |
InspectorTest.sendCommandOrDie("Debugger.enable", {}, callTestFunction); |
+ function scriptParsed(response) |
+ { |
+ scriptIdToHash.set(response.params.scriptId, response.params.hash); |
+ } |
+ |
function callTestFunction(response) |
{ |
InspectorTest.evaluateInInspectedPage("setTimeout(testFunction, 0);"); |
@@ -31,8 +39,9 @@ function test() |
{ |
var callFrames = response.params.callFrames; |
printCallFrames(callFrames); |
- InspectorTest.sendCommand("Debugger.setBlackboxedRanges", { |
- scriptId: callFrames[1].location.scriptId, |
+ var hash = scriptIdToHash.get(callFrames[1].location.scriptId); |
+ InspectorTest.sendCommand("Debugger.addBlackboxRanges", { |
+ hash: hash, |
positions: [ { line: 0, column: 0 } ] // blackbox ranges for blackboxed.js |
}, setIncorrectRanges.bind(null, callFrames[2].location.scriptId)); |
} |
@@ -53,8 +62,8 @@ function test() |
return; |
} |
InspectorTest.log("Try to set positions: " + JSON.stringify(positions)); |
- InspectorTest.sendCommand("Debugger.setBlackboxedRanges", { |
- scriptId: scriptId, |
+ InspectorTest.sendCommand("Debugger.addBlackboxRanges", { |
+ hash: scriptIdToHash.get(scriptId), |
positions: positions |
}, setIncorrectRanges.bind(null, scriptId)); |
} |
@@ -62,8 +71,8 @@ function test() |
function setMixedSourceRanges(scriptId) |
{ |
InspectorTest.eventHandler["Debugger.paused"] = runAction; |
- InspectorTest.sendCommandOrDie("Debugger.setBlackboxedRanges", { |
- scriptId: scriptId, |
+ InspectorTest.sendCommandOrDie("Debugger.addBlackboxRanges", { |
+ hash: scriptIdToHash.get(scriptId), |
positions: [ { line: 8, column: 0 }, { line: 15, column: 0 } ] // blackbox ranges for mixed.js |
}, runAction); |
} |