pub struct Assertion {
pub assertion_type: String,
pub field: Option<String>,
pub value: Option<Value>,
pub values: Option<Vec<Value>>,
}Expand description
A single assertion in a fixture.
Fields§
§assertion_type: StringAssertion type (equals, contains, not_empty, error, etc.).
field: Option<String>Field path to access on the result (dot-separated).
value: Option<Value>Expected value (string, number, bool, or array depending on type).
values: Option<Vec<Value>>Expected values (for contains_all, contains_any).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Assertion
impl<'de> Deserialize<'de> for Assertion
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 Assertion
impl RefUnwindSafe for Assertion
impl Send for Assertion
impl Sync for Assertion
impl Unpin for Assertion
impl UnsafeUnpin for Assertion
impl UnwindSafe for Assertion
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