|
Ran
|
Jobs
1
|
Files
116
|
Run time
1min
|
Badge
README BADGES
|
push
github
Merge rust-bitcoin/rust-bitcoin#3840: Address mutants in units <a class=hub.com/rust-bitcoin/rust-bitcoin/commit/<a class="double-link" href="https://git"><a class=hub.com/rust-bitcoin/rust-bitcoin/commit/286bf900b1c100d2f5d0a0d45f31a5bf5a0a26ce">286bf900b Address mutants in units (Shing Him Ng) Pull request description: Preemptively addressing these mutants before introducing the `cargo-mutants` workflow. There are several types of changes: - Changes that address mutants that were actually missing - Changes that address test values that cause `cargo-mutants` to think mutants were missed. For example, `cargo-mutants` will replace the return values for unsigned integer types with 0 and 1. While this case might be tested, the test might be testing this with a call that results in 0 or 1. When `cargo-mutants` substitutes the function call with `Ok(1)`, the test will still pass, and it will consider this a mutant. `cargo-mutants` also replaces operations (+, -, /, %), bitwise operations (&, |, ^, etc), so an operation such as `3 - 2` results in a mutant because changing it to `3 / 2` yields the same result - TODOs to ignore functions/impls in the future I uased the following `mutants.toml` config file when running `cargo mutants` and skipped the `Debug`, `Arbitrary`, `Display`, and `Error` impls and the `kani` test: ``` additional_cargo_args = ["--all-features"] examine_globs = ["units/src/**/*.rs"] exclude_globs = ["units/src/amount/verification.rs"] exclude_re = ["impl Debug", "impl Arbitrary", "impl Display", ".*Error", "<impl Visitor for VisitOptAmt<X>>"] ``` I wasn't sure the code for Displaying things needed to be tested with `cargo mutants`, but I'm less sure about the errors so i can kill those mutants too if needed ACKs for top commit: tcharding: ACK 286bf900b1c100d2f5d0a0d45f31a5bf5a0a26ce apoelstra: ACK 286bf900b1c100d2f5d0a0d45f31a5bf5a0a26ce; successfully ran local tests Tree-SHA512: 3db9598a5f720a20676c0feb2dc7de749f7
199 of 200 new or added lines in 8 files covered. (99.5%)
20689 of 24935 relevant lines covered (82.97%)
17452.15 hits per line
| ID | Job ID | Ran | Files | Coverage | |
|---|---|---|---|---|---|
| 1 | 12622292995.1 | 0 |
82.97 |
GitHub Action Run |