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

Unified Diff: pkg/analysis_server/test/domain_completion_test.dart

Issue 2877653002: Remove unused analysisContext from completion request and contributors (Closed)
Patch Set: address comments Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: pkg/analysis_server/test/domain_completion_test.dart
diff --git a/pkg/analysis_server/test/domain_completion_test.dart b/pkg/analysis_server/test/domain_completion_test.dart
index dc2bb574684436d032438c7b70358699438f9a45..0b6df7bd49fcff83150c001ba109523b78591bde 100644
--- a/pkg/analysis_server/test/domain_completion_test.dart
+++ b/pkg/analysis_server/test/domain_completion_test.dart
@@ -275,12 +275,7 @@ class CompletionDomainHandlerTest extends AbstractCompletionDomainTest {
});
}
- @failingTest
test_imports_aborted_new_request() async {
- // TODO(brianwilkerson) Figure out whether this test makes sense when
- // running the new driver. It waits for an initial empty notification then
- // waits for a new notification. But I think that under the driver we only
- // ever send one notification.
addTestFile('''
class foo { }
c^''');
@@ -401,6 +396,12 @@ class CompletionDomainHandlerTest extends AbstractCompletionDomainTest {
completionId = response.id;
assertValidId(completionId);
await waitForTasksFinished();
+ // wait for response to arrive
+ // because although the analysis is complete (waitForTasksFinished)
+ // the response may not yet have been processed
+ while (replacementOffset == null) {
+ await new Future.delayed(new Duration(milliseconds: 5));
+ }
expect(replacementOffset, completionOffset - 1);
expect(replacementLength, 1);
assertHasResult(CompletionSuggestionKind.KEYWORD, 'library',

Powered by Google App Engine
This is Rietveld 408576698