feat(turbo-gen): templates for gen event publish

This commit is contained in:
2026-05-08 16:13:07 +02:00
parent cf71547223
commit 0801469e89
2 changed files with 25 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
// packages/{{kebabCase feature}}/src/events/{{kebabCase event}}.event.test.ts
import { describe, it, expect } from "vitest";
import { {{camelCase event}}EventSchema, {{camelCase event}}Event } from "@/events/{{kebabCase event}}.event";
describe("{{camelCase event}}Event", () => {
it("has the correct wire name", () => {
expect({{camelCase event}}Event.name).toBe("{{kebabCase feature}}.{{event}}");
});
it("validates an empty payload (stub schema)", () => {
expect(() => {{camelCase event}}EventSchema.parse({})).not.toThrow();
});
});