OLD | NEW |
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, 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 --asyn
c_debugger | 4 // VMOptions=--error_on_bad_type --error_on_bad_override --verbose_debug --asyn
c_debugger |
5 | 5 |
6 import 'dart:developer'; | 6 import 'dart:developer'; |
7 import 'package:observatory/models.dart' as M; | |
8 import 'package:observatory/service_io.dart'; | |
9 import 'package:unittest/unittest.dart'; | |
10 import 'service_test_common.dart'; | 7 import 'service_test_common.dart'; |
11 import 'test_helper.dart'; | 8 import 'test_helper.dart'; |
12 | 9 |
13 const LINE_A = 24; | 10 const LINE_A = 21; |
14 const LINE_B = 25; | 11 const LINE_B = 22; |
15 const LINE_C = 29; | 12 const LINE_C = 26; |
16 const LINE_D = 32; | 13 const LINE_D = 29; |
17 const LINE_E = 39; | 14 const LINE_E = 36; |
18 const LINE_F = 40; | 15 const LINE_F = 37; |
19 const LINE_G = 41; | 16 const LINE_G = 38; |
20 const LINE_H = 30; | 17 const LINE_H = 27; |
21 const LINE_I = 34; | 18 const LINE_I = 31; |
22 | 19 |
23 foobar() async* { | 20 foobar() async* { |
24 yield 1; // LINE_A. | 21 yield 1; // LINE_A. |
25 yield 2; // LINE_B. | 22 yield 2; // LINE_B. |
26 } | 23 } |
27 | 24 |
28 helper() async { | 25 helper() async { |
29 print('helper'); // LINE_C. | 26 print('helper'); // LINE_C. |
30 await for (var i in foobar()) { // LINE_H. | 27 await for (var i in foobar()) { // LINE_H. |
31 debugger(); | 28 debugger(); |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 stoppedAtLine(LINE_H), // await for. | 78 stoppedAtLine(LINE_H), // await for. |
82 stepInto, | 79 stepInto, |
83 hasStoppedAtBreakpoint, | 80 hasStoppedAtBreakpoint, |
84 stepOut, // step out of generator. | 81 stepOut, // step out of generator. |
85 hasStoppedAtBreakpoint, | 82 hasStoppedAtBreakpoint, |
86 stoppedAtLine(LINE_I), // return null. | 83 stoppedAtLine(LINE_I), // return null. |
87 ]; | 84 ]; |
88 | 85 |
89 main(args) => | 86 main(args) => |
90 runIsolateTestsSynchronous(args, tests, testeeConcurrent: testMain); | 87 runIsolateTestsSynchronous(args, tests, testeeConcurrent: testMain); |
OLD | NEW |