[−][src]Struct mockers::CallMatch1
Methods
impl<Arg0, Res> CallMatch1<Arg0, Res>
[src]
pub fn new(
mock_id: usize,
mock_type_id: usize,
method_name: &'static str,
type_param_ids: Vec<usize>,
arg0: Box<dyn MatchArg<Arg0>>
) -> Self
[src]
mock_id: usize,
mock_type_id: usize,
method_name: &'static str,
type_param_ids: Vec<usize>,
arg0: Box<dyn MatchArg<Arg0>>
) -> Self
impl<Arg0, Res: 'static> CallMatch1<Arg0, Res>
[src]
pub fn and_return(self, result: Res) -> Expectation1<Arg0, Res>
[src]
pub fn and_panic(self, msg: String) -> Expectation1<Arg0, Res>
[src]
pub fn and_call<F>(self, func: F) -> Expectation1<Arg0, Res> where
F: FnOnce(Arg0) -> Res + 'static,
[src]
F: FnOnce(Arg0) -> Res + 'static,
pub fn never(self) -> ExpectationNever<Self>
[src]
impl<Arg0, Res: Clone + 'static> CallMatch1<Arg0, Res>
[src]
pub fn and_return_clone(self, result: Res) -> Reaction1<Arg0, Res>
[src]
impl<Arg0, Res: 'static> CallMatch1<Arg0, Res>
[src]
pub fn and_call_clone<F>(self, func: F) -> Reaction1<Arg0, Res> where
F: FnMut(Arg0) -> Res + 'static,
[src]
F: FnMut(Arg0) -> Res + 'static,
impl<Arg0, Res: Default + 'static> CallMatch1<Arg0, Res>
[src]
pub fn and_return_default(self) -> Reaction1<Arg0, Res>
[src]
Trait Implementations
impl<Arg0, Res> CallMatch for CallMatch1<Arg0, Res>
[src]
fn matches_args(&self, call: &Call) -> bool
[src]
fn validate(&self, call: &Call) -> Vec<Result<(), String>>
[src]
fn get_mock_id(&self) -> usize
[src]
fn get_mock_type_id(&self) -> usize
[src]
fn get_method_name(&self) -> &'static str
[src]
fn get_type_param_ids(&self) -> &[usize]
[src]
fn describe(&self) -> String
[src]
fn matches(&self, call: &Call) -> bool
[src]
fn matches_target(&self, call: &Call) -> bool
[src]
fn matches_generic_method(&self, call: &Call) -> bool
[src]
fn matches_method(&self, call: &Call) -> bool
[src]
Auto Trait Implementations
impl<Arg0, Res> !Send for CallMatch1<Arg0, Res>
impl<Arg0, Res> !Sync for CallMatch1<Arg0, Res>
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,