pub struct VerificationResult {
pub matched: bool,
pub count: usize,
pub expected: VerificationCount,
pub matches: Vec<RequestLogEntry>,
pub error_message: Option<String>,
}Expand description
Result of a verification operation
Fields§
§matched: boolWhether the verification passed
count: usizeActual count of matching requests
expected: VerificationCountExpected count assertion
matches: Vec<RequestLogEntry>All matching request log entries (for inspection)
error_message: Option<String>Error message if verification failed
Implementations§
Source§impl VerificationResult
impl VerificationResult
Sourcepub fn success(
count: usize,
expected: VerificationCount,
matches: Vec<RequestLogEntry>,
) -> Self
pub fn success( count: usize, expected: VerificationCount, matches: Vec<RequestLogEntry>, ) -> Self
Create a successful verification result
Sourcepub fn failure(
count: usize,
expected: VerificationCount,
matches: Vec<RequestLogEntry>,
error_message: String,
) -> Self
pub fn failure( count: usize, expected: VerificationCount, matches: Vec<RequestLogEntry>, error_message: String, ) -> Self
Create a failed verification result
Trait Implementations§
Source§impl Clone for VerificationResult
impl Clone for VerificationResult
Source§fn clone(&self) -> VerificationResult
fn clone(&self) -> VerificationResult
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 VerificationResult
impl Debug for VerificationResult
Source§impl<'de> Deserialize<'de> for VerificationResult
impl<'de> Deserialize<'de> for VerificationResult
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 VerificationResult
impl RefUnwindSafe for VerificationResult
impl Send for VerificationResult
impl Sync for VerificationResult
impl Unpin for VerificationResult
impl UnwindSafe for VerificationResult
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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