Skip to content

Commit ab196d7

Browse files
committed
normalize doctest output
1 parent e2aa3fc commit ab196d7

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

tests/rustdoc-ui/doctest/force-no-merge.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@
33
//@ compile-flags: --test --test-args=--test-threads=1 --merge-doctests=no -Z unstable-options
44
//@ normalize-stderr: ".*doctest_bundle_2018.rs:\d+:\d+" -> "doctest_bundle_2018.rs:$$LINE:$$COL"
55

6+
//@ normalize-stdout: "tests/rustdoc-ui" -> "$$DIR"
7+
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
8+
//@ normalize-stdout: "ran in \d+\.\d+s" -> "ran in $$TIME"
9+
//@ normalize-stdout: "compilation took \d+\.\d+s" -> "compilation took $$TIME"
10+
//@ normalize-stdout: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"
11+
612
/// These two doctests should not force-merge, even though this crate has edition 2024 and the
713
/// individual doctests are not annotated.
814
///
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
running 2 tests
3-
test tests/rustdoc-ui/doctest/force-no-merge.rs - Foo (line 14) ... ok
4-
test tests/rustdoc-ui/doctest/force-no-merge.rs - Foo (line 9) ... ok
3+
test $DIR/doctest/force-no-merge.rs - Foo (line 15) ... ok
4+
test $DIR/doctest/force-no-merge.rs - Foo (line 20) ... ok
55

6-
test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.34s
6+
test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in $TIME
77

0 commit comments

Comments
 (0)