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 7ee4457f376a4b4ac74a4633ce793add11779cc9..ddaa6a5559a6ae9265775ccaec8c60524aa9ef72 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 |
@@ -4153,4 +4153,22 @@ class LocalConstructorContributorTest_Driver |
extends LocalConstructorContributorTest { |
@override |
bool get enableNewAnalysisDriver => true; |
+ |
+ /// Sanity check. Permutations tested in local_ref_contributor. |
+ test_ArgDefaults_cons_with_required_named() async { |
+ addMetaPackageSource(); |
+ addTestSource(''' |
+import 'package:meta/meta.dart'; |
+ |
+class A { |
+ A(int bar, {bool boo, @required int baz}); |
+ baz() { |
+ new A^ |
+ } |
+}'''); |
+ await computeSuggestions(); |
+ |
+ assertSuggestConstructor('A', |
+ defaultArgListString: 'bar, baz: null'); |
+ } |
} |