Files
agentic-dev/turbo/generators/templates/realtime/channel/channel.test.ts.hbs
2026-07-12 08:15:46 +00:00

19 lines
637 B
Handlebars

// packages/{{kebabCase feature}}/src/realtime/{{kebabCase channelSlug}}.channel.test.ts
import { describe, it, expect } from "vitest";
import {
{{camelCase channelSlug}}Channel,
{{camelCase channelSlug}}Schema,
} from "@/realtime/{{kebabCase channelSlug}}.channel";
describe("{{camelCase channelSlug}}Channel", () => {
it("has the expected wire name", () => {
expect({{camelCase channelSlug}}Channel.name).toBe(
"{{kebabCase feature}}.{{kebabCase channelSlug}}",
);
});
it("validates an empty payload (stub schema)", () => {
expect(() => {{camelCase channelSlug}}Schema.parse({})).not.toThrow();
});
});