rust-testing-quality

rust-testing-quality is a skill for Claude Code from fusengine/agents. It costs 46 tokens per session (1,264 once invoked), scanned A, original, MIT.

A guide to writing and running Rust tests, including unit, integration, documentation, property-based tests, benchmarks, and mutation testing. It also explains which commands are needed for full coverage.

In plain words
What is it for?
Use it when adding, organizing, or running tests in a Rust project, including tests that generate many inputs or check benchmark performance.
Why use it?
It helps avoid missing tests or assuming a green test command checked everything. For example, Rust documentation tests need to be run separately from nextest.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter.

Part of the fuse-rust plugin — 7 skills, 1 agent shipped together

Good fit Use it when adding, organizing, or running tests in a Rust project, including tests that generate many inputs or check benchmark performance.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/fusengine/agents/rust-testing-quality
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add fusengine/agents --skill rust-testing-quality
Clone the repo
git clone --depth 1 https://github.com/fusengine/agents

Made for: Claude Code.

Or install fuse-rust, the plugin that ships this one along with the rest of its 7 skills, 1 agent.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for rust-testing-quality

README.md
[![agentmods](https://agentmods.dev/badge/skills/fusengine/agents/rust-testing-quality/github.svg)](https://agentmods.dev/skills/fusengine/agents/rust-testing-quality)
Your own site
<a href="https://agentmods.dev/skills/fusengine/agents/rust-testing-quality"><img src="https://agentmods.dev/badge/skills/fusengine/agents/rust-testing-quality/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for rust-testing-quality

Your own site · 80×15
<a href="https://agentmods.dev/skills/fusengine/agents/rust-testing-quality"><img src="https://agentmods.dev/badge/skills/fusengine/agents/rust-testing-quality.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 46 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,264 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00046 $0.01264
Opus 5.5 $0.00018 $0.00506
Sonnet 5.5 $0.00009 $0.00253
Haiku 4.5 $0.00005 $0.00126

Measured 22d ago against content hash dffee6b6adc4, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

rust-testing-quality scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 22d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/rust-expert/skills/rust-testing-quality/SKILL.md · 138 lines

How it starts

The opening of the file, as written. The whole thing — 138 lines — stays where its author put it; the contents beside it link to each section on GitHub.

It also covers the nextest doctest pitfall: cargo nextest run never runs doc-tests, so cargo test --doc must always be paired alongside it — a green nextest run alone is not full coverage.

Out of scope: CI pipeline wiring and gate ordering belong to rust-tooling-cicd; non-Rust test suites are not covered.

Rust Testing & Quality

Agent Workflow (MANDATORY)

Before ANY test work, spawn 3 agents in parallel, one Agent call each with a name:

  1. fuse-ai-pilot:explore-codebase - Map existing tests/, #[cfg(test)], benches/
  2. fuse-ai-pilot:research-expert - Verify current nextest/proptest/criterion docs via Context7/Exa
  3. mcp__context7__query-docs - Check crate-specific API (proptest strategies, criterion groups)

After implementation, run fuse-ai-pilot:sniper for validation.


Overview

Test kind Location Runs the code as
Unit #[cfg(test)] mod tests inside the source file Same crate, sees private items
Integration tests/*.rs (each file = own crate) External consumer, public API only
Doc-test ```rust blocks in /// docs Compiled + run as examples
Property proptest, inside unit or integration Generated random inputs + shrinking
Benchmark benches/*.rs with criterion Statistical timing, not correctness

Critical Rules

  1. nextest does NOT run doc-tests - cargo nextest run skips them by design. ALWAYS pair with cargo test --doc. Never treat a green nextest run as full coverage.
  2. Integration tests see only the public API - if a test needs private items, it belongs in #[cfg(test)], not tests/.
  3. Commit proptest-regressions/ - persisted failing seeds must be under version control so failures are reproducible.
  4. harness = false for criterion benches - required in Cargo.toml, or the built-in bench harness collides.
  5. Mutation testing is a gate, not a smoke test - cargo mutants is slow; run it in scheduled CI, not on every push.

Read the full file on GitHub · 138 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 22d ago Changed dffee6b6adc4
  2. 1mo ago Changed 9dc0df6bfc92
  3. 1mo ago First seen · 138 lines · 46 tokens per session scan A 516d8a008788

Subscribe to this mod's changes

rust-testing-quality is a skill published in the GitHub repository fusengine/agents (33 stars, last pushed 7d ago), licensed MIT. It adds 46 tokens to every session and 1,264 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

r-testthat

Best practices for writing R package tests with testthat version 3+. Use this skill when writing or organizing tests for an R package or when improving existing tests that use testthat. It covers test structure and expectations, self-sufficient test design, proper cleanup with withr, fixtures, mocking external…

posit-dev/skills · 77 tokens

craft-pest

Testing Craft CMS 5 plugins and modules with Pest — test isolation, database safety, and the markhuot/craft-pest-core harness. ALWAYS load when writing, running, fixing, or reviewing tests for a Craft plugin or module, and whenever a suite touches a real Craft install. Covers why rollback is opt-in, tests/Pest.php +…

michtio/craftcms-claude-skills · 175 tokens

rust-testing

Design Rust tests that catch real regressions — unit, integration, doc, property, snapshot, and golden tests, and differential tests that prove a port matches its source. Use when writing or reviewing Rust tests, when a change lands without tests, when deciding what form a test should take, when a port needs parity…

rewrite-rs/skills · 86 tokens

phx-verify

Verify Elixir/Phoenix changes — compile, format, and test in one loop. Use after implementation, before PRs, or after fixing bugs.

oliver-kriska/claude-elixir-phoenix · 36 tokens

111-java-maven-dependencies

Use when you need to add or evaluate Maven dependencies that improve code quality or domain modeling — including nullness annotations (JSpecify), static analysis (Error Prone + NullAway), functional programming (VAVR), architecture testing (ArchUnit), or money and currency support (JavaMoney) — and want a…

jabrena/plinth · 133 tokens

130-java-testing-strategies

Use when you need to apply testing strategies for Java code — RIGHT-BICEP to guide test creation, A-TRIP for test quality characteristics, or CORRECT for verifying boundary conditions. This should trigger for requests such as Review Java code for testing strategies; Apply RIGHT-BICEP testing strategies in Java code…

jabrena/plinth · 96 tokens