convert import tests

This commit is contained in:
Jesse Trinity 2020-05-14 11:53:43 -07:00
parent 57e856b0b4
commit 665e434832
2 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,9 @@
/// <reference path='fourslash.ts' />
/////*a1*/im/*a2*/port { /*a3*//*b3*/x, y as z, T } fro/*b2*/m "m";/*b1*/
// verify that the refactor is offered for full, partial, and empty spans.
for (const m of ["1", "2", "3"]) {
goTo.select("a" + m, "b" + m);
verify.refactorAvailable("Convert import", "Convert named imports to namespace import");
}

View File

@ -0,0 +1,10 @@
/// <reference path='fourslash.ts' />
/////*a1*/im/*a2*/port * as /*a3*//*b3*/m from "m/*b2*/";/*b1*/
// verify that the refactor is offered for full, partial, and empty spans.
for (const m of ["1", "2", "3"]) {
goTo.select("a" + m, "b" + m);
verify.refactorAvailable("Convert import", "Convert namespace import to named imports");
}