fix: MSRV test

The MSRV test on master was failing for a while. Since MSRV is
the reason to keep unicode-normalization pinned I fixed it to
demonstrate that even without pinning downstream consumers can
maintain the current MSRV.
This commit is contained in:
elsirion 2025-06-04 13:10:39 +02:00
parent b100bf3e22
commit fddecd95e9
No known key found for this signature in database
GPG Key ID: B3005E571AA314DA
3 changed files with 14 additions and 6 deletions

View File

@ -50,7 +50,7 @@ zeroize = { version = "1.5", features = ["zeroize_derive"], optional = true }
# Unexported dependnecies
bitcoin_hashes = { version = ">=0.12, <=0.13", default-features = false }
unicode-normalization = { version = "=0.1.22", default-features = false, optional = true }
unicode-normalization = { version = "0.1.22", default-features = false, optional = true }
[dev-dependencies]
# Enabling the "rand" feature by default to run the benches

View File

@ -31,10 +31,14 @@ Use the `all-languages` feature to enable all languages.
This crate supports Rust v1.41.1 and up and works with `no_std`.
When using older version of Rust, you might have to pin the version of the
`bitcoin_hashes` crate used as such:
```
$ cargo update --package "bitcoin_hashes" --precise "0.12.0"
When using older version of Rust, you might have to pin the versions of several crates, for an up-to-date list refer to [`contrib/test.sh`](contrib/test.sh):
```bash
cargo update --package "bitcoin_hashes" --precise "0.12.0"
cargo update --package "rand" --precise "0.6.0"
cargo update --package "libc" --precise "0.2.151"
cargo update --package "tinyvec" --precise "1.6.0"
cargo update --package "unicode-normalization" --precise "0.1.22"
```
If you enable the `zeroize` feature the MSRV becomes 1.51.

View File

@ -10,6 +10,10 @@ rustc --version
# Pin dependencies as required if we are using MSRV toolchain.
if cargo --version | grep "1\.41"; then
cargo update --package "bitcoin_hashes" --precise "0.12.0"
cargo update --package "rand" --precise "0.6.0"
cargo update --package "libc" --precise "0.2.151"
cargo update --package "tinyvec" --precise "1.6.0"
cargo update --package "unicode-normalization" --precise "0.1.22"
fi
echo "********* Testing std *************"
@ -37,7 +41,7 @@ then
cargo build --verbose --no-default-features
# Build std + no_std, to make sure they are not incompatible
cargo build --verbose
cargo build --verbose
# Test no_std
cargo test --verbose --no-default-features