diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2021-06-11 22:11:35 +0200 |
|---|---|---|
| committer | Guillaume Gomez <guillaume.gomez@huawei.com> | 2021-07-18 11:54:39 +0200 |
| commit | 111cca1fa76e13956610cae02da13758daed8ddf (patch) | |
| tree | 8a5c518b3e3cffd54bcedd97f7bf8e1ba5f07eaf | |
| parent | 6ca0e5ed39dd9ff4661a0c99c15592da171bffcf (diff) | |
| download | rust-111cca1fa76e13956610cae02da13758daed8ddf.tar.gz rust-111cca1fa76e13956610cae02da13758daed8ddf.zip | |
Add test for rustdoc --nocapture option
| -rw-r--r-- | src/test/rustdoc-ui/nocapture.rs | 10 | ||||
| -rw-r--r-- | src/test/rustdoc-ui/nocapture.stderr | 1 | ||||
| -rw-r--r-- | src/test/rustdoc-ui/nocapture.stdout | 7 |
3 files changed, 18 insertions, 0 deletions
diff --git a/src/test/rustdoc-ui/nocapture.rs b/src/test/rustdoc-ui/nocapture.rs new file mode 100644 index 00000000000..321f5ca08ed --- /dev/null +++ b/src/test/rustdoc-ui/nocapture.rs @@ -0,0 +1,10 @@ +// check-pass +// compile-flags:--test -Zunstable-options --nocapture +// normalize-stdout-test: "src/test/rustdoc-ui" -> "$$DIR" +// normalize-stdout-test "finished in \d+\.\d+s" -> "finished in $$TIME" + +/// ``` +/// println!("hello!"); +/// eprintln!("stderr"); +/// ``` +pub struct Foo; diff --git a/src/test/rustdoc-ui/nocapture.stderr b/src/test/rustdoc-ui/nocapture.stderr new file mode 100644 index 00000000000..af6415db3c7 --- /dev/null +++ b/src/test/rustdoc-ui/nocapture.stderr @@ -0,0 +1 @@ +stderr diff --git a/src/test/rustdoc-ui/nocapture.stdout b/src/test/rustdoc-ui/nocapture.stdout new file mode 100644 index 00000000000..4880e75da70 --- /dev/null +++ b/src/test/rustdoc-ui/nocapture.stdout @@ -0,0 +1,7 @@ + +running 1 test +hello! +test $DIR/nocapture.rs - Foo (line 6) ... ok + +test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in $TIME + |
