Feature request: Run cargo bench
benchmarks via nextest
#2125
smklein
started this conversation in
Feature requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Motivation
"cargo nextest" has pretty much entirely replaced my usage of "cargo test", which is neat. The setup and utilities are great, and the configuration is powerful. However, when writing benchmarks, which often share a lot of logic from test utilities, things get more painful.
https://nexte.st/docs/integrations/criterion describes how "benchmarks can be run as tests" - specifically, they can run a single execution for validity - but running "benchmarks as benchmarks" is not currently possible with nextest.
Proposal
It would be nice for nextest to support a
cargo nextest bench
option, which runs benchmarks serially as benchmarks.This would be distinct from
cargo nextest run --benches
, which does not attempt to do benchmarking, but it would allow benchmarks to utilize other features from nextest (e.g. setup scripts) for benchmarking purposes.Alternatives
No response
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions