Index: pkg/analysis_server/test/services/index/dart_index_contributor_test.dart |
diff --git a/pkg/analysis_server/test/services/index/dart_index_contributor_test.dart b/pkg/analysis_server/test/services/index/dart_index_contributor_test.dart |
index 1830a285943c337c44bc75d23d0030ba990dc406..9ba6cae2f5cbb2b74559cb8e98893b540c8a3e0a 100644 |
--- a/pkg/analysis_server/test/services/index/dart_index_contributor_test.dart |
+++ b/pkg/analysis_server/test/services/index/dart_index_contributor_test.dart |
@@ -4,7 +4,7 @@ |
library test.services.src.index.dart_index_contributor; |
-import 'package:analysis_server/plugin/index/index_core.dart'; |
+import 'package:analysis_server/src/provisional/index/index_core.dart'; |
import 'package:analysis_server/src/services/index/index.dart'; |
import 'package:analysis_server/src/services/index/index_contributor.dart'; |
import 'package:analysis_server/src/services/index/index_store.dart'; |
@@ -94,27 +94,6 @@ class DartUnitContributorTest extends AbstractSingleUnitTest { |
}); |
} |
- void test_isReferencedBy_PrefixElement() { |
- _indexTestUnit(''' |
-import 'dart:async' as ppp; |
-main() { |
- ppp.Future a; |
- ppp.Stream b; |
-} |
-'''); |
- // prepare elements |
- PrefixElement element = findNodeElementAtString('ppp;'); |
- Element elementA = findElement('a'); |
- Element elementB = findElement('b'); |
- IndexableElement indexable = new IndexableElement(element); |
- // verify |
- _assertRecordedRelation(indexable, IndexConstants.IS_REFERENCED_BY, |
- _expectedLocation(elementA, 'ppp.Future')); |
- _assertRecordedRelation(indexable, IndexConstants.IS_REFERENCED_BY, |
- _expectedLocation(elementB, 'ppp.Stream')); |
- _assertNoRecordedRelation(indexable, null, _expectedLocation(null, 'ppp;')); |
- } |
- |
void test_bad_unresolvedFieldFormalParameter() { |
verifyNoTestUnitErrors = false; |
_indexTestUnit(''' |
@@ -1423,6 +1402,27 @@ main() { |
_expectedLocation(mainElement, 'p: 1')); |
} |
+ void test_isReferencedBy_PrefixElement() { |
+ _indexTestUnit(''' |
+import 'dart:async' as ppp; |
+main() { |
+ ppp.Future a; |
+ ppp.Stream b; |
+} |
+'''); |
+ // prepare elements |
+ PrefixElement element = findNodeElementAtString('ppp;'); |
+ Element elementA = findElement('a'); |
+ Element elementB = findElement('b'); |
+ IndexableElement indexable = new IndexableElement(element); |
+ // verify |
+ _assertRecordedRelation(indexable, IndexConstants.IS_REFERENCED_BY, |
+ _expectedLocation(elementA, 'ppp.Future')); |
+ _assertRecordedRelation(indexable, IndexConstants.IS_REFERENCED_BY, |
+ _expectedLocation(elementB, 'ppp.Stream')); |
+ _assertNoRecordedRelation(indexable, null, _expectedLocation(null, 'ppp;')); |
+ } |
+ |
void test_isReferencedBy_TopLevelVariableElement() { |
addSource( |
'/lib.dart', |