TypeScript/tests/cases/fourslash/codeFixClassImplementInterface_typeInOtherFile.ts
Wesley Wigham 3d2bf6a75f
Fix implement interface quickfix import types (#29410)
* Pass module specifier resolution host thru types constructed by implements quickfixes

* Add regression test

* Fix scope node for generated methods, fix lints
2019-01-14 13:56:27 -08:00

26 lines
506 B
TypeScript

/// <reference path='fourslash.ts' />
// @Filename: /I.ts
////export interface J {}
////export interface I {
//// x: J;
//// m(): J;
////}
// @Filename: /C.ts
////import { I } from "./I";
////export class C implements I {}
goTo.file("/C.ts");
verify.codeFix({
description: "Implement interface 'I'",
newFileContent:
`import { I } from "./I";
export class C implements I {
x: import("./I").J;
m(): import("./I").J {
throw new Error("Method not implemented.");
}
}`,
});