Function zebra_test::prelude::prop::strategy::check_strategy_sanity
pub fn check_strategy_sanity<S>(
strategy: S,
options: Option<CheckStrategySanityOptions>,
)
Expand description
Run some tests on the given Strategy
to ensure that it upholds the
simplify/complicate contracts.
This is used to internally test proptest, but is made generally available for external implementations to use as well.
options
can be passed to configure the test; if None
, the defaults are
used. Note that the defaults check for certain properties which are not
actually required by the Strategy
and ValueTree
contracts; if you think
your code is right but it fails the test, consider whether a non-default
configuration is necessary.
This can work with fallible strategies, but limits how many times it will retry failures.