Struct assertor::AssertionResult
source · pub struct AssertionResult { /* private fields */ }
Expand description
Contains assertion results which will be shown in the assertion messages.
Implementations§
source§impl AssertionResult
impl AssertionResult
pub fn add_fact<K: Into<String>, V: Into<String>>( self, key: K, value: V ) -> Self
pub fn add_simple_fact<V: Into<String>>(self, value: V) -> Self
pub fn add_splitter(self) -> Self
sourcepub fn generate_message(&self) -> String
pub fn generate_message(&self) -> String
Generates an assertion message from the assertion result.
pub fn facts(&self) -> &Vec<Fact>
Trait Implementations§
source§impl AssertionStrategy<()> for AssertionResult
impl AssertionStrategy<()> for AssertionResult
source§impl AssertionStrategy<CheckThatResult> for AssertionResult
impl AssertionStrategy<CheckThatResult> for AssertionResult
source§fn do_fail(self) -> CheckThatResult
fn do_fail(self) -> CheckThatResult
Behavior when assertion fails.
source§fn do_ok(self) -> CheckThatResult
fn do_ok(self) -> CheckThatResult
Behavior when assertion passes.
source§impl Clone for AssertionResult
impl Clone for AssertionResult
source§fn clone(&self) -> AssertionResult
fn clone(&self) -> AssertionResult
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl RefUnwindSafe for AssertionResult
impl Send for AssertionResult
impl Sync for AssertionResult
impl Unpin for AssertionResult
impl UnwindSafe for AssertionResult
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more