import { describe, expect, test } from "bun:test"; import { readFileSync } from "node:fs"; describe("home page hierarchy", () => { test("desktop layout defines aligned AI and timeline top-row sections", () => { const source = readFileSync("src/app/page.tsx", "utf8"); expect(source).toContain( "lg:grid-cols-[minmax(0,0.75fr)_minmax(0,1.25fr)]", ); expect(source).toContain("AI capture"); expect(source).toContain("Event timeline"); }); test("manual create is routed through a More menu instead of a primary mobile action", () => { const source = readFileSync("src/app/page.tsx", "utf8"); expect(source).toContain("More"); expect(source).not.toContain("New Event"); }); test("mobile layout keeps capture before timeline and keeps manual create secondary", () => { const source = readFileSync("src/app/page.tsx", "utf8"); expect(source).toContain("order-1 lg:order-none"); expect(source).toContain("Import"); expect(source).toContain("Manual create"); }); });