test_case

Macro test_case 

Source
macro_rules! test_case {
    ($name:ident, $test_fn:expr) => { ... };
}
Expand description

Macro to create test cases that work exactly like Rust’s built-in #[test] attribute but with our framework’s enhanced features (hooks, Docker, etc.)

IDE Support: This macro creates a standard #[test] function that RustRover will recognize.

Usage:

#[cfg(test)]
mod tests {
    use super::*;
    use rust_test_harness::test_case;
     
    test_case!(test_something, |ctx| {
        // Your test logic here
        assert_eq!(2 + 2, 4);
        Ok(())
    });
     
    test_case!(test_with_docker, |ctx| {
        // Test with Docker context
        Ok(())
    });
}