Skip to content

Commit

Permalink
[Doc] Arbitrary : add a note about the derive macro in Arbitrary's do…
Browse files Browse the repository at this point in the history
…cumentation
  • Loading branch information
matthew-russo committed Jun 15, 2024
1 parent 24412f5 commit 060cfbe
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions proptest/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
- Setting `PROPTEST_MAX_DEFAULT_SIZE_RANGE` now customizes the default `SizeRange`
used by the default strategies for collections (like `Vec`). The default remains 100.

### Documentation
- Reference the derive macro in Arbitrary's documentation

### Bug Fixes
- Fixed issue where config contextualization would clobber existing failure persistence config

Expand Down
5 changes: 5 additions & 0 deletions proptest/src/arbitrary/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,15 @@ use crate::strategy::Strategy;
/// which may be lifted in the future as the [generic associated types (GAT)]
/// feature of Rust is implemented and stabilized.
///
/// If you do not have unique constraints on how to generate the data for your
/// custom types, consider using [the derive macro] to implement Arbitrary
///
/// [generic associated types (GAT)]: https://github.com/rust-lang/rust/issues/44265
///
/// [`Strategy`]: ../strategy/trait.Strategy.html
///
/// [the derive macro]: https://docs.rs/proptest-derive/latest/proptest_derive/
///
/// [HaskellQC]:
/// https://hackage.haskell.org/package/QuickCheck/docs/Test-QuickCheck-Arbitrary.html
pub trait Arbitrary: Sized + fmt::Debug {
Expand Down

0 comments on commit 060cfbe

Please sign in to comment.