aboutsummaryrefslogtreecommitdiff
path: root/crates/ide_completion/src/tests
diff options
context:
space:
mode:
authorLukas Wirth <[email protected]>2021-06-17 12:59:31 +0100
committerLukas Wirth <[email protected]>2021-06-17 12:59:31 +0100
commit9353f36516e5b4026ce3a181d578c3a63876a18f (patch)
tree2909822a4406e05f66a79b180ce1d2327062b5f1 /crates/ide_completion/src/tests
parent2225db2eb48bd8c8fdf399c50652d3f95c851ace (diff)
Fix incorrect completions in empty braced use statement
Diffstat (limited to 'crates/ide_completion/src/tests')
-rw-r--r--crates/ide_completion/src/tests/use_tree.rs17
1 files changed, 17 insertions, 0 deletions
diff --git a/crates/ide_completion/src/tests/use_tree.rs b/crates/ide_completion/src/tests/use_tree.rs
index 878bc42bf..7e6748ccc 100644
--- a/crates/ide_completion/src/tests/use_tree.rs
+++ b/crates/ide_completion/src/tests/use_tree.rs
@@ -236,3 +236,20 @@ pub use $0;
236 "#]], 236 "#]],
237 ); 237 );
238} 238}
239
240#[test]
241fn use_tree_braces_at_start() {
242 check(
243 r#"
244struct X;
245mod bar {}
246use {$0};
247"#,
248 expect![[r#"
249 kw crate::
250 kw self::
251 kw super::
252 md bar
253 "#]],
254 );
255}