• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1namespace ts.projectSystem {
2    describe("unittests:: tsserver:: import helpers", () => {
3        it("should not crash in tsserver", () => {
4            const f1 = {
5                path: "/a/app.ts",
6                content: "export async function foo() { return 100; }"
7            };
8            const tslib = {
9                path: "/a/node_modules/tslib/index.d.ts",
10                content: ""
11            };
12            const host = createServerHost([f1, tslib]);
13            const service = createProjectService(host);
14            service.openExternalProject({ projectFileName: "p", rootFiles: [toExternalFile(f1.path)], options: { importHelpers: true } });
15            service.checkNumberOfProjects({ externalProjects: 1 });
16        });
17    });
18}
19