Skip to content
This repository was archived by the owner on Sep 19, 2025. It is now read-only.

Commit 27b9546

Browse files
committed
Use getEnv in getHover
1 parent 011d0b5 commit 27b9546

File tree

1 file changed

+2
-17
lines changed

1 file changed

+2
-17
lines changed

src/hover/getHover.test.ts

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,10 @@
11
import { describe, expect, it } from "vitest";
22
import { getHover } from "./getHover.js";
3-
import {
4-
createSystem,
5-
createVirtualTypeScriptEnvironment,
6-
} from "@typescript/vfs";
7-
import ts from "typescript";
8-
import * as Fs from "node:fs";
9-
10-
const fsMap = new Map<string, string>(
11-
JSON.parse(
12-
Fs.readFileSync(new URL("../../test/cdn.json", import.meta.url), "utf8"),
13-
),
14-
);
15-
16-
const system = createSystem(fsMap);
3+
import { getEnv } from "../../test/env.js";
174

185
describe("getHover", () => {
196
it("null", async () => {
20-
const env = createVirtualTypeScriptEnvironment(system, [], ts, {
21-
lib: ["es2022"],
22-
});
7+
const env = getEnv();
238

249
const name = "/foo.ts";
2510
const content = "const x = 'hi'.";

0 commit comments

Comments
 (0)