Merge master into worktree-openobject-openslice

Keeps the OpenObject and OpenSlice discovery rows beside master's new
OpenStack.md row in the spec discovery contract test.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
Anthony Ettinger 2026-09-21 10:02:31 +00:00
commit 21d3800b21
8 changed files with 684 additions and 4 deletions

View file

@ -0,0 +1,43 @@
import { describe, expect, it } from "vitest";
import { GET, openstackBody } from "../src/app/.well-known/openstack.md/route";
import { readDoc } from "../src/lib/docs";
// The site that publishes a spec serves its own file, and that file is the
// worked example inside the spec, so the two can never drift apart.
describe("OpenStack.md: the site's own file", () => {
it("serves the spec's worked example as text/markdown", async () => {
const res = GET();
expect(res.headers.get("content-type")).toBe("text/markdown; charset=utf-8");
const body = await res.text();
expect(body.startsWith("# LogicSRC\n")).toBe(true);
expect(readDoc("openstack")).toContain(body.trim());
});
it("follows its own rules: one name, an identity block, the fixed layers, a Not section", () => {
const body = openstackBody();
expect(body.match(/^# /gm)).toHaveLength(1);
expect(body).toMatch(/^- \*\*Kind\*\*: monorepo$/m);
expect(body).toMatch(/^- \*\*Web\*\*: https:\/\/logicsrc\.com$/m);
expect(body).toMatch(/^- \*\*Operator\*\*: https:\/\/logicsrc\.com\/\.well-known\/openprofile\.md$/m);
for (const layer of [
"Languages",
"Runtimes",
"Interfaces",
"Data",
"Services",
"Modules",
"Tooling",
"Hosting",
"Auth",
"Conventions",
"Not"
]) {
expect(body).toMatch(new RegExp(`^## ${layer}$`, "m"));
}
// every interface this monorepo ships is declared
for (const iface of ["Web", "CLI", "TUI", "MCP", "API"]) {
expect(body).toMatch(new RegExp(`^### ${iface}$`, "m"));
}
expect(body).not.toContain(String.fromCharCode(0x2014));
});
});

View file

@ -16,7 +16,8 @@ describe.each([
{ slug: "openrental", name: "OpenRental", family: "catalogs" },
{ slug: "openwall", name: "OpenWall", family: "people" },
{ slug: "openobject", name: "OpenObject", family: "catalogs" },
{ slug: "openslice", name: "OpenSlice", family: "catalogs" }
{ slug: "openslice", name: "OpenSlice", family: "catalogs" },
{ slug: "openstack", name: "OpenStack.md", family: "catalogs" }
])("$name public discovery", ({ slug, name, family }) => {
it("serves the specification through its family and docs index", () => {
expect(familyOfSpec(slug)?.slug).toBe(family);