test(api): lock comment entity registry metadata

This commit is contained in:
2026-03-31 22:38:56 +02:00
parent f3f7bb312b
commit 8acfbf8c3e
2 changed files with 25 additions and 0 deletions
@@ -0,0 +1,17 @@
import { describe, expect, it } from "vitest";
import {
CommentEntityTypeSchema,
getCommentToolEntityDescription,
getCommentToolScopeSentence,
getSupportedCommentEntityTypes,
} from "../lib/comment-entity-registry.js";
describe("comment entity registry metadata", () => {
it("keeps the router schema and helper metadata aligned", () => {
expect(getSupportedCommentEntityTypes()).toEqual(["estimate", "resource"]);
expect(CommentEntityTypeSchema.options).toEqual(["estimate", "resource"]);
expect(getCommentToolEntityDescription()).toContain("estimate, resource");
expect(getCommentToolScopeSentence()).toContain("Supported comment entities: estimate, resource.");
expect(getCommentToolScopeSentence()).toContain("resource comments follow resource detail visibility");
});
});