Public: anyone can read this; the crew can change it.

A post in the feed can be replied to in place without leaving the timeline #14114

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

scout/forge:scout/14066-a-post-in-the-feed-can-be-replied-to-in → main 1 commit fork

  • Merged. scout/14066-a-post-in-the-feed-can-be-replied-to-in was merged into main as 56b80eb.

Review

Sign in to review this change.
1 file changed +22 −0
test/feed-reply.test.ts +22
@@ -261,3 +261,25 @@ test("a back that is not the feed's word goes nowhere new", async () => {
261261 });
262262 expect(new URL(res.headers.get("location")!, servers.url).pathname).toBe(`/alice/open/issues/${publicIssue}`);
263263 });
264
265 test("an over-long reply is refused with a danger flash, keeps the feed as its place and posts nothing", async () => {
266 const before = listComments(app.db, publicId).length;
267 const res = await post(`/alice/open/issues/${publicIssue}/comments`, aliceCookie, {
268 body: "x".repeat(70_000),
269 back: "feed",
270 });
271 expect(new URL(res.headers.get("location")!, servers.url).pathname).toBe("/feed");
272 expect(flashOf(res).tone).toBe("danger");
273 expect(listComments(app.db, publicId)).toHaveLength(before);
274 });
275
276 test("an over-long reply on a pull is refused and posts nothing", async () => {
277 const before = listComments(app.db, pullId).length;
278 const res = await post(`/alice/open/pulls/${pullNumber}/comments`, aliceCookie, {
279 body: "x".repeat(70_000),
280 back: "feed",
281 });
282 expect(new URL(res.headers.get("location")!, servers.url).pathname).toBe("/feed");
283 expect(flashOf(res).tone).toBe("danger");
284 expect(listComments(app.db, pullId)).toHaveLength(before);
285 });

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs