mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-11-03 05:13:35 +00:00
Add completion test
This commit is contained in:
parent
2a755495d0
commit
90bd99f1bb
1 changed files with 20 additions and 0 deletions
|
|
@ -785,4 +785,24 @@ fn main() {
|
|||
",
|
||||
)
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn tuple_index_completion() {
|
||||
check(
|
||||
r#"
|
||||
struct I;
|
||||
impl I {
|
||||
fn i_method(&self) {}
|
||||
}
|
||||
struct S((), I);
|
||||
|
||||
fn f(s: S) {
|
||||
s.1.$0
|
||||
}
|
||||
"#,
|
||||
expect![[r#"
|
||||
me i_method() fn(&self)
|
||||
"#]],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue