| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 library frame_test; | 5 library frame_test; |
| 6 | 6 |
| 7 import 'package:pathos/path.dart' as path; | 7 import 'package:path/path.dart' as path; |
| 8 import 'package:stack_trace/stack_trace.dart'; | 8 import 'package:stack_trace/stack_trace.dart'; |
| 9 import 'package:unittest/unittest.dart'; | 9 import 'package:unittest/unittest.dart'; |
| 10 | 10 |
| 11 void main() { | 11 void main() { |
| 12 group('.parseVM', () { | 12 group('.parseVM', () { |
| 13 test('parses a stack frame correctly', () { | 13 test('parses a stack frame correctly', () { |
| 14 var frame = new Frame.parseVM("#1 Foo._bar " | 14 var frame = new Frame.parseVM("#1 Foo._bar " |
| 15 "(file:///home/nweiz/code/stuff.dart:42:21)"); | 15 "(file:///home/nweiz/code/stuff.dart:42:21)"); |
| 16 expect(frame.uri, | 16 expect(frame.uri, |
| 17 equals(Uri.parse("file:///home/nweiz/code/stuff.dart"))); | 17 equals(Uri.parse("file:///home/nweiz/code/stuff.dart"))); |
| (...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 287 equals('http://dartlang.org/thing.dart 5:10 in Foo')); | 287 equals('http://dartlang.org/thing.dart 5:10 in Foo')); |
| 288 }); | 288 }); |
| 289 | 289 |
| 290 test('converts "<anonymous closure>" to "<fn>"', () { | 290 test('converts "<anonymous closure>" to "<fn>"', () { |
| 291 expect(new Frame.parseVM('#0 Foo.<anonymous closure> ' | 291 expect(new Frame.parseVM('#0 Foo.<anonymous closure> ' |
| 292 '(dart:core/uri.dart:5:10)').toString(), | 292 '(dart:core/uri.dart:5:10)').toString(), |
| 293 equals('dart:core/uri.dart 5:10 in Foo.<fn>')); | 293 equals('dart:core/uri.dart 5:10 in Foo.<fn>')); |
| 294 }); | 294 }); |
| 295 }); | 295 }); |
| 296 } | 296 } |
| OLD | NEW |