Releases: sourcefrog/cargo-mutants
cargo-mutants-1.2.2
-
Don't mutate
unsafe
fns. -
Don't mutate functions that never return (i.e.
-> !
). -
Minimum supported Rust version increased to 1.64 due to changes in dependencies.
-
Some command-line options can now also be configured through environment variables:
CARGO_MUTANTS_JOBS
,CARGO_MUTANTS_TRACE_LEVEL
. -
New command line option
--minimum-test-timeout
and config file variableminimum_test_timeout
join existing environment variableCARGO_MUTANTS_MINIMUM_TEST_TIMEOUT
, to allow boosting the minimum, especially for test environments with poor or uneven throughput. -
Changed: Renamed fields in
outcomes.json
fromcargo_result
toprocess_status
and fromcommand
toargv
. -
Warn if no mutants were generated or if all mutants were unviable.
cargo-mutants-1.2.1
-
Converted most of the docs to a book available at https://mutants.rs/.
-
Fixed: Correctly find submodules that don't use
mod.rs
naming, e.g. when descending fromsrc/foo.rs
tosrc/foo/bar.rs
. Also handle module names that are raw identifiers usingr#
. (Thanks to @kpreid for the report.)
cargo-mutants 1.2.0
Thankful mutants!
-
Fixed: Files that are excluded by filters are also excluded from
--list-files
. -
Fixed:
--exclude-re
and--re
can match against the return type as shown in--list
. -
New: A
.cargo/mutants.toml
file can be used to configure standard filters and cargo args for a project.
cargo-mutants 1.1.1
Spooky mutants!
-
Fixed support for the Mold linker, or for other options passed via
RUSTFLAGS
orCARGO_ENCODED_RUSTFLAGS
. (See the instructions in README.md). -
Source trees are walked by following
mod
statements rather than globbing the directory. This is more correct if there are files that are not referenced bymod
statements. Once attributes on modules are stable in Rust (rust-lang/rust#54727) this opens a path to skip mods using attributes.
cargo-mutants-1.1.0
Fearless concurrency!
-
cargo-mutants can now run multiple cargo build and test tasks in parallel, to make better use of machine resources and find mutants faster, controlled by
--jobs
. -
The minimum Rust version to build cargo-mutants is now 1.63.0. It can still be used to test code under older toolchains.
cargo-mutants-1.0.3
-
cargo-mutants is now finds no uncaught mutants in itself! Various tests were added and improved, particularly around handling timeouts.
-
New:
--re
and--exclude-re
options to filter by mutant name, including the path. The regexps match against the strings printed by--list
.
cargo-mutants-1.0.2
-
New:
cargo mutants --completions
to generate shell completions usingclap_complete
. -
Changed:
carg-mutants
no longer builds in the source directory, and no longer copies thetarget/
directory to the scratch directory. Sincecargo-mutants
now setsRUSTFLAGS
to avoid false failures from warnings, it is unlikely to match the existing build products in the source directorytarget/
, and in fact building there is just likely to cause rebuilds in the source. The behavior now is as if--no-copy-target
was always passed. That option is still accepted, but it has no effect. -
Changed:
cargo-mutants
finds all possible mutations before doing the baseline test, so that you can see earlier how many there will be. -
New: Set
INSTA_UPDATE=no
so that tests that use the Insta library don't write updates back into the source directory, and so don't falsely pass.
cargo-mutants 1.0.1
-
Fixed: Don't try to mutate functions within test targets, e.g. within
tests/**/*.rs
. -
New:
missed.txt
,caught.txt
,timeout.txt
andunviable.txt
files are written in to the output directory to make results easier to review later. -
New:
--output
creates the specified directory if it does not exist. -
Internal: Switched from Argh to Clap for command-line parsing. There may be some small changes in CLI behavior and help formatting.
cargo-mutants 1.0.0
A 1.0 release to celebrate that with the addition of workspace handling, cargo-mutants gives useful results on many Rust projects.
-
New: Supports workspaces containing multiple packages. Mutants are generated for all relevant targets in all packages, and mutants are subject to the tests of their own package.
cargo mutants --list-files --json
andcargo mutants --list --json
now includes package names for each file or mutant. -
Improved: Generate mutations in
cdylib
,rlib
, and ever other*lib
target. For example, this correctly exercises Wasm projects. -
Improved: Write
mutants.out/outcomes.json
after the source-tree build and baseline tests so that it can be observed earlier on. -
Improved:
mutants.out/outcomes.json
includes the commands run.
cargo-mutants 0.2.11
-
New
--exclude
command line option to exclude source files from mutants generation, matching a glob. -
New:
CARGO_MUTANTS_MINIMUM_TEST_TIMEOUT
sets a minimum timeout for cargo tests, in seconds. This can be used to allow more time on slow CI builders. If unset the default is still 20s. -
Added: A new
mutants.out/debug.log
with internal debugging information. -
Improved: The time for check, build, and test is now shown separately in progress bars and output, to give a better indication of which is taking more time in the tree under test. Also, times are show in seconds with one decimal place, and they are styled more consistently.
-
Improved: More consistent use of 'unviable' and other terms for outcomes in the UI.