Skip to content

Commit 1de7848

Browse files
Fix the other test
1 parent bbe1fbd commit 1de7848

File tree

2 files changed

+25
-3
lines changed

2 files changed

+25
-3
lines changed

crates/completion/src/completions/unqualified_path.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -747,7 +747,7 @@ impl My<|>
747747
}
748748

749749
#[test]
750-
fn function_magic_completion() {
750+
fn function_fuzzy_completion() {
751751
check_edit(
752752
"stdin",
753753
r#"
@@ -772,7 +772,7 @@ fn main() {
772772
}
773773

774774
#[test]
775-
fn macro_magic_completion() {
775+
fn macro_fuzzy_completion() {
776776
check_edit(
777777
"macro_with_curlies!",
778778
r#"
@@ -799,7 +799,7 @@ fn main() {
799799
}
800800

801801
#[test]
802-
fn case_insensitive_magic_completion_works() {
802+
fn struct_fuzzy_completion() {
803803
check_edit(
804804
"ThirdStruct",
805805
r#"

crates/completion/src/render.rs

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -425,6 +425,28 @@ fn main() { let _: m::Spam = S<|> }
425425
insert: "m",
426426
kind: Module,
427427
},
428+
CompletionItem {
429+
label: "m::Spam",
430+
source_range: 75..76,
431+
text_edit: TextEdit {
432+
indels: [
433+
Indel {
434+
insert: "use m::Spam;",
435+
delete: 0..0,
436+
},
437+
Indel {
438+
insert: "\n\n",
439+
delete: 0..0,
440+
},
441+
Indel {
442+
insert: "Spam",
443+
delete: 75..76,
444+
},
445+
],
446+
},
447+
kind: Enum,
448+
lookup: "Spam",
449+
},
428450
CompletionItem {
429451
label: "m::Spam::Foo",
430452
source_range: 75..76,

0 commit comments

Comments
 (0)