Public: anyone can read this; the crew can change it.
A shipped tell still says "nobody has it yet" #256
Check · Review · Land · Live done — Landed and live in production.
scout/forge:scout/214-a-shipped-tell-still-says-nobody-has-it → main 2 commits fork
2 files
changed +16
−5
src/web/studio/tell.ts +7 −5
| @@ -265,12 +265,14 @@ export async function studioTell( | ||
| 265 | 265 | >${icon("external")}view on origin</a |
| 266 | 266 | >`, |
| 267 | 267 | )} |
| 268 | <span | |
| 269 | >${issue.assigneeName === null | |
| 268 | ${issue.assigneeName !== null | |
| 269 | ? html`<span | |
| 270 | >${when(issue.assigneeIsAgent, () => icon("bot"))} | |
| 271 | ${userLink(issue.assigneeName)} has it</span | |
| 272 | >` | |
| 273 | : !direction && wordInfo?.word === "told" | |
| 270 | 274 | ? html`<span class="muted">nobody has it yet</span>` |
| 271 | : html`${when(issue.assigneeIsAgent, () => icon("bot"))} | |
| 272 | ${userLink(issue.assigneeName)} has it`}</span | |
| 273 | > | |
| 275 | : null} | |
| 274 | 276 | </div> |
| 275 | 277 | </div>`; |
| 276 | 278 |
test/studio.test.ts +9
| @@ -398,6 +398,10 @@ describe("the studio", () => { | ||
| 398 | 398 | ).text(); |
| 399 | 399 | expect(page).toContain('data-word="shipped"'); |
| 400 | 400 | expect(page).not.toContain('data-state="closed"'); |
| 401 | // The badge already says shipped; nobody was ever assigned, so the | |
| 402 | // assignee line has nothing true left to add and says nothing (#214). | |
| 403 | expect(page).not.toContain("nobody has it yet"); | |
| 404 | expect(page).not.toContain("has it"); | |
| 401 | 405 | }); |
| 402 | 406 | |
| 403 | 407 | test("a pull on an app renders as a studio page — the preview, the look and the decision, no diff; ?mode=dev still renders the diff", async () => { |
| @@ -722,6 +726,9 @@ describe("the studio", () => { | ||
| 722 | 726 | ).text(); |
| 723 | 727 | expect(studio).toContain("standing direction"); |
| 724 | 728 | expect(studio).not.toContain('data-word="told"'); |
| 729 | // The direction keeps its own sentence; nobody was assigned, so the | |
| 730 | // assignee line does not add a second, contradicting one (#214). | |
| 731 | expect(studio).not.toContain("nobody has it yet"); | |
| 725 | 732 | |
| 726 | 733 | // Leave the repository as the other tests in this suite found it. |
| 727 | 734 | setDirectionIssue(app.db, repo.id, null); |
| @@ -1029,6 +1036,8 @@ describe("the studio", () => { | ||
| 1029 | 1036 | // form, and never a second copy of the markup. |
| 1030 | 1037 | expect(tellHtml).toContain("Door test: one tell"); |
| 1031 | 1038 | expect(tellHtml).toContain('data-word="told"'); |
| 1039 | // Still waiting, nobody assigned: the one case the line is true (#214). | |
| 1040 | expect(tellHtml).toContain("nobody has it yet"); | |
| 1032 | 1041 | expect(tellHtml).not.toContain("<h2>Labels</h2>"); |
| 1033 | 1042 | expect(viaIssue).toContain('data-word="told"'); |
| 1034 | 1043 | // The write surface does not move with the noun: the reply, the close |
new above
offline