diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-10-14 13:22:54 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2019-10-14 13:22:54 +0100 |
commit | 1f4fbc0035a6a9ee1b599a3aa9f236989633a9f7 (patch) | |
tree | 40ee641fc90ecf384199ac537542deb71689d30d /crates/ra_batch/src/lib.rs | |
parent | bc7de5d47a56b9f2ab44f833130ba6d77aefe864 (diff) | |
parent | 1555a1aa0d5d45e4b317db272c07ad3e8470553d (diff) |
Merge #2007
2007: remove one more dependency on source roots r=matklad a=matklad
Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_batch/src/lib.rs')
-rw-r--r-- | crates/ra_batch/src/lib.rs | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/crates/ra_batch/src/lib.rs b/crates/ra_batch/src/lib.rs index 602beb439..df49eb13d 100644 --- a/crates/ra_batch/src/lib.rs +++ b/crates/ra_batch/src/lib.rs | |||
@@ -141,14 +141,8 @@ mod tests { | |||
141 | #[test] | 141 | #[test] |
142 | fn test_loading_rust_analyzer() { | 142 | fn test_loading_rust_analyzer() { |
143 | let path = Path::new(env!("CARGO_MANIFEST_DIR")).parent().unwrap().parent().unwrap(); | 143 | let path = Path::new(env!("CARGO_MANIFEST_DIR")).parent().unwrap().parent().unwrap(); |
144 | let (host, roots) = load_cargo(path).unwrap(); | 144 | let (host, _roots) = load_cargo(path).unwrap(); |
145 | let mut n_crates = 0; | 145 | let n_crates = Crate::all(host.raw_database()).len(); |
146 | for (root, _) in roots { | ||
147 | for _krate in Crate::source_root_crates(host.raw_database(), root) { | ||
148 | n_crates += 1; | ||
149 | } | ||
150 | } | ||
151 | |||
152 | // RA has quite a few crates, but the exact count doesn't matter | 146 | // RA has quite a few crates, but the exact count doesn't matter |
153 | assert!(n_crates > 20); | 147 | assert!(n_crates > 20); |
154 | } | 148 | } |