pub struct Expect<T>(pub T);Tuple Fields§
§0: TImplementations§
Source§impl Expect<bool>
impl Expect<bool>
pub fn to_be_true(self) -> Self
pub fn to_be_false(self) -> Self
Source§impl<T: PartialOrd + Debug> Expect<T>
impl<T: PartialOrd + Debug> Expect<T>
pub fn to_be_greater_than(self, other: T) -> Self
pub fn to_be_less_than(self, other: T) -> Self
pub fn to_be_at_least(self, other: T) -> Self
pub fn to_be_at_most(self, other: T) -> Self
Source§impl Expect<&str>
impl Expect<&str>
pub fn to_contain(self, needle: &str) -> Self
pub fn to_start_with(self, prefix: &str) -> Self
pub fn to_end_with(self, suffix: &str) -> Self
pub fn to_match(self, regex: &str) -> Self
Source§impl Expect<String>
impl Expect<String>
pub fn to_contain(self, needle: &str) -> Self
pub fn to_start_with(self, prefix: &str) -> Self
pub fn to_end_with(self, suffix: &str) -> Self
pub fn to_match(self, regex: &str) -> Self
Source§impl<T: Debug + PartialEq> Expect<Vec<T>>
impl<T: Debug + PartialEq> Expect<Vec<T>>
pub fn to_have_length(self, len: usize) -> Self
pub fn to_contain(self, item: T) -> Self
pub fn to_be_empty(self) -> Self
Source§impl<T: Debug> Expect<Option<T>>
impl<T: Debug> Expect<Option<T>>
pub fn to_be_some(self) -> Self
pub fn to_be_none(self) -> Self
Auto Trait Implementations§
impl<T> Freeze for Expect<T>where
T: Freeze,
impl<T> RefUnwindSafe for Expect<T>where
T: RefUnwindSafe,
impl<T> Send for Expect<T>where
T: Send,
impl<T> Sync for Expect<T>where
T: Sync,
impl<T> Unpin for Expect<T>where
T: Unpin,
impl<T> UnsafeUnpin for Expect<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Expect<T>where
T: UnwindSafe,
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more