prevtest (previous test) is a test caching solution for nextest.
Work in progress.
The main proposal is described in the high-level design document.
The repo currently contains an early implementation of the first increment, still missing the file hashing shortcut, signal handling, integration tests, etc.
From this crate's directory:
cargo install --path . --lockedAdd this to your project's .config/nextest.toml:
experimental = ["wrapper-scripts"]
[scripts.wrapper.prevtest]
command = "prevtest"
target-runner = "overrides-wrapper"
[[profile.default.scripts]]
filter = "all()"
run-wrapper = "prevtest"Then run:
cargo nextest runSet PREVTEST_FORCE=1 to force test execution while still updating the cache.