rust-testing

Implement TDD workflows for Rust unit, integration, async, and property-based tests.

Updated Sep 13, 2025
One-click install
npx skills add https://github.com/llmh333/employee_management_spring --skill rust-testing-llmh333
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rust-testing
Source: https://github.com/llmh333/employee_management_spring/tree/main/.gemini/skills/rust-testing
Command: npx skills add https://github.com/llmh333/employee_management_spring --skill rust-testing-llmh333

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It solves the problem of brittle, low-coverage, hard-to-debug Rust testing by providing a repeatable TDD-driven workflow that helps you validate behavior early and maintain correctness over time.

Core Features & Use Cases

  • Test-first (TDD) workflow: Follow RED-GREEN-REFACTOR to drive minimal implementations from failing tests to passing code.
  • Broad test coverage strategies: Cover unit tests, integration tests, async tests with Tokio, and doc tests that stay executable documentation.
  • Advanced quality techniques: Use rstest for parameterized cases, proptest for property-based testing, mockall for isolated dependency mocking, and coverage tooling targets to keep quality measurable.

Quick Start

Use the rust-testing skill to design and implement TDD coverage for a Rust module by writing unit and integration tests first, then adding property-based and async tests as needed, ensuring mocks and coverage thresholds are in place.

Frequently Asked Questions about rust-testing

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I apply TDD workflows for Rust testing?

Rust testing with TDD workflows requires following RED-GREEN-REFACTOR steps to drive minimal implementations from failing tests to passing code, ensuring behavior is validated early and correctness is maintained over time.

What's the best way to write async tests in Rust using Tokio?

Async testing in Rust with Tokio involves applying correct Rust testing constructs and patterns to validate asynchronous behavior across normal and edge cases, ensuring comprehensive test coverage for concurrent code paths.

Can I use mockall for dependency mocking in Rust integration tests?

Yes, Rust integration testing supports isolated dependency mocking using mockall to validate behavior across normal and edge cases, ensuring components are tested independently within comprehensive test coverage strategies.

How do I measure Rust test coverage targets with cargo-llvm-cov?

Rust test coverage measurement with cargo-llvm-cov establishes measurable coverage targets such as 80%, validating that unit, integration, async, property-based, and doc testing scenarios achieve consistent quality thresholds.

Why does my Rust TDD workflow need doc tests alongside unit tests?

Rust doc tests provide executable documentation that stays validated alongside unit tests, ensuring comprehensive test coverage strategies validate behavior across all testing scenarios including normal and edge cases.