diff options
Diffstat (limited to 'integration/bunjs-only-snippets')
-rw-r--r-- | integration/bunjs-only-snippets/inspect.test.js | 4 | ||||
-rw-r--r-- | integration/bunjs-only-snippets/reportError.test.js | 4 | ||||
-rw-r--r-- | integration/bunjs-only-snippets/resolve.test.js | 10 |
3 files changed, 4 insertions, 14 deletions
diff --git a/integration/bunjs-only-snippets/inspect.test.js b/integration/bunjs-only-snippets/inspect.test.js index 71c9c25cc..ef041844d 100644 --- a/integration/bunjs-only-snippets/inspect.test.js +++ b/integration/bunjs-only-snippets/inspect.test.js @@ -1,9 +1,5 @@ import { it, expect } from "bun:test"; -it("console.trace", () => { - console.trace("Hi"); -}); - it("jsx with two elements", () => { const input = Bun.inspect( <div hello="quoted"> diff --git a/integration/bunjs-only-snippets/reportError.test.js b/integration/bunjs-only-snippets/reportError.test.js index 6ba202b7f..e51f93309 100644 --- a/integration/bunjs-only-snippets/reportError.test.js +++ b/integration/bunjs-only-snippets/reportError.test.js @@ -1,7 +1,7 @@ import { it } from "bun:test"; it("reportError", () => { - console.error("---BEGIN REPORT ERROR TEST--"); + console.log("---BEGIN REPORT ERROR TEST--"); // make sure we don't crash when given non-sensical types reportError(new Error("reportError Test!")); reportError(true); @@ -21,5 +21,5 @@ it("reportError", () => { reportError([123, null]); reportError({}); reportError([{}]); - console.error("---END REPORT ERROR TEST--"); + console.log("---END REPORT ERROR TEST--"); }); 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"); |