commit a2b4f5f8bcb4cd71cfbb48c6cf676ffb5be46e62
parent 29cc853307778f5bdef7756fb32f1a384c23faf6
Author: I Mean I'm Just Saying <imeanimjustsaying@kiwifarms.st>
Date: Wed, 14 Oct 2026 07:31:00 -0400
umtool: piece.spec — an article drafted from a research board shows its board (P4a-2)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Diffstat:
1 file changed, 27 insertions(+), 0 deletions(-)
diff --git a/umtool/e2e/piece.spec.ts b/umtool/e2e/piece.spec.ts
@@ -325,3 +325,30 @@ test("a video started from a research board: Research done, Article not applicab
rmSync(path.join(FIXTURE, ".umtool", "research", id), { recursive: true, force: true });
}
});
+
+test("an article drafted from a research board: Research done, the board in the head and on the Overview", async ({ page, request }) => {
+ const made = (await (await request.post("/api/research/cases", { data: { title: "Piece article board" } })).json()) as { case: { id: string } };
+ const id = made.case.id;
+ const article = "piece-board-article";
+ try {
+ const board = (await (await request.get(`/api/research/cases/${BOARD_CASE}`)).json()) as {
+ case: { scope: { source: string }; quotes: { cite: { channel: string; video: string; t: number } }[] };
+ };
+ const q = board.case.quotes[0].cite;
+ const pin = await request.post(`/api/research/cases/${id}/quotes`, { data: { source: board.case.scope.source, channel: q.channel, video: q.video, t: q.t } });
+ expect(pin.ok(), await pin.text()).toBe(true);
+ const done = await request.post(`/api/research/cases/${id}/handoff`, { data: { to: "article", article, confirm: true } });
+ expect(done.ok(), await done.text()).toBe(true);
+ const { href } = (await done.json()) as { href: string };
+ expect(href).toBe(urls.articleHref({ site: "articles", id: article }));
+
+ await page.goto(href);
+ const steps = page.getByRole("list", { name: "Stage" }).locator("li");
+ await expect(steps.nth(0)).toHaveAttribute("data-step", "done");
+ await expect(page.locator(`[data-piece-from-board="${id}"] a`)).toHaveText("Piece article board");
+ await expect(page.locator(`[data-piece-board="${id}"] a`)).toHaveAttribute("href", researchCaseHref(id));
+ } finally {
+ rmSync(path.join(FIXTURE, ".umtool", "research", id), { recursive: true, force: true });
+ rmSync(path.join(FIXTURE, "articles", article), { recursive: true, force: true });
+ }
+});