| Index: pkg/analysis_server/test/services/completion/dart/local_constructor_contributor_test.dart
|
| diff --git a/pkg/analysis_server/test/services/completion/dart/local_constructor_contributor_test.dart b/pkg/analysis_server/test/services/completion/dart/local_constructor_contributor_test.dart
|
| index dfef73b9bd8b8401e1a4a50d3ad708de82a9e30c..89c378da9e2e294c39f51e63959392c92120e740 100644
|
| --- a/pkg/analysis_server/test/services/completion/dart/local_constructor_contributor_test.dart
|
| +++ b/pkg/analysis_server/test/services/completion/dart/local_constructor_contributor_test.dart
|
| @@ -74,9 +74,7 @@ class A {
|
|
|
| test_ArgumentList() async {
|
| // ArgumentList MethodInvocation ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| bool hasLength(int expected) { }
|
| void baz() { }''');
|
| @@ -102,9 +100,7 @@ void main() {expect(^)}''');
|
|
|
| test_ArgumentList_imported_function() async {
|
| // ArgumentList MethodInvocation ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| bool hasLength(int expected) { }
|
| expect(arg) { }
|
| @@ -131,9 +127,7 @@ void main() {expect(^)}''');
|
|
|
| test_ArgumentList_InstanceCreationExpression_functionalArg() async {
|
| // ArgumentList InstanceCreationExpression ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| class A { A(f()) { } }
|
| bool hasLength(int expected) { }
|
| @@ -162,9 +156,7 @@ void main() {new A(^)}''');
|
|
|
| test_ArgumentList_InstanceCreationExpression_typedefArg() async {
|
| // ArgumentList InstanceCreationExpression ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| typedef Funct();
|
| class A { A(Funct f) { } }
|
| @@ -194,9 +186,7 @@ void main() {new A(^)}''');
|
|
|
| test_ArgumentList_local_function() async {
|
| // ArgumentList MethodInvocation ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| bool hasLength(int expected) { }
|
| void baz() { }''');
|
| @@ -223,9 +213,7 @@ void main() {expect(^)}''');
|
|
|
| test_ArgumentList_local_method() async {
|
| // ArgumentList MethodInvocation ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| bool hasLength(int expected) { }
|
| void baz() { }''');
|
| @@ -252,9 +240,7 @@ String bar() => true;''');
|
|
|
| test_ArgumentList_MethodInvocation_functionalArg() async {
|
| // ArgumentList MethodInvocation ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| class A { A(f()) { } }
|
| bool hasLength(int expected) { }
|
| @@ -283,9 +269,7 @@ void main() {bar(^);}''');
|
|
|
| test_ArgumentList_MethodInvocation_methodArg() async {
|
| // ArgumentList MethodInvocation ExpressionStatement Block
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| class A { A(f()) { } }
|
| bool hasLength(int expected) { }
|
| @@ -313,9 +297,7 @@ void main() {new B().bar(^);}''');
|
| test_ArgumentList_namedParam() async {
|
| // SimpleIdentifier NamedExpression ArgumentList MethodInvocation
|
| // ExpressionStatement
|
| - addSource(
|
| - '/libA.dart',
|
| - '''
|
| + addSource('/libA.dart', '''
|
| library A;
|
| bool hasLength(int expected) { }''');
|
| addTestSource('''
|
| @@ -507,29 +489,21 @@ main() async {A a; await ^}''');
|
|
|
| test_Block() async {
|
| // Block BlockFunctionBody MethodDeclaration
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| export "dart:math" hide max;
|
| class A {int x;}
|
| @deprecated D1() {int x;}
|
| class _B {boo() { partBoo() {}} }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| String T1;
|
| var _T2;
|
| class C { }
|
| class D { }''');
|
| - addSource(
|
| - '/testEEF.dart',
|
| - '''
|
| + addSource('/testEEF.dart', '''
|
| class EE { }
|
| class F { }''');
|
| addSource('/testG.dart', 'class G { }');
|
| - addSource(
|
| - '/testH.dart',
|
| - '''
|
| + addSource('/testH.dart', '''
|
| class H { }
|
| int T3;
|
| var _T4;'''); // not imported
|
| @@ -608,29 +582,21 @@ class Z { }''');
|
|
|
| test_Block_final() async {
|
| // Block BlockFunctionBody MethodDeclaration
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| export "dart:math" hide max;
|
| class A {int x;}
|
| @deprecated D1() {int x;}
|
| class _B {boo() { partBoo() {}} }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| String T1;
|
| var _T2;
|
| class C { }
|
| class D { }''');
|
| - addSource(
|
| - '/testEEF.dart',
|
| - '''
|
| + addSource('/testEEF.dart', '''
|
| class EE { }
|
| class F { }''');
|
| addSource('/testG.dart', 'class G { }');
|
| - addSource(
|
| - '/testH.dart',
|
| - '''
|
| + addSource('/testH.dart', '''
|
| class H { }
|
| int T3;
|
| var _T4;'''); // not imported
|
| @@ -729,29 +695,21 @@ class Z { }''');
|
|
|
| test_Block_final_final() async {
|
| // Block BlockFunctionBody MethodDeclaration
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| export "dart:math" hide max;
|
| class A {int x;}
|
| @deprecated D1() {int x;}
|
| class _B {boo() { partBoo() {}} }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| String T1;
|
| var _T2;
|
| class C { }
|
| class D { }''');
|
| - addSource(
|
| - '/testEEF.dart',
|
| - '''
|
| + addSource('/testEEF.dart', '''
|
| class EE { }
|
| class F { }''');
|
| addSource('/testG.dart', 'class G { }');
|
| - addSource(
|
| - '/testH.dart',
|
| - '''
|
| + addSource('/testH.dart', '''
|
| class H { }
|
| int T3;
|
| var _T4;'''); // not imported
|
| @@ -836,29 +794,21 @@ class Z { }''');
|
|
|
| test_Block_final_var() async {
|
| // Block BlockFunctionBody MethodDeclaration
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| export "dart:math" hide max;
|
| class A {int x;}
|
| @deprecated D1() {int x;}
|
| class _B {boo() { partBoo() {}} }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| String T1;
|
| var _T2;
|
| class C { }
|
| class D { }''');
|
| - addSource(
|
| - '/testEEF.dart',
|
| - '''
|
| + addSource('/testEEF.dart', '''
|
| class EE { }
|
| class F { }''');
|
| addSource('/testG.dart', 'class G { }');
|
| - addSource(
|
| - '/testH.dart',
|
| - '''
|
| + addSource('/testH.dart', '''
|
| class H { }
|
| int T3;
|
| var _T4;'''); // not imported
|
| @@ -942,29 +892,21 @@ class Z { }''');
|
| }
|
|
|
| test_Block_identifier_partial() async {
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| export "dart:math" hide max;
|
| class A {int x;}
|
| @deprecated D1() {int x;}
|
| class _B { }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| String T1;
|
| var _T2;
|
| class C { }
|
| class D { }''');
|
| - addSource(
|
| - '/testEEF.dart',
|
| - '''
|
| + addSource('/testEEF.dart', '''
|
| class EE { }
|
| class F { }''');
|
| addSource('/testG.dart', 'class G { }');
|
| - addSource(
|
| - '/testH.dart',
|
| - '''
|
| + addSource('/testH.dart', '''
|
| class H { }
|
| class D3 { }
|
| int T3;
|
| @@ -1029,9 +971,7 @@ class Z { }''');
|
|
|
| test_Block_inherited_imported() async {
|
| // Block BlockFunctionBody MethodDeclaration ClassDeclaration
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| class F { var f1; f2() { } get f3 => 0; set f4(fx) { } var _pf; }
|
| class E extends F { var e1; e2() { } }
|
| @@ -1085,29 +1025,21 @@ class A extends E implements I with M {a() {^}}''');
|
| }
|
|
|
| test_Block_local_function() async {
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| export "dart:math" hide max;
|
| class A {int x;}
|
| @deprecated D1() {int x;}
|
| class _B {boo() { partBoo() {}} }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| String T1;
|
| var _T2;
|
| class C { }
|
| class D { }''');
|
| - addSource(
|
| - '/testEEF.dart',
|
| - '''
|
| + addSource('/testEEF.dart', '''
|
| class EE { }
|
| class F { }''');
|
| addSource('/testG.dart', 'class G { }');
|
| - addSource(
|
| - '/testH.dart',
|
| - '''
|
| + addSource('/testH.dart', '''
|
| class H { }
|
| int T3;
|
| var _T4;'''); // not imported
|
| @@ -1161,9 +1093,7 @@ class Z { }''');
|
|
|
| test_CascadeExpression_selector1() async {
|
| // PropertyAccess CascadeExpression ExpressionStatement Block
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "/testB.dart";
|
| @@ -1188,9 +1118,7 @@ main() {A a; a.^.z}''');
|
|
|
| test_CascadeExpression_selector2() async {
|
| // SimpleIdentifier PropertyAccess CascadeExpression ExpressionStatement
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "/testB.dart";
|
| @@ -1213,9 +1141,7 @@ main() {A a; a..^z}''');
|
|
|
| test_CascadeExpression_selector2_withTrailingReturn() async {
|
| // PropertyAccess CascadeExpression ExpressionStatement Block
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "/testB.dart";
|
| @@ -1310,9 +1236,7 @@ main() {A a; a^..b}''');
|
|
|
| test_ClassDeclaration_body() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "testB.dart" as x;
|
| @@ -1333,9 +1257,7 @@ A T;''');
|
|
|
| test_ClassDeclaration_body_final() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "testB.dart" as x;
|
| @@ -1356,9 +1278,7 @@ A T;''');
|
|
|
| test_ClassDeclaration_body_final_field() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "testB.dart" as x;
|
| @@ -1379,9 +1299,7 @@ A T;''');
|
|
|
| test_ClassDeclaration_body_final_field2() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "testB.dart" as Soo;
|
| @@ -1402,9 +1320,7 @@ A Sew;''');
|
|
|
| test_ClassDeclaration_body_final_final() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "testB.dart" as x;
|
| @@ -1425,9 +1341,7 @@ A T;''');
|
|
|
| test_ClassDeclaration_body_final_var() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| class B { }''');
|
| addTestSource('''
|
| import "testB.dart" as x;
|
| @@ -1448,23 +1362,17 @@ A T;''');
|
|
|
| test_Combinator_hide() async {
|
| // SimpleIdentifier HideCombinator ImportDirective
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| library libAB;
|
| part '/partAB.dart';
|
| class A { }
|
| class B { }''');
|
| - addSource(
|
| - '/partAB.dart',
|
| - '''
|
| + addSource('/partAB.dart', '''
|
| part of libAB;
|
| var T1;
|
| PB F1() => new PB();
|
| class PB { }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| class C { }
|
| class D { }''');
|
| addTestSource('''
|
| @@ -1478,25 +1386,19 @@ class X {}''');
|
|
|
| test_Combinator_show() async {
|
| // SimpleIdentifier HideCombinator ImportDirective
|
| - addSource(
|
| - '/testAB.dart',
|
| - '''
|
| + addSource('/testAB.dart', '''
|
| library libAB;
|
| part '/partAB.dart';
|
| class A { }
|
| class B { }''');
|
| - addSource(
|
| - '/partAB.dart',
|
| - '''
|
| + addSource('/partAB.dart', '''
|
| part of libAB;
|
| var T1;
|
| PB F1() => new PB();
|
| typedef PB2 F2(int blat);
|
| class Clz = Object with Object;
|
| class PB { }''');
|
| - addSource(
|
| - '/testCD.dart',
|
| - '''
|
| + addSource('/testCD.dart', '''
|
| class C { }
|
| class D { }''');
|
| addTestSource('''
|
| @@ -1510,9 +1412,7 @@ class X {}''');
|
|
|
| test_ConditionalExpression_elseExpression() async {
|
| // SimpleIdentifier ConditionalExpression ReturnStatement
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {int x;}''');
|
| @@ -1532,9 +1432,7 @@ class C {foo(){var f; {var x;} return a ? T1 : T^}}''');
|
|
|
| test_ConditionalExpression_elseExpression_empty() async {
|
| // SimpleIdentifier ConditionalExpression ReturnStatement
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {int x;}''');
|
| @@ -1560,9 +1458,7 @@ class C {foo(){var f; {var x;} return a ? T1 : ^}}''');
|
|
|
| test_ConditionalExpression_partial_thenExpression() async {
|
| // SimpleIdentifier ConditionalExpression ReturnStatement
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {int x;}''');
|
| @@ -1582,9 +1478,7 @@ class C {foo(){var f; {var x;} return a ? T^}}''');
|
|
|
| test_ConditionalExpression_partial_thenExpression_empty() async {
|
| // SimpleIdentifier ConditionalExpression ReturnStatement
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {int x;}''');
|
| @@ -1610,9 +1504,7 @@ class C {foo(){var f; {var x;} return a ? ^}}''');
|
|
|
| test_ConditionalExpression_thenExpression() async {
|
| // SimpleIdentifier ConditionalExpression ReturnStatement
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {int x;}''');
|
| @@ -1668,9 +1560,7 @@ class C {foo(){var f; {var x;} return a ? T^ : c}}''');
|
| test_ConstructorName_importedClass() async {
|
| // SimpleIdentifier PrefixedIdentifier TypeName ConstructorName
|
| // InstanceCreationExpression
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| int T1;
|
| F1() { }
|
| @@ -1695,9 +1585,7 @@ main() {new X.^}''');
|
| test_ConstructorName_importedFactory() async {
|
| // SimpleIdentifier PrefixedIdentifier TypeName ConstructorName
|
| // InstanceCreationExpression
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| int T1;
|
| F1() { }
|
| @@ -1815,9 +1703,7 @@ class A {a(blat: ^) { }}''');
|
|
|
| test_ExpressionStatement_identifier() async {
|
| // SimpleIdentifier ExpressionStatement Block
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| _B F1() { }
|
| class A {int x;}
|
| class _B { }''');
|
| @@ -1844,9 +1730,7 @@ class C {foo(){^} void bar() {}}''');
|
|
|
| test_ExpressionStatement_name() async {
|
| // ExpressionStatement Block BlockFunctionBody MethodDeclaration
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| B T1;
|
| class B{}''');
|
| addTestSource('''
|
| @@ -2104,9 +1988,7 @@ class B extends A {
|
|
|
| test_FunctionDeclaration_returnType_afterComment() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2136,9 +2018,7 @@ class C2 { }
|
|
|
| test_FunctionDeclaration_returnType_afterComment2() async {
|
| // FunctionDeclaration ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2168,9 +2048,7 @@ class C2 { }
|
|
|
| test_FunctionDeclaration_returnType_afterComment3() async {
|
| // FunctionDeclaration ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2325,9 +2203,7 @@ main(aaa, bbb) {}''');
|
|
|
| test_IndexExpression() async {
|
| // ExpressionStatement Block
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {int x;}''');
|
| @@ -2353,9 +2229,7 @@ class C {foo(){var f; {var x;} f[^]}}''');
|
|
|
| test_IndexExpression2() async {
|
| // SimpleIdentifier IndexExpression ExpressionStatement Block
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {int x;}''');
|
| @@ -2455,9 +2329,7 @@ main() {
|
|
|
| test_InstanceCreationExpression_imported() async {
|
| // SimpleIdentifier TypeName ConstructorName InstanceCreationExpression
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| class A {A(this.x) { } int x;}''');
|
| @@ -2536,9 +2408,7 @@ main() {
|
|
|
| test_InterpolationExpression() async {
|
| // SimpleIdentifier InterpolationExpression StringInterpolation
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2568,9 +2438,7 @@ main() {String name; print("hello \$^");}''');
|
|
|
| test_InterpolationExpression_block() async {
|
| // SimpleIdentifier InterpolationExpression StringInterpolation
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2642,9 +2510,7 @@ main() {String name; print("hello \${^}");}''');
|
|
|
| test_IsExpression() async {
|
| // SimpleIdentifier TypeName IsExpression IfStatement
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| foo() { }
|
| class X {X.c(); X._d(); z() {}}''');
|
| @@ -2713,9 +2579,7 @@ main(){var a; if (a is Obj^)}''');
|
| }
|
|
|
| test_keyword() async {
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| int newT1;
|
| int T1;
|
| @@ -2777,9 +2641,7 @@ main() {new^ X.c();}''');
|
|
|
| test_MapLiteralEntry() async {
|
| // MapLiteralEntry MapLiteral VariableDeclaration
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2808,9 +2670,7 @@ foo = {^''');
|
|
|
| test_MapLiteralEntry1() async {
|
| // MapLiteralEntry MapLiteral VariableDeclaration
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2832,9 +2692,7 @@ foo = {T^''');
|
|
|
| test_MapLiteralEntry2() async {
|
| // SimpleIdentifier MapLiteralEntry MapLiteral VariableDeclaration
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -2946,9 +2804,7 @@ class B extends A {
|
|
|
| test_MethodDeclaration_body_static() async {
|
| // Block BlockFunctionBody MethodDeclaration
|
| - addSource(
|
| - '/testC.dart',
|
| - '''
|
| + addSource('/testC.dart', '''
|
| class C {
|
| c1() {}
|
| var c2;
|
| @@ -3032,9 +2888,7 @@ class A {Z a(X x, [int y=1]) {^}}''');
|
|
|
| test_MethodDeclaration_returnType() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -3063,9 +2917,7 @@ class C2 {^ zoo(z) { } String name; }''');
|
|
|
| test_MethodDeclaration_returnType_afterComment() async {
|
| // ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -3094,9 +2946,7 @@ class C2 {/* */ ^ zoo(z) { } String name; }''');
|
|
|
| test_MethodDeclaration_returnType_afterComment2() async {
|
| // MethodDeclaration ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -3125,9 +2975,7 @@ class C2 {/** */ ^ zoo(z) { } String name; }''');
|
|
|
| test_MethodDeclaration_returnType_afterComment3() async {
|
| // MethodDeclaration ClassDeclaration CompilationUnit
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| int T1;
|
| F1() { }
|
| typedef D1();
|
| @@ -3235,16 +3083,12 @@ class B extends A {m() {^}}
|
|
|
| test_partFile_TypeName() async {
|
| // SimpleIdentifier TypeName ConstructorName
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| int T1;
|
| F1() { }
|
| class X {X.c(); X._d(); z() {}}''');
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| library libA;
|
| import "/testB.dart";
|
| part "$testFile";
|
| @@ -3273,16 +3117,12 @@ main() {new ^}''');
|
|
|
| test_partFile_TypeName2() async {
|
| // SimpleIdentifier TypeName ConstructorName
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| int T1;
|
| F1() { }
|
| class X {X.c(); X._d(); z() {}}''');
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| part of libA;
|
| class B { }''');
|
| addTestSource('''
|
| @@ -3310,9 +3150,7 @@ var m;''');
|
|
|
| test_PrefixedIdentifier_class_const() async {
|
| // SimpleIdentifier PrefixedIdentifier ExpressionStatement Block
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| class I {
|
| static const scI = 'boo';
|
| @@ -3359,9 +3197,7 @@ main() {A.^}''');
|
|
|
| test_PrefixedIdentifier_class_imported() async {
|
| // SimpleIdentifier PrefixedIdentifier ExpressionStatement
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| class I {X get f => new A();get _g => new A();}
|
| class A implements I {
|
| @@ -3440,9 +3276,7 @@ class X{}''');
|
|
|
| test_PrefixedIdentifier_library() async {
|
| // SimpleIdentifier PrefixedIdentifier ExpressionStatement
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| var T1;
|
| class X { }
|
| @@ -3469,9 +3303,7 @@ main() {b.^}''');
|
|
|
| test_PrefixedIdentifier_library_typesOnly() async {
|
| // SimpleIdentifier PrefixedIdentifier TypeName
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| var T1;
|
| class X { }
|
| @@ -3498,9 +3330,7 @@ foo(b.^ f) {}''');
|
|
|
| test_PrefixedIdentifier_library_typesOnly2() async {
|
| // SimpleIdentifier PrefixedIdentifier TypeName
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| var T1;
|
| class X { }
|
| @@ -3527,9 +3357,7 @@ foo(b.^) {}''');
|
|
|
| test_PrefixedIdentifier_parameter() async {
|
| // SimpleIdentifier PrefixedIdentifier ExpressionStatement
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| class _W {M y; var _z;}
|
| class X extends _W {}
|
| @@ -3548,9 +3376,7 @@ foo(X x) {x.^}''');
|
|
|
| test_PrefixedIdentifier_prefix() async {
|
| // SimpleIdentifier PrefixedIdentifier ExpressionStatement
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| class A {static int bar = 10;}
|
| _B() {}''');
|
| addTestSource('''
|
| @@ -4018,9 +3844,7 @@ class X{}''');
|
|
|
| test_TypeArgumentList() async {
|
| // SimpleIdentifier BinaryExpression ExpressionStatement
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| class C1 {int x;}
|
| F1() => 0;
|
| typedef String T1(int blat);''');
|
| @@ -4046,9 +3870,7 @@ main() { C<^> c; }''');
|
|
|
| test_TypeArgumentList2() async {
|
| // TypeName TypeArgumentList TypeName
|
| - addSource(
|
| - '/testA.dart',
|
| - '''
|
| + addSource('/testA.dart', '''
|
| class C1 {int x;}
|
| F1() => 0;
|
| typedef String T1(int blat);''');
|
| @@ -4070,9 +3892,7 @@ main() { C<C^> c; }''');
|
| test_VariableDeclaration_name() async {
|
| // SimpleIdentifier VariableDeclaration VariableDeclarationList
|
| // VariableDeclarationStatement Block
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| foo() { }
|
| class _B { }
|
| @@ -4099,9 +3919,7 @@ main() {var ^}''');
|
| test_VariableDeclarationStatement_RHS() async {
|
| // SimpleIdentifier VariableDeclaration VariableDeclarationList
|
| // VariableDeclarationStatement
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| foo() { }
|
| class _B { }
|
| @@ -4126,9 +3944,7 @@ class C {bar(){var f; {var x;} var e = ^}}''');
|
| test_VariableDeclarationStatement_RHS_missing_semicolon() async {
|
| // VariableDeclaration VariableDeclarationList
|
| // VariableDeclarationStatement
|
| - addSource(
|
| - '/testB.dart',
|
| - '''
|
| + addSource('/testB.dart', '''
|
| lib B;
|
| foo1() { }
|
| void bar1() { }
|
|
|