Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide-assists/src/tests/generated.rs')
-rw-r--r--crates/ide-assists/src/tests/generated.rs28
1 files changed, 28 insertions, 0 deletions
diff --git a/crates/ide-assists/src/tests/generated.rs b/crates/ide-assists/src/tests/generated.rs
index 48e12a8107..933d45d750 100644
--- a/crates/ide-assists/src/tests/generated.rs
+++ b/crates/ide-assists/src/tests/generated.rs
@@ -3265,6 +3265,20 @@ fn foo() {
}
#[test]
+fn doctest_unwrap_option_return_type() {
+ check_doc_test(
+ "unwrap_option_return_type",
+ r#####"
+//- minicore: option
+fn foo() -> Option<i32>$0 { Some(42i32) }
+"#####,
+ r#####"
+fn foo() -> i32 { 42i32 }
+"#####,
+ )
+}
+
+#[test]
fn doctest_unwrap_result_return_type() {
check_doc_test(
"unwrap_result_return_type",
@@ -3298,6 +3312,20 @@ fn main() {
}
#[test]
+fn doctest_wrap_return_type_in_option() {
+ check_doc_test(
+ "wrap_return_type_in_option",
+ r#####"
+//- minicore: option
+fn foo() -> i32$0 { 42i32 }
+"#####,
+ r#####"
+fn foo() -> Option<i32> { Some(42i32) }
+"#####,
+ )
+}
+
+#[test]
fn doctest_wrap_return_type_in_result() {
check_doc_test(
"wrap_return_type_in_result",