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

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

Issue 2680303002: Kernel debugging; service tests (Closed)
Patch Set: New failing test Created 3 years, 10 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 import 'test_helper.dart';
Kevin Millikin (Google) 2017/02/08 15:37:52 License header.
jensj 2017/02/13 14:04:16 Done.
2 import 'service_test_common.dart';
3
4 const int LINE_A = 8;
5 const String file = "next_through_is_and_as_test.dart";
6
7 code() {
8 var i = 42.42;
9 var hex = 0x42;
10 if (i is int) {
11 print("i is int");
12 int x = i as int;
13 if (x.isEven) {
14 print("it's even even!");
15 } else {
16 print("but it's not even even!");
17 }
18 }
19 if (i is! int) {
20 print("i is not int");
21 }
22 if (hex is int) {
23 print("hex is int");
24 int x = hex as int;
25 if (x.isEven) {
26 print("it's even even!");
27 } else {
28 print("but it's not even even!");
29 }
30 }
31 if (hex is! int) {
32 print("hex is not int");
33 }
34 }
35
36 List<String> stops = [];
37 List<String> expected = [
38 "$file:${LINE_A+0}:9",
39 "$file:${LINE_A+1}:11",
40 "$file:${LINE_A+2}:9",
41 "$file:${LINE_A+11}:9",
42 "$file:${LINE_A+12}:5",
43 "$file:${LINE_A+14}:11",
44 "$file:${LINE_A+15}:5",
45 "$file:${LINE_A+16}:17",
46 "$file:${LINE_A+17}:11",
47 "$file:${LINE_A+18}:7",
48 "$file:${LINE_A+23}:11",
49 "$file:${LINE_A+26}:1"
50 ];
51
52 var tests = [
53 hasPausedAtStart,
54 setBreakpointAtLine(LINE_A),
55 runStepThroughProgramRecordingStops(stops),
56 checkRecordedStops(stops, expected)
57 ];
58
59 main(args) {
60 runIsolateTestsSynchronous(args, tests,
61 testeeConcurrent: code, pause_on_start: true, pause_on_exit: true);
62 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698