From 5bc4672bd11ca518c0ba9ef973cc65aeff696e11 Mon Sep 17 00:00:00 2001 From: Rex <4276518+rexmas@users.noreply.github.com> Date: Sun, 15 Dec 2024 11:57:41 -0800 Subject: [PATCH] proptest-derive: prepare 0.5.1 patch release (#538) * proptest-derive: prepare 0.5.1 patch release * [fix] update proptest import in tests * [fix] update compiletest to pull in proptest --------- Co-authored-by: Matthew Russo --- proptest-derive/CHANGELOG.md | 13 +++++++++++++ proptest-derive/Cargo.toml | 16 ++++++++-------- proptest-derive/src/tests.rs | 6 +++--- proptest-derive/tests/compiletest.rs | 2 +- 4 files changed, 25 insertions(+), 12 deletions(-) diff --git a/proptest-derive/CHANGELOG.md b/proptest-derive/CHANGELOG.md index 15061d9a..c3949f42 100644 --- a/proptest-derive/CHANGELOG.md +++ b/proptest-derive/CHANGELOG.md @@ -1,5 +1,18 @@ ## Unreleased +## 0.5.1 + +- Fix non-local impl nightly warning with allow(non_local_definitions) + ((\#531)[https://github.com/proptest-rs/proptest/pull/531]) +- Adds support for re-exporting crate. `proptest-derive` now works correctly + when `proptest` is re-exported from another crate. This removes the + requirement for `proptest` to be a direct dependency. + ((\#530)[https://github.com/proptest-rs/proptest/pull/530]) +- Fix bounds generation for generics in derive(Arbitrary). The implementation + of UseTracker expects that iteration over items of used_map gives items in + insertion order. However, the order of BTreeSet is based on Ord, not + insertion. ((\#511)[https://github.com/proptest-rs/proptest/pull/511]) + ## 0.5 ### Features diff --git a/proptest-derive/Cargo.toml b/proptest-derive/Cargo.toml index f7d6ba3e..6b3992de 100644 --- a/proptest-derive/Cargo.toml +++ b/proptest-derive/Cargo.toml @@ -1,15 +1,15 @@ [package] -name = "proptest-derive" -version = "0.5.0" -authors = ["Mazdak Farrokhzad "] -license = "MIT OR Apache-2.0" -readme = "README.md" +name = "proptest-derive" +version = "0.5.1" +authors = ["Mazdak Farrokhzad "] +license = "MIT OR Apache-2.0" +readme = "README.md" -repository = "https://github.com/proptest-rs/proptest" +repository = "https://github.com/proptest-rs/proptest" documentation = "https://proptest-rs.github.io/proptest/proptest-derive/index.html" -keywords = ["derive", "arbitrary", "proptest", "testing", "quickcheck"] -categories = ["development-tools::testing"] +keywords = ["derive", "arbitrary", "proptest", "testing", "quickcheck"] +categories = ["development-tools::testing"] description = """ Custom-derive for the Arbitrary trait of proptest. diff --git a/proptest-derive/src/tests.rs b/proptest-derive/src/tests.rs index ca2d7d9a..9c0c92d4 100644 --- a/proptest-derive/src/tests.rs +++ b/proptest-derive/src/tests.rs @@ -82,7 +82,7 @@ test! { #[allow(non_upper_case_globals)] #[allow(clippy::arc_with_non_send_sync)] const _: () = { - extern crate proptest as _proptest; + use proptest as _proptest; impl _proptest::arbitrary::Arbitrary for MyUnitStruct { type Parameters = (); type Strategy = fn() -> Self; @@ -104,7 +104,7 @@ test! { #[allow(non_upper_case_globals)] #[allow(clippy::arc_with_non_send_sync)] const _: () = { - extern crate proptest as _proptest; + use proptest as _proptest; impl _proptest::arbitrary::Arbitrary for MyTupleUnitStruct { type Parameters = (); type Strategy = fn() -> Self; @@ -126,7 +126,7 @@ test! { #[allow(non_upper_case_globals)] #[allow(clippy::arc_with_non_send_sync)] const _: () = { - extern crate proptest as _proptest; + use proptest as _proptest; impl _proptest::arbitrary::Arbitrary for MyNamedUnitStruct { type Parameters = (); type Strategy = fn() -> Self; diff --git a/proptest-derive/tests/compiletest.rs b/proptest-derive/tests/compiletest.rs index 11357ee0..8d51be21 100644 --- a/proptest-derive/tests/compiletest.rs +++ b/proptest-derive/tests/compiletest.rs @@ -15,7 +15,7 @@ fn run_mode(src: &'static str, mode: &'static str) { config.mode = mode.parse().expect("invalid mode"); config.target_rustcflags = - Some("-L ../target/debug/deps --edition=2018".to_owned()); + Some("-L ../target/debug/deps --extern proptest --edition=2021".to_owned()); if let Ok(name) = env::var("TESTNAME") { config.filters = vec![name]; }