/** * Dependency-graph smoke test. * * Ensures the public barrel imports without runtime errors and that all * expected top-level exports are present. */ import { describe, expect, it } from "@suaveplan/testing/runner"; import * as surrealdb from "../src/index.js"; describe("@suaveplan/surrealdb barrel", () => { it("exports SurrealAdapter", { timeout: 5000 }, () => { expect(typeof surrealdb.SurrealAdapter).toBe("function"); }); it("exports SurrealError and SURREAL_CODES", { timeout: 5000 }, () => { expect(typeof surrealdb.SurrealError).toBe("function"); expect(typeof surrealdb.SURREAL_CODES).toBe("object"); }); it("exports getDefaultConfig", { timeout: 5000 }, () => { expect(typeof surrealdb.getDefaultConfig).toBe("function"); }); it("exports discoverSchemas", { timeout: 5000 }, () => { expect(typeof surrealdb.discoverSchemas).toBe("function"); }); it("exports initDatabase", { timeout: 5000 }, () => { expect(typeof surrealdb.initDatabase).toBe("function"); }); it("exports parseVersion and detectVersion", { timeout: 5000 }, () => { expect(typeof surrealdb.parseVersion).toBe("function"); expect(typeof surrealdb.detectVersion).toBe("function"); }); it("exports getSurrealSingleton", { timeout: 5000 }, () => { expect(typeof surrealdb.getSurrealSingleton).toBe("function"); }); });