mirror of
https://github.com/dart-lang/sdk
synced 2024-09-16 01:59:38 +00:00
Add completion contributor tests for CFE
Change-Id: I32fc27a593fa1f94b123195b8c0ad606d6828fef Reviewed-on: https://dart-review.googlesource.com/68803 Commit-Queue: Brian Wilkerson <brianwilkerson@google.com> Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
This commit is contained in:
parent
6137511849
commit
6879e4cedc
|
@ -13,6 +13,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(ArgListContributorTest);
|
||||
defineReflectiveTests(ArgListContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -1043,3 +1044,59 @@ main() { f("16", radix: ^);}''');
|
|||
assertSuggestArgumentList(['arg', 'blat'], ['dynamic', 'int']);
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class ArgListContributorTest_UseCFE extends ArgListContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_Flutter_MethodExpression_children() =>
|
||||
super.test_ArgumentList_Flutter_MethodExpression_children();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_constructor_named_param_4() =>
|
||||
super.test_ArgumentList_local_constructor_named_param_4();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_constructor_named_param_5() =>
|
||||
super.test_ArgumentList_local_constructor_named_param_5();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_function_1() =>
|
||||
super.test_ArgumentList_local_function_1();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_function_2() =>
|
||||
super.test_ArgumentList_local_function_2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_function_3() =>
|
||||
super.test_ArgumentList_local_function_3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_function_3a() =>
|
||||
super.test_ArgumentList_local_function_3a();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_function_3b() =>
|
||||
super.test_ArgumentList_local_function_3b();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_function_3c() =>
|
||||
super.test_ArgumentList_local_function_3c();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_local_function_3d() =>
|
||||
super.test_ArgumentList_local_function_3d();
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(CombinatorContributorTest);
|
||||
defineReflectiveTests(CombinatorContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -169,3 +170,13 @@ import "${convertPathForImport("/testB.dart")}" show ^;
|
|||
kind: CompletionSuggestionKind.IDENTIFIER);
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class CombinatorContributorTest_UseCFE extends CombinatorContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_local() => super.test_Block_inherited_local();
|
||||
}
|
||||
|
|
|
@ -19,6 +19,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(CompletionManagerTest);
|
||||
defineReflectiveTests(CompletionManagerTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -52,8 +53,8 @@ part '${convertPathForImport(testFile)}';
|
|||
new CompletionPerformance());
|
||||
Completer<DartCompletionRequest> requestCompleter =
|
||||
new Completer<DartCompletionRequest>();
|
||||
DartCompletionRequestImpl
|
||||
.from(baseRequest, resultDescriptor: RESOLVED_UNIT1)
|
||||
DartCompletionRequestImpl.from(baseRequest,
|
||||
resultDescriptor: RESOLVED_UNIT1)
|
||||
.then((DartCompletionRequest request) {
|
||||
requestCompleter.complete(request);
|
||||
});
|
||||
|
@ -86,3 +87,9 @@ part '${convertPathForImport(testFile)}';
|
|||
assertImportedLib('libA.dart');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class CompletionManagerTest_UseCFE extends CompletionManagerTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(FieldFormalContributorTest);
|
||||
defineReflectiveTests(FieldFormalContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -195,3 +196,9 @@ class FieldFormalContributorTest extends DartCompletionContributorTest {
|
|||
assertNotSuggested('x');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class FieldFormalContributorTest_UseCFE extends FieldFormalContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
}
|
||||
|
|
|
@ -15,6 +15,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(ImportedReferenceContributorTest);
|
||||
defineReflectiveTests(ImportedReferenceContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -4457,3 +4458,97 @@ List<^> x;
|
|||
assertNotSuggested('e');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class ImportedReferenceContributorTest_UseCFE
|
||||
extends ImportedReferenceContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_AsExpression() => super.test_AsExpression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_imported() => super.test_Block_inherited_imported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_local() => super.test_Block_inherited_local();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_partial_results() => super.test_Block_partial_results();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType() => super.test_CatchClause_onType();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType_noBrackets() =>
|
||||
super.test_CatchClause_onType_noBrackets();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_typed() => super.test_CatchClause_typed();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Combinator_hide() => super.test_Combinator_hide();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Combinator_show() => super.test_Combinator_show();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConditionalExpression_partial_thenExpression_empty() =>
|
||||
super.test_ConditionalExpression_partial_thenExpression_empty();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_DefaultFormalParameter_named_expression() =>
|
||||
super.test_DefaultFormalParameter_named_expression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_enum_filter() => super.test_enum_filter();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_body_untyped() =>
|
||||
super.test_ForEachStatement_body_untyped();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_loopVariable_type() =>
|
||||
super.test_ForEachStatement_loopVariable_type();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForStatement_initializer() => super.test_ForStatement_initializer();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ImportDirective_dart() => super.test_ImportDirective_dart();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression() => super.test_InstanceCreationExpression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_unimported() =>
|
||||
super.test_InstanceCreationExpression_unimported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_multiple_contexts() => super.test_multiple_contexts();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_class_const() =>
|
||||
super.test_PrefixedIdentifier_class_const();
|
||||
}
|
||||
|
|
|
@ -14,6 +14,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(InheritedReferenceContributorTest);
|
||||
defineReflectiveTests(InheritedReferenceContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -675,3 +676,18 @@ $line^
|
|||
expect(cs.hasNamedParameters, isNull);
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class InheritedReferenceContributorTest_UseCFE
|
||||
extends InheritedReferenceContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_imported() => super.test_Block_inherited_imported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_local() => super.test_Block_inherited_local();
|
||||
}
|
||||
|
|
|
@ -14,6 +14,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(KeywordContributorTest);
|
||||
defineReflectiveTests(KeywordContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -1869,3 +1870,197 @@ class A {
|
|||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class KeywordContributorTest_UseCFE extends KeywordContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_after_import() => super.test_after_import();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_after_import2() => super.test_after_import2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_anonymous_function_async2() => super.test_anonymous_function_async2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_anonymous_function_async7() => super.test_anonymous_function_async7();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_anonymous_function_async9() => super.test_anonymous_function_async9();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_class_extends_name() => super.test_class_extends_name();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_class_implements2() => super.test_class_implements2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_class_implements3() => super.test_class_implements3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_class_implements_name() => super.test_class_implements_name();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_class_with_name() => super.test_class_with_name();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_for_initialization_var() => super.test_for_initialization_var();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_function_async() => super.test_function_async();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_function_async4() => super.test_function_async4();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import() => super.test_import();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_as() => super.test_import_as();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_as2() => super.test_import_as2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_as3() => super.test_import_as3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred() => super.test_import_deferred();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred2() => super.test_import_deferred2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred3() => super.test_import_deferred3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred4() => super.test_import_deferred4();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred5() => super.test_import_deferred5();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred6() => super.test_import_deferred6();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred_as() => super.test_import_deferred_as();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred_as2() => super.test_import_deferred_as2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred_as3() => super.test_import_deferred_as3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred_as4() => super.test_import_deferred_as4();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred_as5() => super.test_import_deferred_as5();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred_not() => super.test_import_deferred_not();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_deferred_partial() => super.test_import_deferred_partial();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_partial() => super.test_import_partial();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_partial2() => super.test_import_partial2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_partial3() => super.test_import_partial3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_partial4() => super.test_import_partial4();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_partial5() => super.test_import_partial5();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_partial6() => super.test_import_partial6();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_async4() => super.test_method_async4();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_async5() => super.test_method_async5();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_async6() => super.test_method_async6();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_async7() => super.test_method_async7();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_async8() => super.test_method_async8();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_body3() => super.test_method_body3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_body_async3() => super.test_method_body_async3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_method_body_expression1() => super.test_method_body_expression1();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_newInstance2() => super.test_newInstance2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_of() => super.test_part_of();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_prefixed_library() => super.test_prefixed_library();
|
||||
}
|
||||
|
|
|
@ -13,6 +13,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(LabelContributorTest);
|
||||
defineReflectiveTests(LabelContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -318,3 +319,26 @@ void main() {
|
|||
assertSuggestLabel('foo');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class LabelContributorTest_UseCFE extends LabelContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_continue_to_earlier_case() => super.test_continue_to_earlier_case();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_continue_to_enclosing_switch() =>
|
||||
super.test_continue_to_enclosing_switch();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_continue_to_later_case() => super.test_continue_to_later_case();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_continue_to_same_case() => super.test_continue_to_same_case();
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(LibraryMemberContributorTest);
|
||||
defineReflectiveTests(LibraryMemberContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -285,3 +286,18 @@ main() {
|
|||
assertNoSuggestions();
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class LibraryMemberContributorTest_UseCFE extends LibraryMemberContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_libraryPrefix_deferred() => super.test_libraryPrefix_deferred();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_libraryPrefix_deferred_inPart() =>
|
||||
super.test_libraryPrefix_deferred_inPart();
|
||||
}
|
||||
|
|
|
@ -13,6 +13,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(LibraryPrefixContributorTest);
|
||||
defineReflectiveTests(LibraryPrefixContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -327,3 +328,23 @@ main() {new ^ String x = "hello";}''');
|
|||
assertNoSuggestions();
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class LibraryPrefixContributorTest_UseCFE extends LibraryPrefixContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression() => super.test_InstanceCreationExpression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_inPart() =>
|
||||
super.test_InstanceCreationExpression_inPart();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_inPart_detached() =>
|
||||
super.test_InstanceCreationExpression_inPart_detached();
|
||||
}
|
||||
|
|
|
@ -13,6 +13,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(LocalConstructorContributorTest);
|
||||
defineReflectiveTests(LocalConstructorContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -4181,3 +4182,91 @@ class C {bar(){var f; {var x;} var e = ^ var g}}''');
|
|||
assertNotSuggested('e');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class LocalConstructorContributorTest_UseCFE
|
||||
extends LocalConstructorContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_AsExpression() => super.test_AsExpression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_imported() => super.test_Block_inherited_imported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_local() => super.test_Block_inherited_local();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType() => super.test_CatchClause_onType();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType_noBrackets() =>
|
||||
super.test_CatchClause_onType_noBrackets();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_typed() => super.test_CatchClause_typed();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConditionalExpression_partial_thenExpression_empty() =>
|
||||
super.test_ConditionalExpression_partial_thenExpression_empty();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_DefaultFormalParameter_named_expression() =>
|
||||
super.test_DefaultFormalParameter_named_expression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_enum_deprecated() => super.test_enum_deprecated();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_body_untyped() =>
|
||||
super.test_ForEachStatement_body_untyped();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_loopVariable_type() =>
|
||||
super.test_ForEachStatement_loopVariable_type();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForStatement_initializer() => super.test_ForStatement_initializer();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ImportDirective_dart() => super.test_ImportDirective_dart();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression() => super.test_InstanceCreationExpression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_invocationArgument() =>
|
||||
super.test_InstanceCreationExpression_invocationArgument();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_invocationArgument_named() =>
|
||||
super.test_InstanceCreationExpression_invocationArgument_named();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_unimported() =>
|
||||
super.test_InstanceCreationExpression_unimported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_class_const() =>
|
||||
super.test_PrefixedIdentifier_class_const();
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(LocalLibraryContributorTest);
|
||||
defineReflectiveTests(LocalLibraryContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -290,3 +291,9 @@ class LocalLibraryContributorTest extends DartCompletionContributorTest {
|
|||
assertNotSuggested('m');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class LocalLibraryContributorTest_UseCFE extends LocalLibraryContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
}
|
||||
|
|
|
@ -13,6 +13,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(LocalReferenceContributorTest);
|
||||
defineReflectiveTests(LocalReferenceContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -2908,6 +2909,12 @@ class C {foo(){var f; {var x;} f[T^]}}''');
|
|||
//assertNotSuggested('T1');
|
||||
}
|
||||
|
||||
test_inferredType() async {
|
||||
addTestSource('main() { var v = 42; ^ }');
|
||||
await computeSuggestions();
|
||||
assertSuggestLocalVariable('v', 'int');
|
||||
}
|
||||
|
||||
test_InstanceCreationExpression() async {
|
||||
addTestSource('''
|
||||
class A {foo(){var f; {var x;}}}
|
||||
|
@ -4202,12 +4209,6 @@ class X {foo(){A^.bar}}''');
|
|||
assertSuggestLocalVariable('_ab', null);
|
||||
}
|
||||
|
||||
test_inferredType() async {
|
||||
addTestSource('main() { var v = 42; ^ }');
|
||||
await computeSuggestions();
|
||||
assertSuggestLocalVariable('v', 'int');
|
||||
}
|
||||
|
||||
test_prioritization_public() async {
|
||||
addTestSource('main() {var ab; var _ab; a^}');
|
||||
await computeSuggestions();
|
||||
|
@ -4679,3 +4680,100 @@ class C {bar(){var f; {var x;} var e = ^ var g}}''');
|
|||
assertNotSuggested('e');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class LocalReferenceContributorTest_UseCFE
|
||||
extends LocalReferenceContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_MethodInvocation_functionalArg2() =>
|
||||
super.test_ArgumentList_MethodInvocation_functionalArg2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ArgumentList_namedParam_filter() =>
|
||||
super.test_ArgumentList_namedParam_filter();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_AsExpression_type() => super.test_AsExpression_type();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_imported() => super.test_Block_inherited_imported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_local() => super.test_Block_inherited_local();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType() => super.test_CatchClause_onType();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType_noBrackets() =>
|
||||
super.test_CatchClause_onType_noBrackets();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_typed() => super.test_CatchClause_typed();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConditionalExpression_partial_thenExpression_empty() =>
|
||||
super.test_ConditionalExpression_partial_thenExpression_empty();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_DefaultFormalParameter_named_expression() =>
|
||||
super.test_DefaultFormalParameter_named_expression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_enum_deprecated() => super.test_enum_deprecated();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_enum_filter() => super.test_enum_filter();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_body_untyped() =>
|
||||
super.test_ForEachStatement_body_untyped();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_loopVariable_type() =>
|
||||
super.test_ForEachStatement_loopVariable_type();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForStatement_initializer() => super.test_ForStatement_initializer();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_FunctionExpression_body_function() =>
|
||||
super.test_FunctionExpression_body_function();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ImportDirective_dart() => super.test_ImportDirective_dart();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression() => super.test_InstanceCreationExpression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_unimported() =>
|
||||
super.test_InstanceCreationExpression_unimported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_class_const() =>
|
||||
super.test_PrefixedIdentifier_class_const();
|
||||
}
|
||||
|
|
|
@ -13,6 +13,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(NamedConstructorContributorTest);
|
||||
defineReflectiveTests(NamedConstructorContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -169,3 +170,34 @@ class NamedConstructorContributorTest extends DartCompletionContributorTest {
|
|||
assertNotSuggested('m');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class NamedConstructorContributorTest_UseCFE
|
||||
extends NamedConstructorContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConstructorName_importedClass() =>
|
||||
super.test_ConstructorName_importedClass();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConstructorName_importedClass_unresolved() =>
|
||||
super.test_ConstructorName_importedClass_unresolved();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConstructorName_importedFactory() =>
|
||||
super.test_ConstructorName_importedFactory();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConstructorName_localClass() => super.test_ConstructorName_localClass();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConstructorName_localFactory() =>
|
||||
super.test_ConstructorName_localFactory();
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'completion_contributor_util.dart';
|
|||
|
||||
main() {
|
||||
defineReflectiveTests(OverrideContributorTest);
|
||||
defineReflectiveTests(OverrideContributorTest_UseCFE);
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
|
@ -153,6 +154,29 @@ class C extends B {
|
|||
selectionLength: 27);
|
||||
}
|
||||
|
||||
@failingTest
|
||||
test_insideBareClass() async {
|
||||
addTestSource('''
|
||||
class A {
|
||||
method() {}
|
||||
int age;
|
||||
}
|
||||
|
||||
class B extends A {
|
||||
^
|
||||
}
|
||||
''');
|
||||
await computeSuggestions();
|
||||
_assertOverride('''
|
||||
method() {
|
||||
// TODO: implement method
|
||||
return super.method();
|
||||
}''',
|
||||
displayText: 'method() { … }',
|
||||
selectionOffset: 45,
|
||||
selectionLength: 22);
|
||||
}
|
||||
|
||||
test_withExistingOverride() async {
|
||||
addTestSource('''
|
||||
class A {
|
||||
|
@ -200,29 +224,6 @@ method() {
|
|||
selectionLength: 22);
|
||||
}
|
||||
|
||||
@failingTest
|
||||
test_insideBareClass() async {
|
||||
addTestSource('''
|
||||
class A {
|
||||
method() {}
|
||||
int age;
|
||||
}
|
||||
|
||||
class B extends A {
|
||||
^
|
||||
}
|
||||
''');
|
||||
await computeSuggestions();
|
||||
_assertOverride('''
|
||||
method() {
|
||||
// TODO: implement method
|
||||
return super.method();
|
||||
}''',
|
||||
displayText: 'method() { … }',
|
||||
selectionOffset: 45,
|
||||
selectionLength: 22);
|
||||
}
|
||||
|
||||
CompletionSuggestion _assertOverride(String completion,
|
||||
{String displayText, int selectionOffset, int selectionLength}) {
|
||||
CompletionSuggestion cs = getSuggest(
|
||||
|
@ -246,3 +247,9 @@ method() {
|
|||
return cs;
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class OverrideContributorTest_UseCFE extends OverrideContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(StaticMemberContributorTest);
|
||||
defineReflectiveTests(StaticMemberContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -305,3 +306,14 @@ void main() {async.Future.^.w()}''');
|
|||
assertNotSuggested('==');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class StaticMemberContributorTest_UseCFE extends StaticMemberContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_class_const() =>
|
||||
super.test_PrefixedIdentifier_class_const();
|
||||
}
|
||||
|
|
|
@ -15,6 +15,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(TypeMemberContributorTest);
|
||||
defineReflectiveTests(TypeMemberContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -4025,3 +4026,100 @@ class C1 extends C2 implements C3 {
|
|||
assertNotSuggested('e');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class TypeMemberContributorTest_UseCFE extends TypeMemberContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_AsExpression() => super.test_AsExpression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_imported() => super.test_Block_inherited_imported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_Block_inherited_local() => super.test_Block_inherited_local();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType() => super.test_CatchClause_onType();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_onType_noBrackets() =>
|
||||
super.test_CatchClause_onType_noBrackets();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_CatchClause_typed() => super.test_CatchClause_typed();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ConditionalExpression_partial_thenExpression_empty() =>
|
||||
super.test_ConditionalExpression_partial_thenExpression_empty();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_DefaultFormalParameter_named_expression() =>
|
||||
super.test_DefaultFormalParameter_named_expression();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_body_untyped() =>
|
||||
super.test_ForEachStatement_body_untyped();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForEachStatement_loopVariable_type() =>
|
||||
super.test_ForEachStatement_loopVariable_type();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ForStatement_initializer() => super.test_ForStatement_initializer();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_ImportDirective_dart() => super.test_ImportDirective_dart();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_InstanceCreationExpression_unimported() =>
|
||||
super.test_InstanceCreationExpression_unimported();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_libraryPrefix_deferred() => super.test_libraryPrefix_deferred();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_class_const() =>
|
||||
super.test_PrefixedIdentifier_class_const();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_propertyAccess_newStmt() =>
|
||||
super.test_PrefixedIdentifier_propertyAccess_newStmt();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_trailingStmt_field() =>
|
||||
super.test_PrefixedIdentifier_trailingStmt_field();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_trailingStmt_param() =>
|
||||
super.test_PrefixedIdentifier_trailingStmt_param();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_PrefixedIdentifier_trailingStmt_param2() =>
|
||||
super.test_PrefixedIdentifier_trailingStmt_param2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_super() => super.test_super();
|
||||
}
|
||||
|
|
|
@ -15,7 +15,9 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(UriContributorTest);
|
||||
defineReflectiveTests(UriContributorTest_UseCFE);
|
||||
defineReflectiveTests(UriContributorWindowsTest);
|
||||
defineReflectiveTests(UriContributorWindowsTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -528,6 +530,152 @@ class UriContributorTest extends DartCompletionContributorTest {
|
|||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class UriContributorTest_UseCFE extends UriContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_after_import() => super.test_after_import();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_after_import_raw() => super.test_after_import_raw();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_before_import() => super.test_before_import();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_before_import_raw() => super.test_before_import_raw();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_before_import_raw2() => super.test_before_import_raw2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_export_package2() => super.test_export_package2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_export_package2_off() => super.test_export_package2_off();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import3() => super.test_import3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_dart() => super.test_import_dart();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_dart2() => super.test_import_dart2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file2() => super.test_import_file2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file2_off() => super.test_import_file2_off();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file_child() => super.test_import_file_child();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file_outside_lib() => super.test_import_file_outside_lib();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file_parent() => super.test_import_file_parent();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file_parent2() => super.test_import_file_parent2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_no_dot_folders() => super.test_import_no_dot_folders();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_only_dart_files() => super.test_import_only_dart_files();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_package() => super.test_import_package();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_package2() => super.test_import_package2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_package2_off() => super.test_import_package2_off();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_package2_raw() => super.test_import_package2_raw();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_package2_with_trailing() =>
|
||||
super.test_import_package2_with_trailing();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_package_missing_lib() => super.test_import_package_missing_lib();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_package_raw() => super.test_import_package_raw();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_without_closing_quote_eof2() =>
|
||||
super.test_import_without_closing_quote_eof2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_without_closing_quote_eof3() =>
|
||||
super.test_import_without_closing_quote_eof3();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_without_closing_quote_eof4() =>
|
||||
super.test_import_without_closing_quote_eof4();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_outside_import() => super.test_outside_import();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_outside_import2() => super.test_outside_import2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file() => super.test_part_file();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file2() => super.test_part_file2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file_child() => super.test_part_file_child();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file_parent() => super.test_part_file_parent();
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class UriContributorWindowsTest extends DartCompletionContributorTest {
|
||||
@override
|
||||
|
@ -693,3 +841,41 @@ class UriContributorWindowsTest extends DartCompletionContributorTest {
|
|||
assertSuggest('../blat.dart', csKind: CompletionSuggestionKind.IMPORT);
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class UriContributorWindowsTest_UseCFE extends UriContributorWindowsTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file2() => super.test_import_file2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file_child() => super.test_import_file_child();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file_parent() => super.test_import_file_parent();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_import_file_parent2() => super.test_import_file_parent2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file() => super.test_part_file();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file2() => super.test_part_file2();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file_child() => super.test_part_file_child();
|
||||
|
||||
@failingTest
|
||||
@override
|
||||
test_part_file_parent() => super.test_part_file_parent();
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ import 'completion_contributor_util.dart';
|
|||
main() {
|
||||
defineReflectiveSuite(() {
|
||||
defineReflectiveTests(VariableNameContributorTest);
|
||||
defineReflectiveTests(VariableNameContributorTest_UseCFE);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -242,3 +243,9 @@ class VariableNameContributorTest extends DartCompletionContributorTest {
|
|||
assertSuggestName('a');
|
||||
}
|
||||
}
|
||||
|
||||
@reflectiveTest
|
||||
class VariableNameContributorTest_UseCFE extends VariableNameContributorTest {
|
||||
@override
|
||||
bool get useCFE => true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue