aboutsummaryrefslogtreecommitdiff
path: root/crates/ide_completion
diff options
context:
space:
mode:
authorKirill Bulatov <[email protected]>2021-03-03 22:10:20 +0000
committerKirill Bulatov <[email protected]>2021-03-08 21:59:20 +0000
commit6ca6f101c1b3a795ff6578bae6e01cb4b818e14c (patch)
treeb0dbf09a39dab6c81e9a710b1a301e83a15bb465 /crates/ide_completion
parent5b7d928075f3bedf71f754444c1532976d52eae4 (diff)
Test for fuzzy unresolved path maatch
Diffstat (limited to 'crates/ide_completion')
-rw-r--r--crates/ide_completion/src/completions/flyimport.rs22
1 files changed, 22 insertions, 0 deletions
diff --git a/crates/ide_completion/src/completions/flyimport.rs b/crates/ide_completion/src/completions/flyimport.rs
index c5b3c9e27..efb91fe0e 100644
--- a/crates/ide_completion/src/completions/flyimport.rs
+++ b/crates/ide_completion/src/completions/flyimport.rs
@@ -921,4 +921,26 @@ fn main() {
921}"#, 921}"#,
922 ); 922 );
923 } 923 }
924
925 #[test]
926 fn fuzzy_unresolved_path() {
927 check(
928 r#"
929mod foo {
930 pub mod bar {
931 pub struct Item;
932
933 impl Item {
934 pub const TEST_ASSOC: usize = 3;
935 }
936 }
937}
938
939fn main() {
940 let zz = "sdsd";
941 bar::Ass$0
942}"#,
943 expect![[]],
944 )
945 }
924} 946}