feat(generator): add personalized Random Idea button powered by background profile + Whack Pack card + Codex

This commit is contained in:
airent106 committed 2026-10-29 11:59:05 -06:00
1 parent 4c5560a5a1
commit 2b756ab127
5 files changed
+427 -4

No files matched your search

+18
View File
@@ -216,3 +216,21 @@ test("External notes and images can be attached to a spark and promoted to Mocku
assert.equal(promData.idea.mockups[0].title, "Vintage Ski Patch Photo");
});
test("Personalized Random Idea Generator creates a tailored idea from background + Whack Pack card", async () => {
const res = await fetch(`${baseUrl}/api/ideas/generate-random`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
category: "creative"
})
});
assert.equal(res.status, 201);
const data = await res.json();
assert.ok(data.idea && data.idea.id);
assert.ok(data.idea.title.length > 5);
assert.ok(data.card && data.card.number >= 1 && data.card.number <= 64);
assert.equal(data.idea.inspired_by_card, data.card.number);
assert.ok(data.idea.whack_history.length >= 1);
});