rxpect

Struct RootExpectations

Source
pub struct RootExpectations<'e, T: Debug> { /* private fields */ }
Expand description

Container for expectations on a value.

Returned by expect

Implementations§

Source§

impl<'e, T: Debug> RootExpectations<'e, T>

Source

pub fn check(self)

Manually run all the expectations

Trait Implementations§

Source§

impl<'e, T: Debug> Drop for RootExpectations<'e, T>

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

impl<'e, T: Debug> ExpectationBuilder<'e, T> for RootExpectations<'e, T>

Source§

fn to_pass(self, expectation: impl Expectation<T> + 'e) -> Self

Add an expectation to the list of expectations

Auto Trait Implementations§

§

impl<'e, T> Freeze for RootExpectations<'e, T>
where T: Freeze,

§

impl<'e, T> !RefUnwindSafe for RootExpectations<'e, T>

§

impl<'e, T> !Send for RootExpectations<'e, T>

§

impl<'e, T> !Sync for RootExpectations<'e, T>

§

impl<'e, T> Unpin for RootExpectations<'e, T>
where T: Unpin,

§

impl<'e, T> !UnwindSafe for RootExpectations<'e, T>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<'e, T, B> EqualityExpectations<T> for B
where T: PartialEq + Debug + 'e, B: ExpectationBuilder<'e, T>,

Source§

fn to_equal(self, value: T) -> B

Expect the value to equal another value Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<'e, T, B> OrderExpectations<T> for B
where T: PartialOrd + Debug + 'e, B: ExpectationBuilder<'e, T>,

Source§

fn to_be_less_than(self, value: T) -> B

Expect the value to be less than another value Read more
Source§

fn to_be_less_than_or_equal(self, value: T) -> B

Expect the value to be less than or equal to another value Read more
Source§

fn to_be_greater_than(self, value: T) -> B

Expect the value to be greater than another value Read more
Source§

fn to_be_greater_than_or_equal(self, value: T) -> B

Expect the value to be greater than or equal to another value Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.