Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide-completion/src/context/tests.rs')
-rw-r--r--crates/ide-completion/src/context/tests.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/crates/ide-completion/src/context/tests.rs b/crates/ide-completion/src/context/tests.rs
index b929d36ce6..09a9b6f112 100644
--- a/crates/ide-completion/src/context/tests.rs
+++ b/crates/ide-completion/src/context/tests.rs
@@ -257,6 +257,22 @@ fn foo() -> Foo {
}
#[test]
+fn expected_type_match_arm_block_body_without_leading_char() {
+ cov_mark::check!(expected_type_match_arm_body_without_leading_char);
+ cov_mark::check!(expected_type_match_arm_body_with_leading_char);
+ check_expected_type_and_name(
+ r#"
+struct Foo;
+enum E { X }
+fn foo() -> Foo {
+ match E::X { Foo::X => { $0 } }
+}
+"#,
+ expect![[r#"ty: Foo, name: ?"#]],
+ );
+}
+
+#[test]
fn expected_type_match_body_arm_with_leading_char() {
cov_mark::check!(expected_type_match_arm_body_with_leading_char);
check_expected_type_and_name(