7180: More readable test r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
bors[bot] 2021-01-06 15:36:37 +00:00 committed by GitHub
commit 1b2d80dfa7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -732,6 +732,16 @@ pub fn foo(_input: TokenStream) -> TokenStream {
),
work_done_progress_params: Default::default(),
});
let value = res.get("contents").unwrap().get("value").unwrap().to_string();
expect![[r#""\n```rust\nfoo::Bar\n```\n\n```rust\nfn bar()\n```""#]].assert_eq(&value);
let value = res.get("contents").unwrap().get("value").unwrap().as_str().unwrap();
expect![[r#"
```rust
foo::Bar
```
```rust
fn bar()
```"#]]
.assert_eq(&value);
}