mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-23 17:33:51 +02:00
PAP-56: register conference-room and artifacts as board routes
Both routes rendered "Company not found" because their root segments were missing from BOARD_ROUTE_ROOTS, so applyCompanyPrefix never prepended the company prefix. Add both roots and a regression test. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
1 parent
8be2eb41b0
commit
ebd1940003
2 files changed
+13
No files matched your search
@@ -64,4 +64,15 @@ describe("company routes", () => {
|
||||
"/teams-catalog/core-exec-team",
|
||||
);
|
||||
});
|
||||
|
||||
it("treats /conference-room and /artifacts as board routes that need a company prefix", () => {
|
||||
expect(isBoardPathWithoutPrefix("/conference-room")).toBe(true);
|
||||
expect(isBoardPathWithoutPrefix("/artifacts")).toBe(true);
|
||||
expect(extractCompanyPrefixFromPath("/conference-room")).toBeNull();
|
||||
expect(extractCompanyPrefixFromPath("/artifacts")).toBeNull();
|
||||
expect(applyCompanyPrefix("/conference-room", "PAP")).toBe("/PAP/conference-room");
|
||||
expect(applyCompanyPrefix("/artifacts", "PAP")).toBe("/PAP/artifacts");
|
||||
expect(toCompanyRelativePath("/PAP/conference-room")).toBe("/conference-room");
|
||||
expect(toCompanyRelativePath("/PAP/artifacts")).toBe("/artifacts");
|
||||
});
|
||||
});
|
||||
@@ -20,6 +20,8 @@ const BOARD_ROUTE_ROOTS = new Set([
|
||||
"u",
|
||||
"design-guide",
|
||||
"search",
|
||||
"conference-room",
|
||||
"artifacts",
|
||||
]);
|
||||
|
||||
const GLOBAL_ROUTE_ROOTS = new Set(["auth", "invite", "board-claim", "cli-auth", "docs", "instance"]);
|
||||
|
||||
Reference in new issue
Block a user