pub enum FixtureScope {
Unique,
Test,
Global,
}
Expand description
Represents the scope of a fixture.
The scope determines the test’s “lifetime” of the fixture.
Variants§
Unique
Fixture is used only once.
The fixture is (re)created everytime we request it.
Test
Fixture is associated to a test.
The fixture is (re)created for every tests but created only once per test. This is usefull if the test (or its fixtures’ dependencies) reuse the same fixture twice.
Global
Fixture is global for each test
The fixture is created only once and teardown at end of the tests run.
Auto Trait Implementations§
impl Freeze for FixtureScope
impl RefUnwindSafe for FixtureScope
impl Send for FixtureScope
impl Sync for FixtureScope
impl Unpin for FixtureScope
impl UnwindSafe for FixtureScope
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