pub enum TestExpected {
Truthy,
Value(Expr),
ErrorContains(String),
RoundTrip {
codecs: Vec<Symbol>,
},
}Expand description
Expectation a SimTest checks against the evaluated expression.
Variants§
Truthy
The result must be truthy.
Value(Expr)
The result must equal this expression.
ErrorContains(String)
Evaluation must fail with an error containing this substring.
RoundTrip
The expression must round-trip unchanged through these codecs.
Implementations§
Trait Implementations§
Source§impl Clone for TestExpected
impl Clone for TestExpected
Source§fn clone(&self) -> TestExpected
fn clone(&self) -> TestExpected
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 TestExpected
impl Debug for TestExpected
impl Eq for TestExpected
Source§impl PartialEq for TestExpected
impl PartialEq for TestExpected
Source§fn eq(&self, other: &TestExpected) -> bool
fn eq(&self, other: &TestExpected) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for TestExpected
Auto Trait Implementations§
impl Freeze for TestExpected
impl RefUnwindSafe for TestExpected
impl Send for TestExpected
impl Sync for TestExpected
impl Unpin for TestExpected
impl UnsafeUnpin for TestExpected
impl UnwindSafe for TestExpected
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.