import { describe, it, expect } from "vitest";
import { appComposeCategories, appTestCaseCategories } from "./categories";

describe("appComposeCategories", () => {
  it("produces resolver category", () => {
    const cats = appComposeCategories("apps/myapp");
    expect(cats).toHaveLength(1);
    expect(cats[0].name).toBe("resolver");
    expect(cats[0].docPattern).toBe("apps/myapp/docs/resolver/*.md");
  });
});

describe("appTestCaseCategories", () => {
  it("produces story test case category with correct pattern", () => {
    const cats = appTestCaseCategories("apps");
    expect(cats.name).toBe("story-test-case");
    expect(cats.docPattern).toBe("apps/docs/business-flow/*/story/*.md");
    expect(cats.testDir).toBe("backend/src/tests/story");
  });
});
