| OLD | NEW |
| (Empty) | |
| 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 |
| 3 // BSD-style license that can be found in the LICENSE file. |
| 4 |
| 5 import 'test_helper.dart'; |
| 6 import 'service_test_common.dart'; |
| 7 |
| 8 const int LINE_A = 13; |
| 9 const String file = "next_through_call_on_field_test.dart"; |
| 10 |
| 11 var foo; |
| 12 |
| 13 code() { |
| 14 foo = fooMethod; |
| 15 fooMethod(); |
| 16 foo(); |
| 17 } |
| 18 |
| 19 void fooMethod() { |
| 20 print("Hello from fooMethod"); |
| 21 } |
| 22 |
| 23 List<String> stops = []; |
| 24 List<String> expected = [ |
| 25 "$file:${LINE_A+0}:5", // after "code", i.e. on "(" |
| 26 "$file:${LINE_A+1}:3", // on "foo" |
| 27 "$file:${LINE_A+2}:3", // on "fooMethod" |
| 28 "$file:${LINE_A+3}:6", // after "foo" (on invisible ".call") |
| 29 "$file:${LINE_A+4}:1" // on ending '}' |
| 30 ]; |
| 31 |
| 32 var tests = [ |
| 33 hasPausedAtStart, |
| 34 setBreakpointAtLine(LINE_A), |
| 35 runStepThroughProgramRecordingStops(stops), |
| 36 checkRecordedStops(stops, expected) |
| 37 ]; |
| 38 |
| 39 main(args) { |
| 40 runIsolateTestsSynchronous(args, tests, |
| 41 testeeConcurrent: code, pause_on_start: true, pause_on_exit: true); |
| 42 } |
| OLD | NEW |