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.rs | 80 |
1 files changed, 40 insertions, 40 deletions
diff --git a/crates/ide-assists/src/tests/generated.rs b/crates/ide-assists/src/tests/generated.rs index 524af20013..e5a8d675a9 100644 --- a/crates/ide-assists/src/tests/generated.rs +++ b/crates/ide-assists/src/tests/generated.rs @@ -2314,46 +2314,6 @@ fn handle(action: Action) { } #[test] -fn doctest_replace_or_else_with_or() { - check_doc_test( - "replace_or_else_with_or", - r#####" -//- minicore:option -fn foo() { - let a = Some(1); - a.unwra$0p_or_else(|| 2); -} -"#####, - r#####" -fn foo() { - let a = Some(1); - a.unwrap_or(2); -} -"#####, - ) -} - -#[test] -fn doctest_replace_or_with_or_else() { - check_doc_test( - "replace_or_with_or_else", - r#####" -//- minicore:option -fn foo() { - let a = Some(1); - a.unwra$0p_or(2); -} -"#####, - r#####" -fn foo() { - let a = Some(1); - a.unwrap_or_else(|| 2); -} -"#####, - ) -} - -#[test] fn doctest_replace_qualified_name_with_use() { check_doc_test( "replace_qualified_name_with_use", @@ -2428,6 +2388,46 @@ fn main() { } #[test] +fn doctest_replace_with_eager_method() { + check_doc_test( + "replace_with_eager_method", + r#####" +//- minicore:option, fn +fn foo() { + let a = Some(1); + a.unwra$0p_or_else(|| 2); +} +"#####, + r#####" +fn foo() { + let a = Some(1); + a.unwrap_or(2); +} +"#####, + ) +} + +#[test] +fn doctest_replace_with_lazy_method() { + check_doc_test( + "replace_with_lazy_method", + r#####" +//- minicore:option, fn +fn foo() { + let a = Some(1); + a.unwra$0p_or(2); +} +"#####, + r#####" +fn foo() { + let a = Some(1); + a.unwrap_or_else(|| 2); +} +"#####, + ) +} + +#[test] fn doctest_sort_items() { check_doc_test( "sort_items", |