Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide/src/hover/tests.rs')
-rw-r--r--crates/ide/src/hover/tests.rs26
1 files changed, 26 insertions, 0 deletions
diff --git a/crates/ide/src/hover/tests.rs b/crates/ide/src/hover/tests.rs
index db2b98090c..e60be577f7 100644
--- a/crates/ide/src/hover/tests.rs
+++ b/crates/ide/src/hover/tests.rs
@@ -8962,3 +8962,29 @@ fn test_hover_function_with_pat_param() {
"#]],
);
}
+
+#[test]
+fn hover_path_inside_block_scope() {
+ check(
+ r#"
+mod m {
+ const _: () = {
+ mod m2 {
+ const C$0: () = ();
+ }
+ };
+}
+"#,
+ expect![[r#"
+ *C*
+
+ ```rust
+ test::m::m2
+ ```
+
+ ```rust
+ const C: () = ()
+ ```
+ "#]],
+ );
+}