aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvsrs <[email protected]>2020-06-03 13:29:03 +0100
committervsrs <[email protected]>2020-06-05 13:00:31 +0100
commit92cfc0f2a1edd4e825d4dea96d4f96dcea513629 (patch)
tree31598aaf86c6b5396cb8675859093f76bc92d555
parent5d0c1aa1625a17723209e537590dc7fc7f181df1 (diff)
Add enum hover action test.
-rw-r--r--crates/ra_ide/src/hover.rs15
1 files changed, 15 insertions, 0 deletions
diff --git a/crates/ra_ide/src/hover.rs b/crates/ra_ide/src/hover.rs
index 2fbe0ba1f..62df07459 100644
--- a/crates/ra_ide/src/hover.rs
+++ b/crates/ra_ide/src/hover.rs
@@ -1161,4 +1161,19 @@ fn func(foo: i32) { if true { <|>foo; }; }
1161 ); 1161 );
1162 assert_impl_action(&actions[0], 6); 1162 assert_impl_action(&actions[0], 6);
1163 } 1163 }
1164
1165 #[test]
1166 fn test_hover_enum_has_impl_action() {
1167 let (_, actions) = check_hover_result(
1168 "
1169 //- /lib.rs
1170 enum foo<|>() {
1171 A,
1172 B
1173 }
1174 ",
1175 &["enum foo"],
1176 );
1177 assert_impl_action(&actions[0], 5);
1178 }
1164} 1179}