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

Unified Diff: pkg/analysis_server/test/services/completion/imported_computer_test.dart

Issue 637703002: add suggestions for variable declaration assignment RHS (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: merge Created 6 years, 2 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/services/completion/imported_computer_test.dart
diff --git a/pkg/analysis_server/test/services/completion/imported_computer_test.dart b/pkg/analysis_server/test/services/completion/imported_computer_test.dart
index bbab5fbc6c51febd2a7c0e3f94c28958b592958f..ad056611beef8e5c84b8c0c1d164626545fc193e 100644
--- a/pkg/analysis_server/test/services/completion/imported_computer_test.dart
+++ b/pkg/analysis_server/test/services/completion/imported_computer_test.dart
@@ -70,33 +70,6 @@ class ImportedTypeComputerTest extends AbstractSelectorSuggestionTest {
});
}
- test_ConstructorName_importedClass() {
- // SimpleIdentifier PrefixedIdentifier TypeName ConstructorName
- // InstanceCreationExpression
- addSource('/testB.dart', '''
- lib B;
- class X {X.c(); X._d(); z() {}}''');
- addTestSource('''
- import "/testB.dart";
- var m;
- main() {new X.^}''');
- return computeFull().then((_) {
- assertNoSuggestions();
- });
- }
-
- test_ConstructorName_localClass() {
- // SimpleIdentifier PrefixedIdentifier TypeName ConstructorName
- // InstanceCreationExpression
- addTestSource('''
- var m;
- class X {X.c(); X._d(); z() {}}
- main() {new X.^}''');
- return computeFull().then((_) {
- assertNoSuggestions();
- });
- }
-
test_ExpressionStatement_class() {
// SimpleIdentifier ExpressionStatement Block
addSource('/testA.dart', '''
@@ -268,51 +241,4 @@ class ImportedTypeComputerTest extends AbstractSelectorSuggestionTest {
assertNotSuggested('B');
});
}
-
- test_VariableDeclaration_name() {
- // SimpleIdentifier VariableDeclaration VariableDeclarationList
- // VariableDeclarationStatement Block
- addSource('/testA.dart', 'var T1;');
- addTestSource('''
- import "/testA.dart";
- class C {a() {var ^}}''');
- return computeFull().then((_) {
- assertNotSuggested('T1');
- });
- }
-
- xtest_InstanceCreationExpression() {
- // SimpleIdentifier TypeName ConstructorName InstanceCreationExpression
- addSource('/testA.dart', '''
- class A {int x;}
- B() { }''');
- addTestSource('''
- import "/testA.dart";
- class C {foo(){new ^}}''');
- return computeFull().then((_) {
- assertSuggestClass('A');
- assertNotSuggested('x');
- assertNotSuggested('B');
- // Should not suggest compilation unit elements
- // which are returned by the LocalComputer
- assertNotSuggested('C');
- });
- }
-
- xtest_VariableDeclarationStatement_RHS() {
- // SimpleIdentifier VariableDeclaration VariableDeclarationList
- // VariableDeclarationStatement
- addSource('/testA.dart', 'class A {int x;} class _B { }');
- addTestSource('''
- import "/testA.dart";
- class C {foo(){var e = ^}}''');
- return computeFull().then((_) {
- assertSuggestClass('A');
- assertNotSuggested('x');
- assertNotSuggested('_B');
- // Should not suggest compilation unit elements
- // which are returned by the LocalComputer
- assertNotSuggested('C');
- });
- }
}

Powered by Google App Engine
This is Rietveld 408576698