Type Definition git_testtools::Result

source ·
pub type Result<T = ()> = Result<T, Box<dyn Error>>;
Expand description

A result type to allow using the try operator ? in unit tests.

Use it like so:

use git_testtools::Result;

#[test]
fn this() -> Result {
    let x: usize = "42".parse()?;    
    Ok(())

}