| 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 mixin_test; | 5 library mixin_test; |
| 6 | 6 |
| 7 import 'package:unittest/unittest.dart'; | 7 import 'package:unittest/unittest.dart'; |
| 8 import 'testing.dart'; | 8 import 'testing.dart'; |
| 9 | 9 |
| 10 final options = ['--warnings_as_errors', '--no-colors', 'memory']; | 10 final options = ['--warnings_as_errors', '--no-colors', 'memory']; |
| (...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 610 expect(error.span.end.offset, 69); | 610 expect(error.span.end.offset, 69); |
| 611 error = errors[1]; | 611 error = errors[1]; |
| 612 expect(error.message, 'expected :, but found }'); | 612 expect(error.message, 'expected :, but found }'); |
| 613 expect(error.span.start.line, 7); | 613 expect(error.span.start.line, 7); |
| 614 expect(error.span.end.offset, 73); | 614 expect(error.span.end.offset, 73); |
| 615 error = errors[2]; | 615 error = errors[2]; |
| 616 expect(error.message, 'parsing error expected }'); | 616 expect(error.message, 'parsing error expected }'); |
| 617 expect(error.span.start.line, 9); | 617 expect(error.span.start.line, 9); |
| 618 expect(error.span.end.offset, 83); | 618 expect(error.span.end.offset, 83); |
| 619 error = errors[3]; | 619 error = errors[3]; |
| 620 expect(error.message, 'expected {, but found end of file(\n)'); | 620 expect(error.message, 'expected {, but found end of file()'); |
| 621 expect(error.span.start.line, 9); | 621 expect(error.span.start.line, 9); |
| 622 expect(error.span.end.offset, 86); | 622 expect(error.span.end.offset, 86); |
| 623 error = errors[4]; | 623 error = errors[4]; |
| 624 expect(error.message, 'expected }, but found end of file()'); | 624 expect(error.message, 'expected }, but found end of file()'); |
| 625 expect(error.span.start.line, 10); | 625 expect(error.span.start.line, 10); |
| 626 expect(error.span.end.offset, 86); | 626 expect(error.span.end.offset, 86); |
| 627 error = errors[5]; | 627 error = errors[5]; |
| 628 expect(error.message, 'Using top-level mixin a as a declaration'); | 628 expect(error.message, 'Using top-level mixin a as a declaration'); |
| 629 expect(error.span.start.line, 5); | 629 expect(error.span.start.line, 5); |
| 630 expect(error.span.end.offset, 56); | 630 expect(error.span.end.offset, 56); |
| (...skipping 25 matching lines...) Expand all Loading... |
| 656 test('multiple args and var decls as args', mixinManyArgs); | 656 test('multiple args and var decls as args', mixinManyArgs); |
| 657 }); | 657 }); |
| 658 | 658 |
| 659 group('Mixin warnings', () { | 659 group('Mixin warnings', () { |
| 660 test('undefined top-level', undefinedTopLevel); | 660 test('undefined top-level', undefinedTopLevel); |
| 661 test('undefined declaration', undefinedDeclaration); | 661 test('undefined declaration', undefinedDeclaration); |
| 662 test('detect bad top-level as declaration', badDeclarationInclude); | 662 test('detect bad top-level as declaration', badDeclarationInclude); |
| 663 test('detect bad declaration as top-level', badTopInclude); | 663 test('detect bad declaration as top-level', badTopInclude); |
| 664 }); | 664 }); |
| 665 } | 665 } |
| OLD | NEW |