aboutsummaryrefslogtreecommitdiff
path: root/crates/ide/src/syntax_highlighting/tests.rs
diff options
context:
space:
mode:
authorLukas Wirth <[email protected]>2021-05-15 16:23:20 +0100
committerLukas Wirth <[email protected]>2021-05-15 16:32:28 +0100
commit4b5b54279ad74316837bcdc7daa195d82bd13d3a (patch)
tree6d377e0cc11c5b0f50ddc49ba004068098772809 /crates/ide/src/syntax_highlighting/tests.rs
parent3da52d2e936bf797d7fe1a9c6c9fad78e19c7d83 (diff)
Attach comments to ast::Impl
Diffstat (limited to 'crates/ide/src/syntax_highlighting/tests.rs')
-rw-r--r--crates/ide/src/syntax_highlighting/tests.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/crates/ide/src/syntax_highlighting/tests.rs b/crates/ide/src/syntax_highlighting/tests.rs
index 32f2d9038..95408dfb2 100644
--- a/crates/ide/src/syntax_highlighting/tests.rs
+++ b/crates/ide/src/syntax_highlighting/tests.rs
@@ -524,6 +524,11 @@ fn main() {
524fn test_highlight_doc_comment() { 524fn test_highlight_doc_comment() {
525 check_highlighting( 525 check_highlighting(
526 r#" 526 r#"
527//! This is a module to test doc injection.
528//! ```
529//! fn test() {}
530//! ```
531
527/// ``` 532/// ```
528/// let _ = "early doctests should not go boom"; 533/// let _ = "early doctests should not go boom";
529/// ``` 534/// ```
@@ -531,6 +536,13 @@ struct Foo {
531 bar: bool, 536 bar: bool,
532} 537}
533 538
539/// This is an impl with a code block.
540///
541/// ```
542/// fn foo() {
543///
544/// }
545/// ```
534impl Foo { 546impl Foo {
535 /// ``` 547 /// ```
536 /// let _ = "Call me 548 /// let _ = "Call me