From a1f42ef8adad95c12fb800aaaead30c4bc938559 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Tue, 4 May 2021 18:21:36 +0300 Subject: internal: env var to toggle slow benches --- crates/rust-analyzer/src/integrated_benchmarks.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'crates') diff --git a/crates/rust-analyzer/src/integrated_benchmarks.rs b/crates/rust-analyzer/src/integrated_benchmarks.rs index 411446b04..3dcbe397a 100644 --- a/crates/rust-analyzer/src/integrated_benchmarks.rs +++ b/crates/rust-analyzer/src/integrated_benchmarks.rs @@ -21,8 +21,7 @@ use crate::cli::load_cargo::{load_workspace_at, LoadCargoConfig}; #[test] fn integrated_highlighting_benchmark() { - // Don't run slow benchmark by default - if true { + if std::env::var("RUN_SLOW_BENCHES").is_err() { return; } @@ -76,8 +75,7 @@ fn integrated_highlighting_benchmark() { #[test] fn integrated_completion_benchmark() { - // Don't run slow benchmark by default - if true { + if std::env::var("RUN_SLOW_BENCHES").is_err() { return; } -- cgit v1.2.3