pub struct AnnotationAssertion<'a> { /* private fields */ }Implementations§
Source§impl<'a> AnnotationAssertion<'a>
impl<'a> AnnotationAssertion<'a>
pub fn label(self, expected: &str) -> Self
pub fn data<F>(self, assertion: F) -> Selfwhere
F: FnOnce(DataAssertion<'a>),
pub fn parameter_count(self, expected: usize) -> Self
Sourcepub fn has_parameter(self, key: &str) -> Self
pub fn has_parameter(self, key: &str) -> Self
Assert that a parameter with the given key exists (any value)
Sourcepub fn no_parameter(self, key: &str) -> Self
pub fn no_parameter(self, key: &str) -> Self
Assert that a parameter with the given key does NOT exist
Sourcepub fn has_parameter_with_value(self, key: &str, value: &str) -> Self
pub fn has_parameter_with_value(self, key: &str, value: &str) -> Self
Assert that a parameter with the given key has the expected value
Sourcepub fn parameter(
self,
index: usize,
expected_key: &str,
expected_value: &str,
) -> Self
pub fn parameter( self, index: usize, expected_key: &str, expected_value: &str, ) -> Self
Assert on a specific parameter by index
Sourcepub fn parameter_key(self, index: usize, expected_key: &str) -> Self
pub fn parameter_key(self, index: usize, expected_key: &str) -> Self
Assert that parameter at given index has the expected key (any value)
pub fn child_count(self, expected: usize) -> Self
pub fn child<F>(self, index: usize, assertion: F) -> Selfwhere
F: FnOnce(ContentItemAssertion<'a>),
Auto Trait Implementations§
impl<'a> Freeze for AnnotationAssertion<'a>
impl<'a> RefUnwindSafe for AnnotationAssertion<'a>
impl<'a> Send for AnnotationAssertion<'a>
impl<'a> Sync for AnnotationAssertion<'a>
impl<'a> Unpin for AnnotationAssertion<'a>
impl<'a> UnsafeUnpin for AnnotationAssertion<'a>
impl<'a> UnwindSafe for AnnotationAssertion<'a>
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