OLD | NEW |
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 let {session, contextGroup, Protocol} = InspectorTest.start('Tests Debugger.setS
criptSource'); |
| 6 |
| 7 contextGroup.addScript( |
6 `function TestExpression(a, b) { | 8 `function TestExpression(a, b) { |
7 return a + b; | 9 return a + b; |
8 }`); | 10 }`); |
9 | 11 |
10 // A general-purpose engine for sending a sequence of protocol commands. | 12 // A general-purpose engine for sending a sequence of protocol commands. |
11 // The clients provide requests and response handlers, while the engine catches | 13 // The clients provide requests and response handlers, while the engine catches |
12 // errors and makes sure that once there's nothing to do completeTest() is calle
d. | 14 // errors and makes sure that once there's nothing to do completeTest() is calle
d. |
13 // @param step is an object with command, params and callback fields | 15 // @param step is an object with command, params and callback fields |
14 function runRequestSeries(step) { | 16 function runRequestSeries(step) { |
15 processStep(step); | 17 processStep(step); |
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 | 145 |
144 function errorCallbackSetScriptSource2(result) { | 146 function errorCallbackSetScriptSource2(result) { |
145 var exceptionDetails = result.exceptionDetails; | 147 var exceptionDetails = result.exceptionDetails; |
146 logCheck("Has error reported", !!exceptionDetails); | 148 logCheck("Has error reported", !!exceptionDetails); |
147 logCheck("Reported error is a compile error", !!exceptionDetails); | 149 logCheck("Reported error is a compile error", !!exceptionDetails); |
148 if (exceptionDetails) | 150 if (exceptionDetails) |
149 logEqualsCheck(exceptionDetails.lineNumber, 1); | 151 logEqualsCheck(exceptionDetails.lineNumber, 1); |
150 return next; | 152 return next; |
151 } | 153 } |
152 } | 154 } |
OLD | NEW |