diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-09-04 22:54:42 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2020-09-04 22:54:42 +0100 |
commit | 0275b08d1521606fa733f76fe5d5707717456fb4 (patch) | |
tree | 5af1036e93cd7cdc3425c913a20864d668ecf1c2 /crates/assists/src/tests | |
parent | 9dfa69a44ac5054b5c970fdd13ade4d50f4c097d (diff) | |
parent | e1b8d836a9b64169a8337be674c78cac20940b92 (diff) |
Merge #5940
5940: Implement "Replace `impl Trait` function argument with the named generic" assist. r=matklad a=alekseysidorov
Fixes #5085
Co-authored-by: Aleksei Sidorov <[email protected]>
Diffstat (limited to 'crates/assists/src/tests')
-rw-r--r-- | crates/assists/src/tests/generated.rs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/crates/assists/src/tests/generated.rs b/crates/assists/src/tests/generated.rs index 04c8fd1f9..27d15adb0 100644 --- a/crates/assists/src/tests/generated.rs +++ b/crates/assists/src/tests/generated.rs | |||
@@ -815,6 +815,19 @@ fn handle(action: Action) { | |||
815 | } | 815 | } |
816 | 816 | ||
817 | #[test] | 817 | #[test] |
818 | fn doctest_replace_impl_trait_with_generic() { | ||
819 | check_doc_test( | ||
820 | "replace_impl_trait_with_generic", | ||
821 | r#####" | ||
822 | fn foo(bar: <|>impl Bar) {} | ||
823 | "#####, | ||
824 | r#####" | ||
825 | fn foo<B: Bar>(bar: B) {} | ||
826 | "#####, | ||
827 | ) | ||
828 | } | ||
829 | |||
830 | #[test] | ||
818 | fn doctest_replace_let_with_if_let() { | 831 | fn doctest_replace_let_with_if_let() { |
819 | check_doc_test( | 832 | check_doc_test( |
820 | "replace_let_with_if_let", | 833 | "replace_let_with_if_let", |