CtrlK
BlogDocsLog inGet started
Tessl Logo

testland/rust-unit-tests

Rust unit testing with the built-in `cargo test` harness - `#[test]` in `#[cfg(test)] mod tests` blocks, `assert_eq!` / `assert_ne!` / `assert!` macros, `#[should_panic(expected)]`, `Result<(), E>` test returns, integration tests in `tests/`, doc tests in `///` comments, runner flags (`--test-threads=1`, `--nocapture`, `--ignored`), `#[ignore]` marking, coverage via cargo-llvm-cov / tarpaulin, and Criterion benchmarks on stable. Includes framework choice (stdlib `#[test]` is the default; rstest for 4+ parameterized case pairs or shared fixtures via references) and test-authoring conventions (inline `#[cfg(test)]` placement, assertion-macro selection, async runtime requirements). References cover rstest parametrize + fixtures and Rust mocking with mockall (`#[automock]` / `mock!`). Use for any Rust unit-test task: writing tests, testing panics or Results, doc tests, coverage gates, benchmarks, or CI wiring.

72

Quality

91%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide

SecuritybySnyk

Passed

No findings from the security scan

Overview
Quality
Evals
Security
Files

Quality

Content

86%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

A well-structured, highly actionable skill body with executable examples and clean progressive disclosure into real reference files. Slight conciseness and explicit-validation-loop gaps are the only weaknesses.

DimensionReasoningScore

Conciseness

Mostly lean — tables, code blocks, and an anti-patterns table carry the content — with a few explanatory sentences ('The Result return allows ? in test bodies...', 'Each file in tests/ compiles to its own binary') that could be trimmed without loss.

4 / 5

Actionability

Fully executable, copy-paste-ready code and cargo commands throughout, with specific examples covering the common cases (assertions, should_panic, Result returns, integration/doc tests, coverage, benchmarks, CI).

5 / 5

Workflow Clarity

A clear Step 1–8 sequence plus an authoring-conventions checklist with a 'Conflicting signals → stop and ask' checkpoint; minor validation gaps (no explicit validate→fix→retry loop) keep it just below 5.

4 / 5

Progressive Disclosure

Well-signaled one-level-deep references to references/rstest.md and references/rust-mocking.md (both verified to exist), with rstest/mocking detail appropriately split out and the overview body kept navigable.

5 / 5

Total

18

/

20

Passed

Description

92%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

A strong, specific description with explicit 'what' and 'when' guidance and concrete trigger phrases. Slightly jargon-heavy in places, but overall highly actionable and distinct.

DimensionReasoningScore

Specificity

Lists multiple specific concrete actions across the testing domain — 'writing tests, testing panics or Results, doc tests, coverage gates, benchmarks, or CI wiring' — plus named macros, flags, and tools, giving comprehensive coverage.

5 / 5

Completeness

Explicitly answers 'what' (the long enumeration of capabilities and conventions) and 'when' via the explicit trigger clause 'Use for any Rust unit-test task: ...' with concrete trigger phrases.

5 / 5

Trigger Term Quality

Includes natural phrases users say ('writing tests', 'doc tests', 'coverage gates', 'CI wiring') but leans heavier on technical jargon (attribute names, runner flags) than on synonyms or file extensions, leaving a few natural variants missing.

4 / 5

Distinctiveness Conflict Risk

Carves a clear Rust unit-testing niche and names adjacent skills (rstest, mockall via references, proptest-testing) so it is unlikely to trigger for the wrong skill.

5 / 5

Total

19

/

20

Passed

Validation

100%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation16 / 16 Passed

Validation for skill structure

No warnings or errors.

Reviewed

Table of Contents