Expand description
Common zebra_test types, traits, and functions.
Re-exports§
pub use crate::command::test_cmd;pub use crate::command::CommandExt;pub use crate::command::TestChild;pub use color_eyre;pub use color_eyre::eyre;
Modules§
- prop
- Re-exports the entire public API of proptest so that an import of
preludeallows simply writing, for example,prop::num::i32::ANYrather thanproptest::num::i32::ANYplus a separateuse proptest;.
Macros§
- prop_
assert - Similar to
assert!from std, but returns a test failure instead of panicking if the condition fails. - prop_
assert_ eq - Similar to
assert_eq!from std, but returns a test failure instead of panicking if the condition fails. - prop_
assert_ ne - Similar to
assert_ne!from std, but returns a test failure instead of panicking if the condition fails. - prop_
assume - Rejects the test input if assumptions are not met.
- prop_
compose - Convenience to define functions which produce new strategies.
- prop_
oneof - Produce a strategy which picks one of the listed choices.
- proptest
- Easily define
proptesttests.
Structs§
- Boxed
Strategy - A boxed
Strategytrait object as produced byStrategy::boxed(). - Just
- A
Strategywhich always produces a single value value and never simplifies. - Proptest
Config - Configuration for how a proptest test should be run.
- SBoxed
Strategy - A boxed
Strategytrait object which is alsoSyncandSend, as produced byStrategy::sboxed(). - Stdio
- Describes what to do with a standard I/O stream for a child process when
passed to the
stdin,stdout, andstderrmethods ofCommand.
Enums§
- Test
Case Error - Errors which can be returned from test cases to indicate non-successful completion.
Traits§
- Arbitrary
- Arbitrary determines a canonical
Strategyfor the implementing type. - Rng
- User-level interface for RNGs
- RngCore
- Implementation-level interface for RNGs
- Strategy
- A strategy for producing arbitrary values of a given type.
Functions§
- any
- Generates a
StrategyproducingArbitraryvalues ofA. Unlikearbitrary, it should be used for being explicit on whatAis. For clarity, this may be a good idea. - any_
with - Generates a
StrategyproducingArbitraryvalues ofAwith the given configuration arguments passed inargs. Unlikearbitrary_with, it should be used for being explicit on whatAis. For clarity, this may be a good idea.
Type Aliases§
- Result
- type alias for
Result<T, Report>