Index: pkg/analyzer/test/generated/parser_test.dart |
diff --git a/pkg/analyzer/test/generated/parser_test.dart b/pkg/analyzer/test/generated/parser_test.dart |
index 514c0d70dcc052b36272cf69ffe245a82d2c5d03..7919ccf47363daee005ea713096405d7fe81cf55 100644 |
--- a/pkg/analyzer/test/generated/parser_test.dart |
+++ b/pkg/analyzer/test/generated/parser_test.dart |
@@ -485,10 +485,6 @@ class C { |
EngineTestCase.assertInstanceOf((obj) => obj is BinaryExpression, |
BinaryExpression, expression.leftOperand); |
} |
- |
- void test_topLevelVariable_withMetadata() { |
- ParserTestCase.parseCompilationUnit("String @A string;"); |
- } |
} |
/** |
@@ -1899,6 +1895,14 @@ class Foo { |
[ParserErrorCode.TOP_LEVEL_OPERATOR]); |
} |
+ void test_topLevelVariable_withMetadata() { |
+ ParserTestCase.parseCompilationUnit("String @A string;", [ |
+ ParserErrorCode.MISSING_IDENTIFIER, |
+ ParserErrorCode.EXPECTED_TOKEN, |
+ ParserErrorCode.MISSING_CONST_FINAL_VAR_OR_TYPE |
+ ]); |
+ } |
+ |
void test_typedefInClass_withoutReturnType() { |
ParserTestCase.parseCompilationUnit( |
"class C { typedef F(x); }", [ParserErrorCode.TYPEDEF_IN_CLASS]); |
@@ -3271,28 +3275,25 @@ class B = Object with A {}''', [ParserErrorCode.EXPECTED_TOKEN]); |
void test_importDirectivePartial_as() { |
CompilationUnit unit = ParserTestCase.parseCompilationUnit( |
- "import 'b.dart' d as b;", |
- [ParserErrorCode.UNEXPECTED_TOKEN]); |
+ "import 'b.dart' d as b;", [ParserErrorCode.UNEXPECTED_TOKEN]); |
ImportDirective importDirective = unit.childEntities.first; |
expect(importDirective.asKeyword, isNotNull); |
expect(unit.directives, hasLength(1)); |
expect(unit.declarations, hasLength(0)); |
} |
- void test_importDirectivePartial_show() { |
+ void test_importDirectivePartial_hide() { |
CompilationUnit unit = ParserTestCase.parseCompilationUnit( |
- "import 'b.dart' d show foo;", |
- [ParserErrorCode.UNEXPECTED_TOKEN]); |
+ "import 'b.dart' d hide foo;", [ParserErrorCode.UNEXPECTED_TOKEN]); |
ImportDirective importDirective = unit.childEntities.first; |
expect(importDirective.combinators, hasLength(1)); |
expect(unit.directives, hasLength(1)); |
expect(unit.declarations, hasLength(0)); |
} |
- void test_importDirectivePartial_hide() { |
+ void test_importDirectivePartial_show() { |
CompilationUnit unit = ParserTestCase.parseCompilationUnit( |
- "import 'b.dart' d hide foo;", |
- [ParserErrorCode.UNEXPECTED_TOKEN]); |
+ "import 'b.dart' d show foo;", [ParserErrorCode.UNEXPECTED_TOKEN]); |
ImportDirective importDirective = unit.childEntities.first; |
expect(importDirective.combinators, hasLength(1)); |
expect(unit.directives, hasLength(1)); |