Install any skill in seconds. Free to start, no credit card required.
Get Started Free →loulanyue/rust-testing
Rust testing patterns including unit tests, integration tests, async testing, property-based testing, mocking, and coverage. Follows TDD methodology.
Passed 23 of 23 test cases with the skill, and 21 of 23 without it.
2 fixed21 passed either way0 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 2 test cases the skill fixed. Same model, same prompt, with and without the skill.
When following TDD in Rust, a developer creates a function signature before writing the actual logic. They are tempted to return dummy values like `0` or `Default::default()`. What built-in Rust macro should be placed in the function body to cause the initial test to panic with a 'not yet implemented' message during the RED step?
| Checked | Without skill | With skill |
|---|---|---|
| Uses the todo!() macro in the function stub. | Missed | Passed |
The instructions your model reads when the skill loads.
Comprehensive Rust testing patterns for writing reliable, maintainable tests following TDD methodology.
#[test] in a #[cfg(test)] module, rstest for parameterized tests, or proptest for property-based testsRED → Write a failing test first
GREEN → Write minimal code to pass the test
REFACTOR → Improve code while keeping tests green
REPEAT → Continue with next requirement
// RED: Write test first, use todo!() as placeholder
pub fn add(a: i32, b: i32) -> i32 { todo!() }
#[cfg(test)]
test cases passed, vs 21 / 23 without
Published skills whose descriptions closely match this one, with their headline benchmark lift.
More skills from the same source and nearby in the registry, with their headline benchmark lift.