]> git.lizzy.rs Git - rust.git/blob - src/test/rustdoc-ui/cfg-test.rs
Auto merge of #61212 - alexcrichton:skip-rustc, r=pietroalbini
[rust.git] / src / test / rustdoc-ui / cfg-test.rs
1 // compile-pass
2 // compile-flags:--test
3 // normalize-stdout-test: "src/test/rustdoc-ui" -> "$$DIR"
4
5 /// this doctest will be ignored:
6 ///
7 /// ```
8 /// assert!(false);
9 /// ```
10 #[cfg(not(test))]
11 pub struct Foo;
12
13 /// this doctest will be tested:
14 ///
15 /// ```
16 /// assert!(true);
17 /// ```
18 #[cfg(test)]
19 pub struct Foo;