Added test for find all refs of function expressions.
This commit is contained in:
parent
934a3bfc6d
commit
035962bee1
1 changed files with 21 additions and 0 deletions
21
tests/cases/fourslash/findAllRefsForFunctionExpression01.ts
Normal file
21
tests/cases/fourslash/findAllRefsForFunctionExpression01.ts
Normal file
|
@ -0,0 +1,21 @@
|
|||
/// <reference path='fourslash.ts'/>
|
||||
|
||||
// @Filename: file1.ts
|
||||
////var foo = function [|foo|](a = [|foo|](), b = () => [|foo|]) {
|
||||
//// [|foo|]([|foo|], [|foo|]);
|
||||
////}
|
||||
|
||||
// @Filename: file2.ts
|
||||
/////// <reference path="file1.ts" />
|
||||
////foo();
|
||||
|
||||
|
||||
let ranges = test.ranges()
|
||||
for (let range of ranges) {
|
||||
goTo.position(range.start);
|
||||
|
||||
verify.referencesCountIs(ranges.length);
|
||||
for (let expectedReference of ranges) {
|
||||
verify.referencesAtPositionContains(expectedReference);
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue