| Index: pkg/stack_trace/test/frame_test.dart
|
| diff --git a/pkg/stack_trace/test/frame_test.dart b/pkg/stack_trace/test/frame_test.dart
|
| index ab7c401222484688732b5a0f7624ae4315f47e80..97cf48a220c7cd7b2f8eae37863816d36184a0b9 100644
|
| --- a/pkg/stack_trace/test/frame_test.dart
|
| +++ b/pkg/stack_trace/test/frame_test.dart
|
| @@ -226,6 +226,53 @@ void main() {
|
| });
|
| });
|
|
|
| + group('.parseSafari6_1', () {
|
| + test('parses a simple stack frame correctly', () {
|
| + var frame = new Frame.parseSafari6_1(
|
| + "foo\$bar@http://dartlang.org/foo/bar.dart:10:11");
|
| + expect(frame.uri, equals(Uri.parse("http://dartlang.org/foo/bar.dart")));
|
| + expect(frame.line, equals(10));
|
| + expect(frame.column, equals(11));
|
| + expect(frame.member, equals('foo\$bar'));
|
| + });
|
| +
|
| + test('parses an anonymous stack frame correctly', () {
|
| + var frame = new Frame.parseSafari6_1(
|
| + "http://dartlang.org/foo/bar.dart:10:11");
|
| + expect(frame.uri, equals(Uri.parse("http://dartlang.org/foo/bar.dart")));
|
| + expect(frame.line, equals(10));
|
| + expect(frame.column, equals(11));
|
| + expect(frame.member, equals('<fn>'));
|
| + });
|
| +
|
| + test('parses a stack frame with no line correctly', () {
|
| + var frame = new Frame.parseSafari6_1(
|
| + "foo\$bar@http://dartlang.org/foo/bar.dart::11");
|
| + expect(frame.uri, equals(Uri.parse("http://dartlang.org/foo/bar.dart")));
|
| + expect(frame.line, isNull);
|
| + expect(frame.column, equals(11));
|
| + expect(frame.member, equals('foo\$bar'));
|
| + });
|
| +
|
| + test('parses a stack frame with no column correctly', () {
|
| + var frame = new Frame.parseSafari6_1(
|
| + "foo\$bar@http://dartlang.org/foo/bar.dart:10:");
|
| + expect(frame.uri, equals(Uri.parse("http://dartlang.org/foo/bar.dart")));
|
| + expect(frame.line, equals(10));
|
| + expect(frame.column, isNull);
|
| + expect(frame.member, equals('foo\$bar'));
|
| + });
|
| +
|
| + test('parses a stack frame with no line or column correctly', () {
|
| + var frame = new Frame.parseSafari6_1(
|
| + "foo\$bar@http://dartlang.org/foo/bar.dart:10:11");
|
| + expect(frame.uri, equals(Uri.parse("http://dartlang.org/foo/bar.dart")));
|
| + expect(frame.line, equals(10));
|
| + expect(frame.column, equals(11));
|
| + expect(frame.member, equals('foo\$bar'));
|
| + });
|
| + });
|
| +
|
| group('.parseFriendly', () {
|
| test('parses a simple stack frame correctly', () {
|
| var frame = new Frame.parseFriendly(
|
|
|