pub struct Kit { /* private fields */ }Expand description
The resolver test kit: the fixtures and the checks. See the module documentation.
Implementations§
Source§impl Kit
impl Kit
Sourcepub fn time_aware(self, yes: bool) -> Kit
pub fn time_aware(self, yes: bool) -> Kit
Declares whether the resolver under test is time-aware: whether
evaluate gives, for a cell with several versions, the value of
the latest version with tx <= asof. Time-aware resolvers (a store) are held to it;
others (MapResolver) are not.
Sourcepub fn run<R: Resolver, F: FnOnce(&Fixtures) -> R>(
&self,
load: F,
) -> Result<(), Report>
pub fn run<R: Resolver, F: FnOnce(&Fixtures) -> R>( &self, load: F, ) -> Result<(), Report>
Calls load with the fixtures, then runs every check on the resolver it returns.
Sourcepub fn check(&self, resolver: &dyn Resolver) -> Result<(), Report>
pub fn check(&self, resolver: &dyn Resolver) -> Result<(), Report>
Runs every check on a resolver loaded with fixtures.
Sourcepub fn check_lazy_calls(&self, resolver: &dyn Resolver) -> Result<(), Report>
pub fn check_lazy_calls(&self, resolver: &dyn Resolver) -> Result<(), Report>
Step 7 asks the resolver only for what it reaches, and nothing when the receipt fails before step 7.
What the resolver does not have is unavailable, never a panic.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Kit
impl RefUnwindSafe for Kit
impl Send for Kit
impl Sync for Kit
impl Unpin for Kit
impl UnsafeUnpin for Kit
impl UnwindSafe for Kit
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