Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(872)

Side by Side Diff: runtime/observatory/tests/service/next_through_catch_test.dart

Issue 2680303002: Kernel debugging; service tests (Closed)
Patch Set: Address comments Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(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 = 12;
9 const String file = "next_through_catch_test.dart";
10
11 code() {
12 try {
13 var value = "world";
14 throw "Hello, $value";
15 } catch(e, st) {
16 print(e);
17 print(st);
18 }
19 try {
20 throw "Hello, world";
21 } catch(e, st) {
22 print(e);
23 print(st);
24 }
25 }
26
27 List<String> stops = [];
28 List<String> expected = [
29 "$file:${LINE_A+1}:15", // on '='
30 "$file:${LINE_A+2}:26", // after last '"' (i.e. before ';')
31 "$file:${LINE_A+4}:5", // on call to 'print'
32 "$file:${LINE_A+5}:5", // on call to 'print'
33 "$file:${LINE_A+8}:5", // on 'throw'
34 "$file:${LINE_A+10}:5", // on call to 'print'
35 "$file:${LINE_A+11}:5", // on call to 'print'
36 "$file:${LINE_A+13}:1" // on ending '}'
37 ];
38
39 var tests = [
40 hasPausedAtStart,
41 setBreakpointAtLine(LINE_A),
42 runStepThroughProgramRecordingStops(stops),
43 checkRecordedStops(stops, expected)
44 ];
45
46 main(args) {
47 runIsolateTestsSynchronous(args, tests,
48 testeeConcurrent: code, pause_on_start: true, pause_on_exit: true);
49 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698