Open-source Grok Bot alternative with a virtual machine that bots can use
TypeScript ai-agentsclaude-codecodexcomputer-usedockerelectrongrokgrok-botgrok-bot-alternativeself-hostedtypescript
Test Publish over HTTP where publishing isn't offered
milind-soni24f659955030
diff --git a/server/share-team-templates.test.ts b/server/share-team-templates.test.tsindex d0e5a5c57d..86fe6075ee 100644--- a/server/share-team-templates.test.ts+++ b/server/share-team-templates.test.ts@@ -75,12 +75,12 @@ function setup(options: { team?: boolean; github?: GithubConnection; fetchTempla}describe("Publish over HTTP", () => {- it("takes Published by from the body, and refuses an email address in it", async () => {+ it("refuses an email address or a non-name in Published by, and offers the folder where publishing isn't available", async () => {const { request, made } = setup();const card = made().card;expect(await request(ADMIN, "POST", `/api/share/${card.id}/publish`, { author: "[email protected]" })).toEqual({ status: 400, body: { error: "Put a name in Published by, not an email address." } });- expect(await request(ADMIN, "POST", `/api/share/${card.id}/publish`, { author: " Olive " })).toMatchObject({ status: 200, body: { id: card.id, author: "Olive" } });- expect(await request(ADMIN, "POST", `/api/share/${card.id}/publish`, {})).toMatchObject({ status: 200, body: { author: "Olive" } });+ expect(await request(ADMIN, "POST", `/api/share/${card.id}/publish`, { author: 42 })).toMatchObject({ status: 400 });+ expect(await request(ADMIN, "POST", `/api/share/${card.id}/publish`, { author: " Olive " })).toMatchObject({ status: 200, body: { id: card.id, status: "draft", fallback: "unavailable" } });});});