src/maverick/skills/maverick_rust_testing/SKILL.md
Rust testing patterns (unit, integration, property-based)
npx skillsauth add get2knowio/maverick maverick-rust-testingInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn test_add() {
assert_eq!(add(2, 2), 4);
}
#[test]
#[should_panic(expected = "overflow")]
fn test_overflow() {
add(i32::MAX, 1);
}
}
Place in tests/ directory (separate crate).
use proptest::prelude::*;
proptest! {
#[test]
fn test_reverse_involutive(ref vec in prop::collection::vec(any::<i32>(), 0..100)) {
let reversed_twice: Vec<_> = vec.iter().rev().rev().cloned().collect();
assert_eq!(vec, &reversed_twice);
}
}
development
Rust unsafe code, FFI, and safety invariants
development
Rust performance optimization and zero-cost abstractions
development
Rust ownership, borrowing, and lifetimes
development
Rust error handling with Result, Error trait, anyhow, thiserror