diff options
Diffstat (limited to '')
-rw-r--r-- | test/bun.js/inspect.test.js | 37 |
1 files changed, 18 insertions, 19 deletions
diff --git a/test/bun.js/inspect.test.js b/test/bun.js/inspect.test.js index 8789b7aba..738442211 100644 --- a/test/bun.js/inspect.test.js +++ b/test/bun.js/inspect.test.js @@ -2,7 +2,7 @@ import { it, expect, describe } from "bun:test"; it("Blob inspect", () => { expect(Bun.inspect(new Blob(["123"]))).toBe(`Blob (3 bytes)`); - expect(Bun.inspect(new Blob(["123".repeat(900)]))).toBe(`Blob (3 KB)`); + expect(Bun.inspect(new Blob(["123".repeat(900)]))).toBe(`Blob (2.70 KB)`); expect(Bun.inspect(Bun.file("/tmp/file.txt"))) .toBe(`FileRef ("/tmp/file.txt") { type: "text/plain;charset=utf-8" @@ -30,26 +30,25 @@ it("Blob inspect", () => { }`); }); -// this test is currently failing! -// it("utf16 property name", () => { -// var { Database } = require("bun:sqlite"); -// const db = Database.open(":memory:"); -// expect("笑".codePointAt(0)).toBe(31505); +it.skip("utf16 property name", () => { + var { Database } = require("bun:sqlite"); + const db = Database.open(":memory:"); + expect("笑".codePointAt(0)).toBe(31505); -// // latin1 escaping identifier issue -// expect(Object.keys({ 笑: "hey" })[0].codePointAt(0)).toBe(31505); + // latin1 escaping identifier issue + expect(Object.keys({ 笑: "hey" })[0].codePointAt(0)).toBe(31505); -// const output = JSON.stringify( -// [ -// { -// 笑: "😀", -// }, -// ], -// null, -// 2, -// ); -// expect(Bun.inspect(db.prepare("select '😀' as 笑").all())).toBe(output); -// }); + const output = JSON.stringify( + [ + { + 笑: "😀", + }, + ], + null, + 2, + ); + expect(Bun.inspect(db.prepare("select '😀' as 笑").all())).toBe(output); +}); it("latin1", () => { expect(Bun.inspect("English")).toBe("English"); |