Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(451)

Side by Side Diff: pkg/analysis_server/test/services/completion/dart/completion_contributor_util.dart

Issue 2771123002: Arglist `children:` default value gen fixes. (Closed)
Patch Set: Remove unneeded assignment. Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 test.services.completion.dart.util; 5 library test.services.completion.dart.util;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:analysis_server/plugin/protocol/protocol.dart' as protocol 9 import 'package:analysis_server/plugin/protocol/protocol.dart' as protocol
10 show Element, ElementKind; 10 show Element, ElementKind;
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 expect(element.parameters, isNull); 203 expect(element.parameters, isNull);
204 expect(element.returnType, isNull); 204 expect(element.returnType, isNull);
205 assertHasNoParameterInfo(cs); 205 assertHasNoParameterInfo(cs);
206 return cs; 206 return cs;
207 } 207 }
208 208
209 CompletionSuggestion assertSuggestConstructor(String name, 209 CompletionSuggestion assertSuggestConstructor(String name,
210 {int relevance: DART_RELEVANCE_DEFAULT, 210 {int relevance: DART_RELEVANCE_DEFAULT,
211 String importUri, 211 String importUri,
212 int elemOffset, 212 int elemOffset,
213 String defaultArgListString}) { 213 String defaultArgListString,
214 List<int> defaultArgumentListTextRanges}) {
214 CompletionSuggestion cs = assertSuggest(name, 215 CompletionSuggestion cs = assertSuggest(name,
215 relevance: relevance, 216 relevance: relevance,
216 importUri: importUri, 217 importUri: importUri,
217 elemOffset: elemOffset, 218 elemOffset: elemOffset,
218 defaultArgListString: defaultArgListString); 219 defaultArgListString: defaultArgListString,
220 defaultArgumentListTextRanges: defaultArgumentListTextRanges);
219 protocol.Element element = cs.element; 221 protocol.Element element = cs.element;
220 expect(element, isNotNull); 222 expect(element, isNotNull);
221 expect(element.kind, equals(protocol.ElementKind.CONSTRUCTOR)); 223 expect(element.kind, equals(protocol.ElementKind.CONSTRUCTOR));
222 int index = name.indexOf('.'); 224 int index = name.indexOf('.');
223 expect(element.name, index >= 0 ? name.substring(index + 1) : ''); 225 expect(element.name, index >= 0 ? name.substring(index + 1) : '');
224 return cs; 226 return cs;
225 } 227 }
226 228
227 CompletionSuggestion assertSuggestEnum(String completion, 229 CompletionSuggestion assertSuggestEnum(String completion,
228 {bool isDeprecated: false}) { 230 {bool isDeprecated: false}) {
(...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after
632 634
633 @override 635 @override
634 void setUp() { 636 void setUp() {
635 super.setUp(); 637 super.setUp();
636 index = createMemoryIndex(); 638 index = createMemoryIndex();
637 searchEngine = 639 searchEngine =
638 new SearchEngineImpl(index, (_) => new AstProviderForContext(context)); 640 new SearchEngineImpl(index, (_) => new AstProviderForContext(context));
639 contributor = createContributor(); 641 contributor = createContributor();
640 } 642 }
641 } 643 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698