rust-unit-testing

Installation
SKILL.md

Rust unit testing

Use this guidance when the issue concerns structuring Rust tests so failures clearly explain defects, rather than how to run cargo test.

Working stance

  • Keep setup, query, and assertion as separate concerns.
  • Prefer pure query helpers that return data over helpers that panic halfway through the inspection.
  • Make fallible setup explicit with Result and unwrap only at the test boundary with useful context.
  • Use table tests for behaviour matrices, not for unrelated stories forced into one function.
  • Serialize only tests that touch global state; otherwise let Cargo run them in parallel.
  • Pick the assertion tool that makes the failing value easiest to inspect.

Test shape

Installs
1
GitHub Stars
1
First Seen
Jul 9, 2026
rust-unit-testing — tomevault-io/skills-registry