f0562504b7 Exclude deprecated fn from mutation testing (Jamil Lambert, PhD)
4d31b141a8 Improve is_too_precise test (Jamil Lambert, PhD)
a2bae3bb0b Add test for impl Display for Script (Jamil Lambert, PhD)
Pull request description:
Weekly mutation testing found new mutants. There are also some untested mutants in match statements that will be included in future mutation testing once #4654 goes in.
- Add a regression test for the mutants in the `Display` impl for `Script`.
- Improve the existing test for `is_too_precise` to check all four cases.
- Exclude the two deprecated functions that have untested mutants.
Closes#4646
ACKs for top commit:
benalleng:
**tACK** no missed mutants on f056250 I ran with 63b61e9497 rebased in to make sure the match arm and match guard mutations were included
tcharding:
ACK f0562504b7
Tree-SHA512: d109e30be91da2ab243a152b9ef17147337328282ac418fa9d2eebd17c2e2d9b6f7ee095d91ccf58e287c9620cb71a090b0d929c9bf35011feb26e6f28457dd3
Mutation testing generates mutants for deprecated functions
`MedianTimePast::to_consensus_u32` and `Height::to_consensus_u32`.
Add the functions to the mutation testing exclude list.
As of the most recent cargo mutants version v25.2.0 delete match arm
and replace match guard mutations can now be identified on function
name patterns and as a result can be effectively excluded using the
existing mutation exclusion patterns.
The output of Display should not change in stable crates for types that
have well defined formatting and ones that implement FromStr.
Crates that are included in the mutation testing have been updated to
test all relevant Display implementations.
Remove the exclusion so that the Display implementations are included in
mutation testing.
cargo-mutants 25.0.1 introduced a new mutation pattern that deletes an
arm of a match statement or replaces a match guard with true and false.
These are applied in sections that have been excluded from mutation
testing and cause false positives.
The match patterns are also now stricter causing previously excluded
`impl` to be included.
Exclude the new match arm and guard mutation patterns.
Add `impl fmt::` versions for Debug and Display.