pub struct TestTimeOptions {
pub error_on_excess: bool,
pub unit_threshold: TimeThreshold,
pub integration_threshold: TimeThreshold,
pub doctest_threshold: TimeThreshold,
}
🔬This is a nightly-only experimental API. (
test
)Expand description
Structure with parameters for calculating test execution time.
Fields§
§error_on_excess: bool
🔬This is a nightly-only experimental API. (
test
)Denotes if the test critical execution time limit excess should be considered a test failure.
unit_threshold: TimeThreshold
🔬This is a nightly-only experimental API. (
§test
)integration_threshold: TimeThreshold
🔬This is a nightly-only experimental API. (
§test
)doctest_threshold: TimeThreshold
🔬This is a nightly-only experimental API. (
test
)Implementations§
Source§impl TestTimeOptions
impl TestTimeOptions
pub fn new_from_env(error_on_excess: bool) -> Self
🔬This is a nightly-only experimental API. (
test
)pub fn is_warn(&self, test: &TestDesc, exec_time: &TestExecTime) -> bool
🔬This is a nightly-only experimental API. (
test
)pub fn is_critical(&self, test: &TestDesc, exec_time: &TestExecTime) -> bool
🔬This is a nightly-only experimental API. (
test
)Trait Implementations§
Source§impl Clone for TestTimeOptions
impl Clone for TestTimeOptions
Source§fn clone(&self) -> TestTimeOptions
fn clone(&self) -> TestTimeOptions
🔬This is a nightly-only experimental API. (
test
)Returns a copy of the value. Read more
Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
🔬This is a nightly-only experimental API. (
test
)Performs copy-assignment from
source
. Read moreSource§impl Debug for TestTimeOptions
impl Debug for TestTimeOptions
Source§impl Default for TestTimeOptions
impl Default for TestTimeOptions
Source§fn default() -> TestTimeOptions
fn default() -> TestTimeOptions
🔬This is a nightly-only experimental API. (
test
)Returns the “default value” for a type. Read more
Source§impl PartialEq for TestTimeOptions
impl PartialEq for TestTimeOptions
Source§fn eq(&self, other: &TestTimeOptions) -> bool
fn eq(&self, other: &TestTimeOptions) -> bool
🔬This is a nightly-only experimental API. (
test
)Tests for
self
and other
values to be equal, and is used by ==
.impl Copy for TestTimeOptions
impl Eq for TestTimeOptions
impl StructuralPartialEq for TestTimeOptions
Auto Trait Implementations§
impl Freeze for TestTimeOptions
impl RefUnwindSafe for TestTimeOptions
impl Send for TestTimeOptions
impl Sync for TestTimeOptions
impl Unpin for TestTimeOptions
impl UnwindSafe for TestTimeOptions
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
🔬This is a nightly-only experimental API. (
test
)Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)Source§impl<T> ToOwned for Twhere
T: Clone,
impl<T> ToOwned for Twhere
T: Clone,
Source§type Owned = T
type Owned = T
🔬This is a nightly-only experimental API. (
test
)The resulting type after obtaining ownership.
Source§fn to_owned(&self) -> T
fn to_owned(&self) -> T
🔬This is a nightly-only experimental API. (
test
)Creates owned data from borrowed data, usually by cloning. Read more
Source§fn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬This is a nightly-only experimental API. (
test
)Uses borrowed data to replace owned data, usually by cloning. Read more