SIGN IN SIGN UP

test(rustd): stand up servers that misbehave, and close 36 of the 40

`codecov/patch/rust-afd` compares head to the PR base, so the patch it grades
is the whole §1–§4 diff rather than the newest commit. Forty lines in `afd_db`
and `afd_redis` failed it, every one of them a branch written for a datastore
that misbehaves — which the live-service suite cannot reach, because the
services it points at are correct.

Two fixtures, both of which stand up a server rather than mocking a client:

- `fake_redis.rs` answers RESP wrongly on purpose, from a rule table a test can
  change MID-FLIGHT. That is what reaches a redial which succeeds and then
  cannot resubscribe — a fixture fixed at spawn time can describe the before or
  the after, never the transition.
- `fault_net.rs` proxies the lane's Postgres and can stop relaying, holding
  accepted sockets OPEN. Closing them would give a clean refusal, which is the
  case these branches are not about; the branch under test is the one where no
  answer ever comes.

Workspace 98.74% → 99.87% (3192/3196); integration suite 23 → 30 tests.

Four lines remain, and they are two different things. `migrate.rs:196`
genuinely resists: `begin()` must fail on a connection everything earlier in
`apply_all` would have failed on first, and the gap before it holds no await
point to hook. It is named under codecov.yml's own clause.

`pump.rs` 76/104/126 are NOT untestable — they are unreachable because of a
defect. `HubInner` owns the only command sender and the pump holds an
`Arc<HubInner>` for life, so `recv()` can never return None and the pub/sub
pump task can never terminate. §7 fixes it under Invariant C2 (stop → join →
drop) by giving the pump a `Weak`; changing the hub's lifetime belongs in the
commit that builds the supervisor, not in a coverage pass. Recording them as
"genuinely resist" would bake a bug into the record as a property of the code.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
K
Kishore Kumar committed
bdbc8d7bbcefad4afcd8ffbce6a01208e46186b7
Parent: b365eba