pub struct TestModifiers {
pub skipped: AtomicBool,
pub skip_reason: Mutex<Option<String>>,
pub expected_failure: AtomicBool,
pub slow: AtomicBool,
pub timeout_override: Mutex<Option<u64>>,
}Expand description
Runtime test modifiers set by test.skip(), test.fail(), test.slow() inside
a test body. Shared via Arc between the NAPI layer (JS thread writes) and the
Rust worker (reads after callback returns).
Uses atomics and std::sync::Mutex for cross-thread safety. No actual race —
the worker reads strictly after the TSFN callback completes.
Fields§
§skipped: AtomicBoolSet by test.skip() / test.fixme() inside test body.
skip_reason: Mutex<Option<String>>Reason for runtime skip.
expected_failure: AtomicBoolSet by test.fail() inside test body — inverts pass/fail.
slow: AtomicBoolSet by test.slow() inside test body.
timeout_override: Mutex<Option<u64>>Set by testInfo.setTimeout() inside test body.
Trait Implementations§
Source§impl Debug for TestModifiers
impl Debug for TestModifiers
Auto Trait Implementations§
impl !Freeze for TestModifiers
impl RefUnwindSafe for TestModifiers
impl Send for TestModifiers
impl Sync for TestModifiers
impl Unpin for TestModifiers
impl UnsafeUnpin for TestModifiers
impl UnwindSafe for TestModifiers
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more