TypeScript/tests/cases/fourslash/renameJsExports02.ts

17 lines
493 B
TypeScript
Raw Normal View History

2017-03-27 22:53:43 +02:00
/// <reference path='fourslash.ts'/>
// @allowJs: true
// @Filename: a.js
////module.exports = class [|{| "isWriteAccess": true, "isDefinition": true |}A|] {}
// @Filename: b.js
////const [|{| "isWriteAccess": true, "isDefinition": true |}A|] = require("./a");
const [r0, r1] = test.ranges();
verify.referenceGroups(r0, [
{ definition: "(local class) A", ranges: [r0] },
{ definition: "const A: typeof A", ranges: [r1] }
]);
verify.singleReferenceGroup("const A: typeof A", [r1]);