Function transaction_diesel::test_run [] [src]

pub fn test_run<'a, Cn, T, E, Tx>(cn: &'a Cn, tx: Tx) -> T where
    Cn: Connection,
    E: From<Error>,
    Tx: Transaction<Ctx = DieselContext<'a, Cn>, Item = T, Err = E>, 

run the given function insed a transaction using the given connection but do not commit it. Panics if the given function returns an Err. This is usefull for testing