From d1aea89c7d5bd7c36d3d73e425cb3883ee21e15e Mon Sep 17 00:00:00 2001 From: Jarred Sumner Date: Thu, 17 Mar 2022 20:52:31 -0700 Subject: celanup --- integration/bunjs-only-snippets/resolve.test.js | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'integration/bunjs-only-snippets/resolve.test.js') diff --git a/integration/bunjs-only-snippets/resolve.test.js b/integration/bunjs-only-snippets/resolve.test.js index d5d14dfef..0a4ac314a 100644 --- a/integration/bunjs-only-snippets/resolve.test.js +++ b/integration/bunjs-only-snippets/resolve.test.js @@ -36,14 +36,7 @@ it("import.meta.resolve", async () => { join(import.meta.url, "../node_modules/package-json-exports/foo/bar.js") ); - expect(await import.meta.resolve("./resolve-typescript-file.tsx")).toBe( - join(import.meta.url, "../resolve-typescript-file.tsx") - ); - expect(await import.meta.resolve("./resolve-typescript-file.js")).toBe( - join(import.meta.url, "../resolve-typescript-file.tsx") - ); - - // works with typescript edgecases like: + // works with TypeScript compiler edgecases like: // - If the file ends with .js and it doesn't exist, try again with .ts and .tsx expect(await import.meta.resolve("./resolve-typescript-file.js")).toBe( join(import.meta.url, "../resolve-typescript-file.tsx") @@ -52,6 +45,7 @@ it("import.meta.resolve", async () => { join(import.meta.url, "../resolve-typescript-file.tsx") ); + // throws a ResolveError on failure try { await import.meta.resolve("THIS FILE DOESNT EXIST"); throw new Error("Test failed"); -- cgit v1.2.3