aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_analysis/tests/test/main.rs
diff options
context:
space:
mode:
authorFlorian Diebold <[email protected]>2018-12-29 23:03:52 +0000
committerFlorian Diebold <[email protected]>2019-01-04 18:14:52 +0000
commit0ad13b9477fc6b15cbfbd521a79ea97bc0e79953 (patch)
treedae217eb806c0b874039089e0c6f70ef5f331e4f /crates/ra_analysis/tests/test/main.rs
parent6ab0e292d2f8302d4e051cdaa49dd440855c1348 (diff)
Add a test for self field completion
Needed to add a default crate graph in the analysis for that.
Diffstat (limited to 'crates/ra_analysis/tests/test/main.rs')
-rw-r--r--crates/ra_analysis/tests/test/main.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/crates/ra_analysis/tests/test/main.rs b/crates/ra_analysis/tests/test/main.rs
index 859778024..beeae1e19 100644
--- a/crates/ra_analysis/tests/test/main.rs
+++ b/crates/ra_analysis/tests/test/main.rs
@@ -138,14 +138,14 @@ fn test_resolve_parent_module_for_inline() {
138fn test_resolve_crate_root() { 138fn test_resolve_crate_root() {
139 let mock = MockAnalysis::with_files( 139 let mock = MockAnalysis::with_files(
140 " 140 "
141 //- /lib.rs 141 //- /bar.rs
142 mod foo; 142 mod foo;
143 //- /foo.rs 143 //- /bar/foo.rs
144 // emtpy <|> 144 // emtpy <|>
145 ", 145 ",
146 ); 146 );
147 let root_file = mock.id_of("/lib.rs"); 147 let root_file = mock.id_of("/bar.rs");
148 let mod_file = mock.id_of("/foo.rs"); 148 let mod_file = mock.id_of("/bar/foo.rs");
149 let mut host = mock.analysis_host(); 149 let mut host = mock.analysis_host();
150 assert!(host.analysis().crate_for(mod_file).unwrap().is_empty()); 150 assert!(host.analysis().crate_for(mod_file).unwrap().is_empty());
151 151