rust-testing

Write and run unit, integration, async, and property-based Rust tests.

Updated Apr 6, 2026
One-click install
npx skills add https://github.com/thangvawn/agent_financial --skill rust-testing-thangvawn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rust-testing
Source: https://github.com/thangvawn/agent_financial/tree/main/.cursor/skills/rust-testing
Command: npx skills add https://github.com/thangvawn/agent_financial --skill rust-testing-thangvawn

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill unit addresses the challenge of efficiently testing Rust code using Test-Driven Development (TDD) and various testing patterns, including unit tests, integration tests, async testing, and property-based testing.

Core Features & Use Cases

  • Unit Testing: Write and run unit tests for individual functions and methods.
  • Integration Testing: Test the interaction between different parts of the code.
  • Async Testing: Perform asynchronous tests for Rust code with async/await features.
  • Property-Based Testing: Use property-based testing to verify the correctness of code.
  • Use Case: A developer uses this Skill to write comprehensive tests for their Rust library, ensuring that all edge cases are covered and that the code behaves as expected.

Quick Start

Run the 'run_tests' script in the 'scripts' directory to execute all tests for the current project.

Frequently Asked Questions about rust-testing

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

FAQPage Schema
How do I write unit tests and integration tests for a Rust project?

You can write unit tests and integration tests for a Rust project by applying the provided Rust testing patterns. This Skill guides you in testing individual functions and the interaction between code parts to ensure reliability.

Can I perform async testing for Rust code with async/await features?

Yes, you can perform async testing for Rust code with async/await features. This Skill provides specific patterns to handle asynchronous tests, ensuring your async functions behave as expected during execution.

What is the best way to apply Test-Driven Development (TDD) methodology in Rust?

The best way to apply Test-Driven Development (TDD) in Rust is by following the TDD methodology included in this Skill. It helps you structure unit and integration tests to ensure code reliability and maintainability before implementation.

How do I use property-based testing to verify the correctness of Rust code?

You use property-based testing to verify the correctness of Rust code by applying the patterns provided here. This approach tests code against generated inputs to ensure all edge cases are covered and behavior remains correct.

Does this Rust testing Skill include mocking and coverage capabilities?

Yes, this Rust testing Skill includes mocking and coverage capabilities. Alongside TDD and property-based testing, it provides patterns to mock dependencies and measure test coverage for your Rust projects.

How do I execute all tests for my current Rust project automatically?

You execute all tests for your current Rust project automatically by running the 'run_tests' script in the 'scripts' directory. This automates the testing process for your Rust library or application.