pub struct TestRegistration {
pub name: &'static str,
pub module: &'static str,
pub file: &'static str,
pub line: u32,
pub run: fn(RustdvCtx) -> Pin<Box<dyn Future<Output = Result<(), TestError>>>>,
pub timeout: Option<(u64, &'static str)>,
pub skip: bool,
pub expect_fail: bool,
pub expect_error: Option<&'static str>,
}Expand description
One registered test (design-doc §6.1: the cocotb Test option set).
Fields§
§name: &'static str§module: &'static str§file: &'static str§line: u32§run: fn(RustdvCtx) -> Pin<Box<dyn Future<Output = Result<(), TestError>>>>§timeout: Option<(u64, &'static str)>(time, unit), e.g. (100, “us”).
skip: bool§expect_fail: bool§expect_error: Option<&'static str>Pass only if the test fails with this cause (D68). Strictly stronger
than expect_fail, which accepts any failure at all.
Auto Trait Implementations§
impl Freeze for TestRegistration
impl RefUnwindSafe for TestRegistration
impl Send for TestRegistration
impl Sync for TestRegistration
impl Unpin for TestRegistration
impl UnsafeUnpin for TestRegistration
impl UnwindSafe for TestRegistration
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