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

Side by Side Diff: test/inspector/debugger/stepping-with-blackboxed-ranges.js

Issue 2633803002: [inspector] implemented blackboxing inside v8 (Closed)
Patch Set: addressed comments Created 3 years, 11 months 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 unified diff | Download patch
« no previous file with comments | « test/inspector/debugger/framework-stepping-expected.txt ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 InspectorTest.addScript( 5 InspectorTest.addScript(
6 `function blackboxedBoo() 6 `function blackboxedBoo()
7 { 7 {
8 var a = 42; 8 var a = 42;
9 var b = foo(); 9 var b = foo();
10 return a + b; 10 return a + b;
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 InspectorTest.log("Try to set positions: " + JSON.stringify(positions)); 83 InspectorTest.log("Try to set positions: " + JSON.stringify(positions));
84 Protocol.Debugger.setBlackboxedRanges({ 84 Protocol.Debugger.setBlackboxedRanges({
85 scriptId: scriptId, 85 scriptId: scriptId,
86 positions: positions 86 positions: positions
87 }).then(setIncorrectRanges.bind(null, scriptId)); 87 }).then(setIncorrectRanges.bind(null, scriptId));
88 } 88 }
89 89
90 function setMixedSourceRanges(scriptId) 90 function setMixedSourceRanges(scriptId)
91 { 91 {
92 Protocol.Debugger.onPaused(runAction); 92 Protocol.Debugger.onPaused(runAction);
93 Protocol.Debugger.setBlackboxedRanges({ 93 Protocol.Debugger
94 scriptId: scriptId, 94 .setBlackboxedRanges({
95 positions: [ { lineNumber: 8, columnNumber: 0 }, { lineNumber: 15, columnNum ber: 0 } ] // blackbox ranges for mixed.js 95 scriptId: scriptId,
96 }).then(runAction); 96 positions: [
97 {lineNumber: 6, columnNumber: 0},
98 {lineNumber: 14, columnNumber: 0}
99 ] // blackbox ranges for mixed.js
100 })
101 .then(runAction);
97 } 102 }
98 103
99 var actions = [ "stepOut", "print", "stepOut", "print", "stepOut", "print", 104 var actions = [ "stepOut", "print", "stepOut", "print", "stepOut", "print",
100 "stepInto", "print", "stepOver", "stepInto", "print", "stepOver", "stepInto" , "print", 105 "stepInto", "print", "stepOver", "stepInto", "print", "stepOver", "stepInto" , "print",
101 "stepOver", "stepInto", "print" ]; 106 "stepOver", "stepInto", "print" ];
102 107
103 function runAction(response) 108 function runAction(response)
104 { 109 {
105 var action = actions.shift(); 110 var action = actions.shift();
106 if (!action) { 111 if (!action) {
(...skipping 12 matching lines...) Expand all
119 124
120 function printCallFrames(callFrames) 125 function printCallFrames(callFrames)
121 { 126 {
122 var topCallFrame = callFrames[0]; 127 var topCallFrame = callFrames[0];
123 if (topCallFrame.functionName.startsWith("blackboxed")) 128 if (topCallFrame.functionName.startsWith("blackboxed"))
124 InspectorTest.log("FAIL: blackboxed function in top call frame"); 129 InspectorTest.log("FAIL: blackboxed function in top call frame");
125 for (var callFrame of callFrames) 130 for (var callFrame of callFrames)
126 InspectorTest.log(callFrame.functionName + ": " + callFrame.location.lineNum ber + ":" + callFrame.location.columnNumber); 131 InspectorTest.log(callFrame.functionName + ": " + callFrame.location.lineNum ber + ":" + callFrame.location.columnNumber);
127 InspectorTest.log(""); 132 InspectorTest.log("");
128 } 133 }
OLDNEW
« no previous file with comments | « test/inspector/debugger/framework-stepping-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698