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

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

Issue 2771653002: Completion boilerplate for Flutter cons children (flutter-intellij#463) (Closed)
Patch Set: 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.manager; 5 library test.services.completion.dart.manager;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:analysis_server/src/provisional/completion/dart/completion_dart. dart'; 9 import 'package:analysis_server/src/provisional/completion/dart/completion_dart. dart';
10 import 'package:analysis_server/src/services/completion/completion_core.dart'; 10 import 'package:analysis_server/src/services/completion/completion_core.dart';
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 } 59 }
60 60
61 // Build the request 61 // Build the request
62 CompletionRequestImpl baseRequest = new CompletionRequestImpl( 62 CompletionRequestImpl baseRequest = new CompletionRequestImpl(
63 enableNewAnalysisDriver ? await driver.getResult(testFile) : null, 63 enableNewAnalysisDriver ? await driver.getResult(testFile) : null,
64 enableNewAnalysisDriver ? null : context, 64 enableNewAnalysisDriver ? null : context,
65 provider, 65 provider,
66 searchEngine, 66 searchEngine,
67 testSource, 67 testSource,
68 completionOffset, 68 completionOffset,
69 new CompletionPerformance()); 69 new CompletionPerformance(),
70 null);
70 Completer<DartCompletionRequest> requestCompleter = 71 Completer<DartCompletionRequest> requestCompleter =
71 new Completer<DartCompletionRequest>(); 72 new Completer<DartCompletionRequest>();
72 DartCompletionRequestImpl 73 DartCompletionRequestImpl
73 .from(baseRequest, resultDescriptor: RESOLVED_UNIT1) 74 .from(baseRequest, resultDescriptor: RESOLVED_UNIT1)
74 .then((DartCompletionRequest request) { 75 .then((DartCompletionRequest request) {
75 requestCompleter.complete(request); 76 requestCompleter.complete(request);
76 }); 77 });
77 request = await performAnalysis(200, requestCompleter); 78 request = await performAnalysis(200, requestCompleter);
78 79
79 // Get the unresolved directives 80 // Get the unresolved directives
(...skipping 29 matching lines...) Expand all
109 assertImportedLib(null /* dart:core */); 110 assertImportedLib(null /* dart:core */);
110 assertImportedLib('/libA.dart'); 111 assertImportedLib('/libA.dart');
111 } 112 }
112 } 113 }
113 114
114 @reflectiveTest 115 @reflectiveTest
115 class CompletionManagerTest_Driver extends CompletionManagerTest { 116 class CompletionManagerTest_Driver extends CompletionManagerTest {
116 @override 117 @override
117 bool get enableNewAnalysisDriver => true; 118 bool get enableNewAnalysisDriver => true;
118 } 119 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698