pub enum TestStatus {
Success,
Error(TestError),
Failure(TestFailure),
Skipped(TestSkipped),
}
Expand description
Status of a test case
Variants§
Success
Success
Error(TestError)
Test case has a <error />
tag
Failure(TestFailure)
Test case has a <failure />
tag
Skipped(TestSkipped)
Test case has a <skipped />
tag
Implementations§
Source§impl TestStatus
impl TestStatus
Sourcepub fn is_success(&self) -> bool
pub fn is_success(&self) -> bool
Returns true
if the TestStatus
is Success
.
Sourcepub fn error_as_ref(&self) -> &TestError
pub fn error_as_ref(&self) -> &TestError
Sourcepub fn is_failure(&self) -> bool
pub fn is_failure(&self) -> bool
Returns true
if the TestStatus
is Failure(_)
.
Sourcepub fn failure_as_ref(&self) -> &TestFailure
pub fn failure_as_ref(&self) -> &TestFailure
Returns the contained Failure(_)
value as a reference
§Panics
Panics if the value is not a Failure(_)
Sourcepub fn is_skipped(&self) -> bool
pub fn is_skipped(&self) -> bool
Returns true
if the TestStatus
is Skipped(_)
.
Sourcepub fn skipped_as_ref(&self) -> &TestSkipped
pub fn skipped_as_ref(&self) -> &TestSkipped
Returns the contained Skipped(_)
value as a reference
§Panics
Panics if the value is not a Skipped(_)
Trait Implementations§
Source§impl Clone for TestStatus
impl Clone for TestStatus
Source§fn clone(&self) -> TestStatus
fn clone(&self) -> TestStatus
Returns a duplicate 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 moreSource§impl Debug for TestStatus
impl Debug for TestStatus
Source§impl Default for TestStatus
impl Default for TestStatus
Source§fn default() -> TestStatus
fn default() -> TestStatus
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for TestStatus
impl<'de> Deserialize<'de> for TestStatus
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for TestStatus
impl RefUnwindSafe for TestStatus
impl Send for TestStatus
impl Sync for TestStatus
impl Unpin for TestStatus
impl UnwindSafe for TestStatus
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