Trait test_context::AsyncTestContext[][src]

pub trait AsyncTestContext where
    Self: Sized
{ #[must_use] fn setup<'async_trait>(
    ) -> Pin<Box<dyn Future<Output = Self> + Send + 'async_trait>>
    where
        Self: 'async_trait
; #[must_use] fn teardown<'async_trait>(
        self
    ) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
    where
        Self: Send + 'async_trait
, { ... } }

The trait to implement to get setup/teardown functionality for async tests.

Required methods

#[must_use]fn setup<'async_trait>(
) -> Pin<Box<dyn Future<Output = Self> + Send + 'async_trait>> where
    Self: 'async_trait, 
[src]

Create the context. This is run once before each test that uses the context.

Loading content...

Provided methods

#[must_use]fn teardown<'async_trait>(
    self
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
    Self: Send + 'async_trait, 
[src]

Perform any additional cleanup of the context besides that already provided by normal “drop” semantics.

Loading content...

Implementors

Loading content...