| Index: pkg/analyzer/test/src/summary/index_unit_test.dart
|
| diff --git a/pkg/analyzer/test/src/summary/index_unit_test.dart b/pkg/analyzer/test/src/summary/index_unit_test.dart
|
| index cb18d02233e3d2a8ab4e3372974c29f47b9110a6..9a269b0b5b2d4097cf699fb6d08bce267f822009 100644
|
| --- a/pkg/analyzer/test/src/summary/index_unit_test.dart
|
| +++ b/pkg/analyzer/test/src/summary/index_unit_test.dart
|
| @@ -819,6 +819,26 @@ main() {
|
| ..isInvokedAt('foo());', false);
|
| }
|
|
|
| + void test_isReferencedBy_FunctionElement_with_LibraryElement() {
|
| + addSource(
|
| + '/foo.dart',
|
| + r'''
|
| +bar() {}
|
| +''');
|
| + _indexTestUnit('''
|
| +import "foo.dart";
|
| +main() {
|
| + bar();
|
| +}
|
| +''');
|
| + LibraryElement fooLibrary = testLibraryElement.imports[0].importedLibrary;
|
| + assertThat(fooLibrary)..isReferencedAt('"foo.dart";', true, length: 10);
|
| + {
|
| + FunctionElement bar = fooLibrary.definingCompilationUnit.functions[0];
|
| + assertThat(bar)..isInvokedAt('bar();', false);
|
| + }
|
| + }
|
| +
|
| void test_isReferencedBy_FunctionTypeAliasElement() {
|
| _indexTestUnit('''
|
| typedef A();
|
|
|