OLD | NEW |
---|---|
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 // VMOptions=--error_on_bad_type --error_on_bad_override --verbose_debug | 4 // VMOptions=--error_on_bad_type --error_on_bad_override --verbose_debug |
5 | 5 |
6 import 'package:observatory/service_io.dart'; | |
7 import 'service_test_common.dart'; | 6 import 'service_test_common.dart'; |
8 import 'dart:async'; | |
9 import 'test_helper.dart'; | 7 import 'test_helper.dart'; |
10 import 'dart:developer'; | 8 import 'dart:developer'; |
11 | 9 |
12 const int LINE_A = 19; | 10 const int LINE_A = 19; |
Cutch
2016/11/15 22:17:12
here too
kevmoo
2016/11/15 23:00:36
Done.
| |
13 const int LINE_B = 20; | 11 const int LINE_B = 20; |
14 | 12 |
15 var libVariable; | 13 var libVariable; |
16 | 14 |
17 testMain() { | 15 testMain() { |
18 debugger(); | 16 debugger(); |
19 print("Before"); // LINE_A | 17 print("Before"); // LINE_A |
20 libVariable = 0; // LINE_B | 18 libVariable = 0; // LINE_B |
21 print("and after"); | 19 print("and after"); |
22 } | 20 } |
23 | 21 |
24 var tests = [ | 22 var tests = [ |
25 hasStoppedAtBreakpoint, | 23 hasStoppedAtBreakpoint, |
26 stoppedAtLine(LINE_A), | 24 stoppedAtLine(LINE_A), |
27 stepOver, | 25 stepOver, |
28 // Check that debugger stops at assignment to top-level variable. | 26 // Check that debugger stops at assignment to top-level variable. |
29 stoppedAtLine(LINE_B), | 27 stoppedAtLine(LINE_B), |
30 resumeIsolate, | 28 resumeIsolate, |
31 ]; | 29 ]; |
32 | 30 |
33 main(args) => runIsolateTests(args, tests, testeeConcurrent: testMain); | 31 main(args) => runIsolateTests(args, tests, testeeConcurrent: testMain); |
OLD | NEW |