classify / cover / collect: distribution labels in the Report #8

Closed
opened 2026-09-13 21:24:22 +09:00 by natsukium · 1 comment
Owner

Missing

Distribution reporting: classify cond label, cover pct label, collect value, with counts in the Report.

Why

There is no way to see what a generator actually produces: how often gen.optional yields absent, how deep gen.recursive nests, whether gen.float ever hits an edge value. Hedgehog classify / cover, fast-check statistics, Hypothesis event/target all exist for this reason, and it is the only cheap way to verify #2 / #3 / #5 behave as intended.

Suggested shape

  • A property can be wrapped: label (v: "depth=${toString (depth v)}") prop.
  • Report.labels = { "<label>" = count; }.
  • cover adds a required minimum; failing coverage fails the check (Hedgehog semantics).
  • Shares the cases list with #1 / the replay issue.
## Missing Distribution reporting: `classify cond label`, `cover pct label`, `collect value`, with counts in the `Report`. ## Why There is no way to see what a generator actually produces: how often `gen.optional` yields absent, how deep `gen.recursive` nests, whether `gen.float` ever hits an edge value. Hedgehog `classify` / `cover`, fast-check `statistics`, Hypothesis `event`/`target` all exist for this reason, and it is the only cheap way to verify #2 / #3 / #5 behave as intended. ## Suggested shape - A property can be wrapped: `label (v: "depth=${toString (depth v)}") prop`. - `Report.labels = { "<label>" = count; }`. - `cover` adds a required minimum; failing coverage fails the check (Hedgehog semantics). - Shares the `cases` list with #1 / the replay issue.
Author
Owner

Implemented in c9f6ec5, pushed to main.

Implemented in c9f6ec5, pushed to main.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
natsukium/nixcheck#8
No description provided.