aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2020-05-02 09:57:37 +0100
committerAleksey Kladov <[email protected]>2020-05-02 09:57:37 +0100
commit247d32cbfdc2683ee4f6fd1474b65840131551dc (patch)
treeb2939c408de7c3f8de299a106b8d5e9da4cfa5bc
parent3c96de5380a09fe06752ce146edeb017ae8c701c (diff)
Test/check the whole package
Closes #4255
-rw-r--r--crates/rust-analyzer/src/main_loop/handlers.rs6
-rw-r--r--crates/rust-analyzer/tests/heavy_tests/main.rs4
2 files changed, 3 insertions, 7 deletions
diff --git a/crates/rust-analyzer/src/main_loop/handlers.rs b/crates/rust-analyzer/src/main_loop/handlers.rs
index 0f623949e..914062902 100644
--- a/crates/rust-analyzer/src/main_loop/handlers.rs
+++ b/crates/rust-analyzer/src/main_loop/handlers.rs
@@ -400,11 +400,7 @@ pub fn handle_runnables(
400 range: Default::default(), 400 range: Default::default(),
401 label: format!("cargo {} -p {}", cmd, spec.package), 401 label: format!("cargo {} -p {}", cmd, spec.package),
402 bin: "cargo".to_string(), 402 bin: "cargo".to_string(),
403 args: { 403 args: vec![cmd.to_string(), "--package".to_string(), spec.package.clone()],
404 let mut args = vec![cmd.to_string()];
405 spec.clone().push_to(&mut args);
406 args
407 },
408 extra_args: Vec::new(), 404 extra_args: Vec::new(),
409 env: FxHashMap::default(), 405 env: FxHashMap::default(),
410 cwd: workspace_root.map(|root| root.to_owned()), 406 cwd: workspace_root.map(|root| root.to_owned()),
diff --git a/crates/rust-analyzer/tests/heavy_tests/main.rs b/crates/rust-analyzer/tests/heavy_tests/main.rs
index 07b8114c6..a218da76d 100644
--- a/crates/rust-analyzer/tests/heavy_tests/main.rs
+++ b/crates/rust-analyzer/tests/heavy_tests/main.rs
@@ -149,7 +149,7 @@ fn main() {}
149 "cwd": server.path().join("foo") 149 "cwd": server.path().join("foo")
150 }, 150 },
151 { 151 {
152 "args": [ "check", "--package", "foo", "--test", "spam" ], 152 "args": [ "check", "--package", "foo" ],
153 "extraArgs": [], 153 "extraArgs": [],
154 "bin": "cargo", 154 "bin": "cargo",
155 "env": {}, 155 "env": {},
@@ -161,7 +161,7 @@ fn main() {}
161 "cwd": server.path().join("foo") 161 "cwd": server.path().join("foo")
162 }, 162 },
163 { 163 {
164 "args": [ "test", "--package", "foo", "--test", "spam" ], 164 "args": [ "test", "--package", "foo" ],
165 "extraArgs": [], 165 "extraArgs": [],
166 "bin": "cargo", 166 "bin": "cargo",
167 "env": {}, 167 "env": {},