Skip to content

Commit

Permalink
test: add additional tests for prefer-export-from
Browse files Browse the repository at this point in the history
  • Loading branch information
nrgnrg committed Feb 11, 2022
1 parent 18f48ae commit f5740ab
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions test/prefer-export-from.mjs
Expand Up @@ -362,6 +362,46 @@ test.typescript({
export {foo} from "foo";
`,
},
{
code: outdent`
import { foo } from "foo";
export { foo };
export { type bar } from "foo";
`,
errors: 1,
output: outdent`
\n
export { type bar, foo } from "foo";
`,
},
{
code: outdent`
import { foo } from 'foo';
export { foo };
export type { bar } from "foo";
export { baz } from "foo";
`,
errors: 1,
output: outdent`
\n
export type { bar } from "foo";
export { baz, foo } from "foo";
`,
},
{
code: outdent`
import { foo } from 'foo';
export { foo };
export { type bar } from "foo";
export { baz } from "foo";
`,
errors: 1,
output: outdent`
\n
export { type bar, foo } from "foo";
export { baz } from "foo";
`,
},
],
});

Expand Down

0 comments on commit f5740ab

Please sign in to comment.