mirror of
https://github.com/block/buzz.git
synced 2026-11-09 10:51:42 +00:00
Two test-only changes, both follow-ups from the #4124 review round; no production code is touched. 1. Two-entry fence fixture (Sami's design, from Dawn's diagnosis): the over-budget leg of is_relay_member_is_bounded_routed_and_fails_closed used a single injected fence entry, which is simultaneously the ring's newest AND the entry the reader proves — so the cheap precheck alone fails the read closed, and the authoritative per-session verdict guard could be deleted with byte-identical results (mutation-proven). The new leg records a proved-but-stale entry (token 50, committed 10s ago) plus a fresh unobservable one (token 999) under the replica's real epoch: the precheck passes on the newest while resolve() proves the stale one, which only the verdict stage can catch. Asserts the boolean outcome (writer's row visible), the writer/stale route metric, and the absence of any replica decision. Kills the verdict mutant; the precheck mutant correctly survives (replica_fence.rs: availability hygiene, not soundness). 2. Owner-limit tests seed from max_communities_per_owner() instead of a hardcoded 3. #3829 raised the default limit 3 -> 5 without updating create_community_with_owner_enforces_per_owner_limit or transfer_ownership_returns_limit_reached_for_maxed_transferee; both have failed on main since. Seeding from the enforced limit fixes them and keeps them limit-change-proof. Verified: full buzz-db PG-gated suite 153/153 (was 151/2 on main); verdict mutant now FAILS the routed test; fmt + clippy clean. Co-authored-by: Tyler <109685178+tlongwell-block@users.noreply.github.com> Signed-off-by: Tyler <109685178+tlongwell-block@users.noreply.github.com>