test(notifications): close per-room notification-level audit gaps (LC-90) #178
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/lc-90-per-room-notify-audit"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
LC-90 was an audit of the per-room notification level (
mute_mode:none/except_mentions/all), not a green-field feature. The schema, write path, render path, and dispatch gating already ship. This PR records the audit result and adds the integration-test tuples the acceptance criteria asked for.Audit result: works end-to-end, no production change needed
room/notify_dropdown.html) is included unconditionally in the sharedpartials/room_header.html, so it renders for public, private, and enclave-scoped rooms. DMs are excluded by design (separate binary mute indm_header.html).POST /room/:id/notify-prefsupserts viaset_room_mute_mode, rejects DMs (400), and returns a swapped#lc-room-headerfragment (no full reload). The button label reflects the persisted mode.push::dispatchgates onroom_mute_mode: a mention is dropped only forall, delivered forexcept_mentions/none.load_missed_mentions/load_missed_dmsfiltermute_mode <> 'all', soexcept_mentionskeeps @mentions in the digest whilealldrops them.Semantic note (by design, not a gap)
Push and the digest never fire on plain (non-mention) messages at all - only on
@mentions, DMs, and reminders. Soallvsexcept_mentionsdiffer only for: (1) @mention push (suppressed only byall), (2) @mention inclusion in the digest (suppressed only byall), and (3) the sidebar unread badge (suppressed by bothallandexcept_mentions). Plain messages always render in-app regardless. This matches the intended "all = mute everything, mentions = only mentions notify, none = default" semantics. No follow-up issue is warranted (AC #5).New tests
routes_room_mute::private_room_page_renders_notify_dropdown- the seeded general room already covers public + enclave-scoped; this guards a standalone private channel rendering the same dropdown.push_dispatch::dispatch_fires_when_room_mute_none- completes the none/except_mentions/all push triplet (the suite covered only the latter two).email_digest_dispatch::except_mentions_keeps_mention_in_digest_set- symmetric to the existing muted-all exclusion test; locks in thatexcept_mentionskeeps @mentions in the digest.Test
just check,just test,just test-saasall green (85 ok / 0 failed each).Acceptance criteria
room_mute_mode.allvsexcept_mentionsequivalence for plain messages).🤖 Generated with Claude Code