| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 | 4 |
| 5 import 'package:observatory/service_io.dart'; | 5 import 'package:observatory/service_io.dart'; |
| 6 import 'package:observatory/debugger.dart'; | 6 import 'package:observatory/debugger.dart'; |
| 7 import 'package:unittest/unittest.dart'; | 7 import 'package:unittest/unittest.dart'; |
| 8 import 'test_helper.dart'; | 8 import 'test_helper.dart'; |
| 9 import 'dart:async'; | 9 import 'dart:async'; |
| 10 | 10 |
| 11 void testFunction() { | 11 void testFunction() { |
| 12 int i = 0; | 12 int i = 0; |
| 13 while (true) { | 13 while (true) { |
| 14 if (++i % 100000000 == 0) { // line 14 | 14 if (++i % 100000000 == 0) { // line 14 |
| 15 print(i); | 15 print(i); |
| 16 } | 16 } |
| 17 } | 17 } |
| 18 } | 18 } |
| 19 | 19 |
| 20 class TestDebugger extends Debugger { | 20 class TestDebugger extends Debugger { |
| 21 TestDebugger(this.isolate, this.stack); | 21 TestDebugger(this.isolate, this.stack); |
| 22 | 22 |
| 23 Isolate isolate; | 23 Isolate isolate; |
| 24 ServiceMap stack; | 24 ServiceMap stack; |
| 25 int currentFrame = 0; |
| 25 } | 26 } |
| 26 | 27 |
| 27 void source_location_dummy_function() { | 28 void source_location_dummy_function() { |
| 28 } | 29 } |
| 29 | 30 |
| 30 class SourceLocationTestFoo { | 31 class SourceLocationTestFoo { |
| 31 SourceLocationTestFoo(this.field); | 32 SourceLocationTestFoo(this.field); |
| 32 SourceLocationTestFoo.named(); | 33 SourceLocationTestFoo.named(); |
| 33 | 34 |
| 34 void method() {} | 35 void method() {} |
| (...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 269 return SourceLocation.complete(debugger, 'SourceLocationTestFoo.q') | 270 return SourceLocation.complete(debugger, 'SourceLocationTestFoo.q') |
| 270 .then((List<String> completions) { | 271 .then((List<String> completions) { |
| 271 expect(completions.toString(), equals('[]')); | 272 expect(completions.toString(), equals('[]')); |
| 272 }); | 273 }); |
| 273 }); | 274 }); |
| 274 }, | 275 }, |
| 275 | 276 |
| 276 ]; | 277 ]; |
| 277 | 278 |
| 278 main(args) => runIsolateTests(args, tests, testeeConcurrent: testFunction); | 279 main(args) => runIsolateTests(args, tests, testeeConcurrent: testFunction); |
| OLD | NEW |