Add test for multi-line attribute handling in doctests

This commit is contained in:
Guillaume Gomez 2022-04-02 17:05:27 +02:00
parent c37cd911a4
commit 732ed2adc8
2 changed files with 18 additions and 0 deletions

View File

@ -0,0 +1,12 @@
// compile-flags:--test
// normalize-stdout-test: "src/test/rustdoc-ui" -> "$$DIR"
// normalize-stdout-test "finished in \d+\.\d+s" -> "finished in $$TIME"
// check-pass
/// ```
/// # #![cfg_attr(not(dox), deny(missing_abi,
/// # non_ascii_idents))]
///
/// pub struct Bar;
/// ```
pub struct Bar;

View File

@ -0,0 +1,6 @@
running 1 test
test $DIR/doc-comment-multi-line-cfg-attr.rs - Bar (line 6) ... ok
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in $TIME