pub struct Test { /* private fields */ }Expand description
Wraps the Tokio runtime and ensures cleanup happens.
This also passes necessary
Implementations§
Source§impl Test
impl Test
pub fn new(setup: Arc<dyn Setup>) -> Self
Sourcepub async fn try_setup_db(&mut self, builder: Builder) -> Result<Db>
pub async fn try_setup_db(&mut self, builder: Builder) -> Result<Db>
Try to setup a database with models, returns Result for error handling
Sourcepub async fn setup_db(&mut self, builder: Builder) -> Db
pub async fn setup_db(&mut self, builder: Builder) -> Db
Setup a database with models, always with logging enabled
Sourcepub fn capability(&self) -> &'static Capability
pub fn capability(&self) -> &'static Capability
Get the driver capability
Sourcepub fn set_serial(&mut self, serial: bool)
pub fn set_serial(&mut self, serial: bool)
Set whether this test requires exclusive (serial) execution
Auto Trait Implementations§
impl !Freeze for Test
impl !RefUnwindSafe for Test
impl Send for Test
impl Sync for Test
impl Unpin for Test
impl !UnwindSafe for Test
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