mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-11-14 00:47:18 +00:00
Check that the bench path exists before invoking analysis-stats
This commit is contained in:
parent
3a6196bf9e
commit
520d02f561
1 changed files with 1 additions and 0 deletions
|
@ -97,6 +97,7 @@ impl Metrics {
|
||||||
name: &str,
|
name: &str,
|
||||||
path: &str,
|
path: &str,
|
||||||
) -> anyhow::Result<()> {
|
) -> anyhow::Result<()> {
|
||||||
|
assert!(Path::new(path).exists(), "unable to find bench in {path}");
|
||||||
eprintln!("\nMeasuring analysis-stats/{name}");
|
eprintln!("\nMeasuring analysis-stats/{name}");
|
||||||
let output = cmd!(sh, "./target/release/rust-analyzer -q analysis-stats {path}").read()?;
|
let output = cmd!(sh, "./target/release/rust-analyzer -q analysis-stats {path}").read()?;
|
||||||
for (metric, value, unit) in parse_metrics(&output) {
|
for (metric, value, unit) in parse_metrics(&output) {
|
||||||
|
|
Loading…
Reference in a new issue