pub enum MonkeyResult<E> {
MonkeyOk(),
MonkeyErr {
minimum_failure: E,
original_failure: E,
some_other_failures: Vec<E>,
success_count: u64,
shrink_count: u64,
seed: u64,
title: Option<String>,
reason: String,
},
}Expand description
Result summary from evaluation of a property tested.
Variants§
MonkeyOk()
A successful monkey test result.
MonkeyErr
A failed monkey test result.
Fields
minimum_failure: EThe minimum example found that disproves the property. In case a shinker is provided, this is the shrunken failure example, possibly separate from original failure. In other cases the same as original failure.
original_failure: EThe original (first found) example that disproves the property.
some_other_failures: Vec<E>Other examples that also disproves the property. In case a shinker is provided, this vector is populated with non-minimum values found as part of the shrinking process of the original failure example. Some found failures may be exluded from list if many failure examples are found
seed: u64The seed used for generating the examples. Can be useful for reproducing the failed test run.
reason: StringReason for the failed propert. This reason is from the minimum failure example. Other failures can have other reasons not shown here.
Implementations§
Source§impl<E> MonkeyResult<E>
impl<E> MonkeyResult<E>
Sourcepub fn assert_minimum_failure(&self, expected_minimum_failure: E) -> &Self
pub fn assert_minimum_failure(&self, expected_minimum_failure: E) -> &Self
Verify that the result is a failure and that the minimum failure equals
given argument expected_minimum_failure.
§Panics
The function panics if there is not a failure result matching
expected_minimum_failue.