| 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 91ba872294f977e0a1c0a41cf2ede552acba1069..585366ab67fafaeb6fa89071770f7dacac8331c4 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
|
| @@ -802,6 +802,22 @@ main(A p) {
|
| _expectedLocation(mainElement, 'A.field); // 3'));
|
| }
|
|
|
| + void test_isReferencedBy_ClassElement_invocation() {
|
| + verifyNoTestUnitErrors = false;
|
| + _indexTestUnit('''
|
| +class A {}
|
| +main() {
|
| + A(); // invalid code, but still a reference
|
| +}''');
|
| + // prepare elements
|
| + Element mainElement = findElement('main');
|
| + Element classElement = findElement('A');
|
| + IndexableElement indexable = new IndexableElement(classElement);
|
| + // verify
|
| + _assertRecordedRelation(indexable, IndexConstants.IS_REFERENCED_BY,
|
| + _expectedLocation(mainElement, 'A();'));
|
| + }
|
| +
|
| void test_isReferencedBy_ClassTypeAlias() {
|
| _indexTestUnit('''
|
| class A {}
|
|
|