Fresh history cut from cynarAI/evoo antigravity-handoff/project-timeline (Voice First + project timeline). Brand docs/titles as evOo; keep @rakazo/* packages as tech debt. Excludes node_modules, caches, secrets, voice blobs.
18 lines
653 B
TypeScript
18 lines
653 B
TypeScript
import { describe, expect, it } from "vitest";
|
|
import { AdapterRegistry, slots } from "./index.js";
|
|
|
|
describe("adapter registry", () => {
|
|
it("registers and retrieves adapters", () => {
|
|
const registry = new AdapterRegistry();
|
|
registry.register(slots.runtime, { id: "scripted" });
|
|
registry.register(slots.browser, { id: "fake" });
|
|
expect(registry.get<{ id: string }>(slots.runtime).id).toBe("scripted");
|
|
expect(registry.get<{ id: string }>(slots.browser).id).toBe("fake");
|
|
});
|
|
|
|
it("throws when missing", () => {
|
|
const registry = new AdapterRegistry();
|
|
expect(() => registry.get("nope")).toThrow(/no adapter/i);
|
|
});
|
|
});
|