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 // Flags: --expose-debug-as debug | |
6 | 5 |
7 Debug = debug.Debug | 6 Debug = debug.Debug |
8 | 7 |
9 function BestEditor() { | 8 function BestEditor() { |
10 throw 'Emacs'; | 9 throw 'Emacs'; |
11 } | 10 } |
12 | 11 |
13 var exception = null; | 12 var exception = null; |
14 var results = []; | 13 var results = []; |
15 var log = [] | 14 var log = [] |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 Debug.setListener(null); | 57 Debug.setListener(null); |
59 | 58 |
60 assertNull(exception); | 59 assertNull(exception); |
61 assertEquals(["Emacs", "Eclipse", "Vim"], results); | 60 assertEquals(["Emacs", "Eclipse", "Vim"], results); |
62 print(JSON.stringify(log, 1)); | 61 print(JSON.stringify(log, 1)); |
63 assertEquals([ | 62 assertEquals([ |
64 " throw 'Emacs';", | 63 " throw 'Emacs';", |
65 " throw 'Eclipse';", | 64 " throw 'Eclipse';", |
66 " throw 'Vim';", | 65 " throw 'Vim';", |
67 ], log); | 66 ], log); |
OLD | NEW |