OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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 // Flags: --expose-debug-as debug --harmony-default-parameters | 5 // Flags: --expose-debug-as debug |
6 | 6 |
7 // Get the Debug object exposed from the debug context global object. | 7 // Get the Debug object exposed from the debug context global object. |
8 Debug = debug.Debug | 8 Debug = debug.Debug |
9 | 9 |
10 listenerComplete = false; | 10 listenerComplete = false; |
11 breakPointCount = 0; | 11 breakPointCount = 0; |
12 | 12 |
13 function listener(event, exec_state, event_data, data) { | 13 function listener(event, exec_state, event_data, data) { |
14 if (event == Debug.DebugEvent.Break) { | 14 if (event == Debug.DebugEvent.Break) { |
15 breakPointCount++; | 15 breakPointCount++; |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 b = a("default"), | 49 b = a("default"), |
50 c = (function() { debugger; })()) { | 50 c = (function() { debugger; })()) { |
51 var d = 'local'; | 51 var d = 'local'; |
52 debugger; | 52 debugger; |
53 }; | 53 }; |
54 | 54 |
55 f(); | 55 f(); |
56 | 56 |
57 // Make sure that the debug event listener vas invoked. | 57 // Make sure that the debug event listener vas invoked. |
58 assertEquals(3, breakPointCount); | 58 assertEquals(3, breakPointCount); |
OLD | NEW |