Struct test::test::TestTimeOptions
source · 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
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
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
Returns the “default value” for a type. Read more
source§impl PartialEq<TestTimeOptions> for TestTimeOptions
impl PartialEq<TestTimeOptions> for TestTimeOptions
source§fn eq(&self, other: &TestTimeOptions) -> bool
fn eq(&self, other: &TestTimeOptions) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.