Park remaining local WIP on main. TUI archived, CLI/kernel edits, glass. Sort later. Broken is fine.
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
import { describe, expect, test } from "bun:test"
|
||||
import { presentRows } from "../src/index.ts"
|
||||
|
||||
describe("presentRows", () => {
|
||||
test("writes the spans", () => {
|
||||
const chunks: string[] = []
|
||||
presentRows((chunk) => chunks.push(chunk), [[{ text: "neuron", fg: [255, 225, 74], bg: [10, 10, 10] }]])
|
||||
const out = chunks.join("")
|
||||
expect(out.includes("neuron")).toBe(true)
|
||||
expect(out.includes("\x1b[38;2;255;225;74m")).toBe(true)
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user