fix: close housekeeping foundation review findings
CI / check (pull_request) Successful in 28s
CI / release (pull_request) Skipped
CI / deploy (pull_request) Skipped

This commit is contained in:
Simo committed 2026-08-26 19:16:34 +02:00
1 parent ebc263da35
commit 08f8d54888
21 files changed
+593 -46

No files matched your search

@@ -40,6 +40,9 @@ const searchResult = {
} satisfies HousekeepingSearchResult;
const searchProvider: HousekeepingSearchProvider = {
id: "people.users",
owner: "people",
capability,
search: async () => ok([searchResult], "search-1"),
};
@@ -49,10 +52,17 @@ const inboxSourceResult = {
} satisfies HousekeepingInboxSourceResult;
const inboxSource: HousekeepingInboxSource = {
id: "people.tickets",
owner: "people",
capability,
getItems: async () => ok(inboxSourceResult, "inbox-1"),
};
const widget: HousekeepingWidgetDefinition = {
id: "people.queue",
owner: "people",
capability,
kind: "mandatory",
load: async () => ok({ count: 2 }, "widget-1"),
};
@@ -80,6 +90,9 @@ const manifest: HousekeepingDomainManifest = {
previewHref: "/admin-next/people",
capability,
routes: [],
searchProviders: [searchProvider],
inboxSources: [inboxSource],
widgets: [widget],
};
describe("housekeeping foundation contracts", () => {
@@ -118,4 +131,23 @@ describe("housekeeping foundation contracts", () => {
requirements,
]).toHaveLength(8);
});
it("carries stable ownership and capability metadata for registry entries", () => {
expect(searchProvider).toMatchObject({
id: "people.users",
owner: "people",
capability,
});
expect(inboxSource).toMatchObject({
id: "people.tickets",
owner: "people",
capability,
});
expect(widget).toMatchObject({
id: "people.queue",
owner: "people",
capability,
kind: "mandatory",
});
});
});