Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 8 pull requests #134822

Merged
merged 19 commits into from
Dec 27, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
526d298
ptr::copy: fix docs for the overlapping case
RalfJung Dec 21, 2024
1e3ecd5
Windows: Use WriteFile to write to a UTF-8 console
ChrisDenton Dec 13, 2024
16a4ad7
rustdoc: use shorter paths as preferred canonical paths
notriddle Dec 26, 2024
da1c1c3
Adjust test for slightly changed inlining behavior
notriddle Dec 26, 2024
d997bc9
Simplify or delete normalize directives that don't care about bit-width
Zalathar Dec 25, 2024
2855098
Sort triples by name in platform_support.md
9names Dec 27, 2024
c5e4b72
tools: fix build failure caused by PR #134420
Integral-Tech Dec 27, 2024
5ba0dd4
Don't use `parse_cfg_name_directive` for normalize directives
Zalathar Dec 25, 2024
835fbcb
Remove the `-test` suffix from normalize directives
Zalathar Dec 25, 2024
0af396f
Fix mistake in windows file open
ChrisDenton Dec 24, 2024
454c09e
Spruce up the docs of several queries related to the type/trait syste…
fmease Dec 26, 2024
b9df376
Rollup merge of #134606 - RalfJung:ptr-copy-docs, r=Mark-Simulacrum
jieyouxu Dec 27, 2024
7bbbfc6
Rollup merge of #134622 - ChrisDenton:write-file-utf8, r=Mark-Simulacrum
jieyouxu Dec 27, 2024
bc3e891
Rollup merge of #134759 - Zalathar:normalize, r=jieyouxu
jieyouxu Dec 27, 2024
72ef16f
Rollup merge of #134787 - fmease:spruce-up-queries, r=compiler-errors
jieyouxu Dec 27, 2024
d419cc7
Rollup merge of #134806 - notriddle:notriddle/parent-path-is-better, …
jieyouxu Dec 27, 2024
3980cc6
Rollup merge of #134815 - 9names:sort_platform_md_targets, r=jieyouxu
jieyouxu Dec 27, 2024
f65dc4f
Rollup merge of #134816 - Integral-Tech:pathbuf-refactor, r=lqd
jieyouxu Dec 27, 2024
5544091
Rollup merge of #134819 - ChrisDenton:trunc, r=Mark-Simulacrum
jieyouxu Dec 27, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove the -test suffix from normalize directives
  • Loading branch information
Zalathar committed Dec 27, 2024
commit 835fbcbcab82ce728a7233de6c32a2d206e3336c
4 changes: 2 additions & 2 deletions src/tools/compiletest/src/directive-list.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,10 @@ const KNOWN_DIRECTIVE_NAMES: &[&str] = &[
"needs-xray",
"no-auto-check-cfg",
"no-prefer-dynamic",
"normalize-stderr",
"normalize-stderr-32bit",
"normalize-stderr-64bit",
"normalize-stderr-test",
"normalize-stdout-test",
"normalize-stdout",
"only-16bit",
"only-32bit",
"only-64bit",
Expand Down
4 changes: 2 additions & 2 deletions src/tools/compiletest/src/header.rs
Original file line number Diff line number Diff line change
Expand Up @@ -984,8 +984,8 @@ impl Config {
let (directive_name, _value) = line.split_once(':')?;

let kind = match directive_name {
"normalize-stdout-test" => NormalizeKind::Stdout,
"normalize-stderr-test" => NormalizeKind::Stderr,
"normalize-stdout" => NormalizeKind::Stdout,
"normalize-stderr" => NormalizeKind::Stderr,
"normalize-stderr-32bit" => NormalizeKind::Stderr32bit,
"normalize-stderr-64bit" => NormalizeKind::Stderr64bit,
_ => return None,
Expand Down
7 changes: 3 additions & 4 deletions src/tools/tidy/src/style.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,7 @@ const ANNOTATIONS_TO_IGNORE: &[&str] = &[
"// gdb",
"// lldb",
"// cdb",
"// normalize-stderr-test",
"//@ normalize-stderr-test",
"//@ normalize-stderr",
];

fn generate_problems<'a>(
Expand Down Expand Up @@ -198,8 +197,8 @@ fn should_ignore(line: &str) -> bool {

// For `ui_test`-style UI test directives, also ignore
// - `//@[rev] compile-flags`
// - `//@[rev] normalize-stderr-test`
|| static_regex!("\\s*//@(\\[.*\\]) (compile-flags|normalize-stderr-test|error-pattern).*")
// - `//@[rev] normalize-stderr`
|| static_regex!("\\s*//@(\\[.*\\]) (compile-flags|normalize-stderr|error-pattern).*")
.is_match(line)
// Matching for rustdoc tests commands.
// It allows to prevent them emitting warnings like `line longer than 100 chars`.
Expand Down
6 changes: 3 additions & 3 deletions tests/rustdoc-ui/2024-doctests-checks.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//@ check-pass
//@ edition: 2024
//@ compile-flags: --test --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout-test: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"
//@ normalize-stdout: "tests/rustdoc-ui" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"

/// ```
/// let x = 12;
Expand Down
6 changes: 3 additions & 3 deletions tests/rustdoc-ui/2024-doctests-crate-attribute.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//@ check-pass
//@ edition: 2024
//@ compile-flags: --test --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout-test: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"
//@ normalize-stdout: "tests/rustdoc-ui" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"

/// This doctest is used to ensure that if a crate attribute is present,
/// it will not be part of the merged doctests.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
// line arguments and is only run on windows.
//
//@ only-windows
//@ normalize-stderr-test: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr-test: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ normalize-stderr: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ compile-flags: --cfg cmdline_set @{{src-base}}\argfile\commandline-argfile-missing.args

#[cfg(not(cmdline_set))]
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/argfile/commandline-argfile-missing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
// windows.
//
//@ ignore-windows
//@ normalize-stderr-test: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr-test: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ normalize-stderr: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ compile-flags: --cfg cmdline_set @{{src-base}}/argfile/commandline-argfile-missing.args

#[cfg(not(cmdline_set))]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
// line arguments and is only run on windows.
//
//@ only-windows
//@ normalize-stderr-test: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr-test: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ normalize-stderr-test: "commandline-argfile-missing2.args:[^(]*" -> "commandline-argfile-missing2.args: $$FILE_MISSING "
//@ normalize-stderr: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ normalize-stderr: "commandline-argfile-missing2.args:[^(]*" -> "commandline-argfile-missing2.args: $$FILE_MISSING "
//@ compile-flags: --cfg cmdline_set @{{src-base}}\argfile\commandline-argfile-missing.args @{{src-base}}\argfile\commandline-argfile-badutf8.args @{{src-base}}\argfile\commandline-argfile-missing2.args

#[cfg(not(cmdline_set))]
Expand Down
6 changes: 3 additions & 3 deletions tests/rustdoc-ui/argfile/commandline-argfile-multiple.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
// windows.
//
//@ ignore-windows
//@ normalize-stderr-test: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr-test: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ normalize-stderr-test: "commandline-argfile-missing2.args:[^(]*" -> "commandline-argfile-missing2.args: $$FILE_MISSING "
//@ normalize-stderr: "os error \d+" -> "os error $$ERR"
//@ normalize-stderr: "commandline-argfile-missing.args:[^(]*" -> "commandline-argfile-missing.args: $$FILE_MISSING "
//@ normalize-stderr: "commandline-argfile-missing2.args:[^(]*" -> "commandline-argfile-missing2.args: $$FILE_MISSING "
//@ compile-flags: --cfg cmdline_set @{{src-base}}/argfile/commandline-argfile-missing.args @{{src-base}}/argfile/commandline-argfile-badutf8.args @{{src-base}}/argfile/commandline-argfile-missing2.args

#[cfg(not(cmdline_set))]
Expand Down
2 changes: 1 addition & 1 deletion tests/rustdoc-ui/disambiguator-endswith-named-suffix.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//@ check-pass
//@ normalize-stderr-test: "nightly|beta|1\.[0-9][0-9]\.[0-9]" -> "$$CHANNEL"
//@ normalize-stderr: "nightly|beta|1\.[0-9][0-9]\.[0-9]" -> "$$CHANNEL"

//! [struct@m!()] //~ WARN: unmatched disambiguator `struct` and suffix `!()`
//! [struct@m!{}]
Expand Down
2 changes: 1 addition & 1 deletion tests/rustdoc-ui/doctest/block-doc-comment.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//@ check-pass
//@ compile-flags:--test
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

// This test ensures that no code block is detected in the doc comments.

Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/cfg-test.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//@ check-pass
//@ compile-flags:--test --test-args --test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

// Crates like core have doctests gated on `cfg(not(test))` so we need to make
// sure `cfg(test)` is not active when running `rustdoc --test`.
Expand Down
6 changes: 3 additions & 3 deletions tests/rustdoc-ui/doctest/check-cfg-test.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
//@ check-pass
//@ compile-flags: --test --nocapture --check-cfg=cfg(feature,values("test")) -Z unstable-options
//@ normalize-stderr-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stderr: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

/// The doctest will produce a warning because feature invalid is unexpected
/// ```
Expand Down
6 changes: 3 additions & 3 deletions tests/rustdoc-ui/doctest/comment-in-attr-134221-2.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
//@ compile-flags:--test --test-args --test-threads=1
//@ failure-status: 101
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout-test: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"

//! ```
#![doc = "#![all\
Expand Down
6 changes: 3 additions & 3 deletions tests/rustdoc-ui/doctest/comment-in-attr-134221.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@

//@ compile-flags:--test --test-args --test-threads=1
//@ failure-status: 101
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout-test: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: ".rs:\d+:\d+" -> ".rs:$$LINE:$$COL"

/*!
```rust
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/dead-code-2024.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

//@ edition: 2024
//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

#![doc(test(attr(allow(unused_variables), deny(warnings))))]
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/dead-code.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// This test ensures that the doctest will not use `#[allow(unused)]`.

//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

#![doc(test(attr(allow(unused_variables), deny(warnings))))]
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/display-output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
//@ check-pass
//@ edition:2018
//@ compile-flags:--test --test-args=--show-output
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

/// ```
/// #![warn(unused)]
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/doc-comment-multi-line-attr.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Regression test for #97440: Multiline inner attribute triggers ICE during doctest
//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ check-pass

//! ```rust
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/doc-comment-multi-line-cfg-attr.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ check-pass

/// ```
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/doc-test-doctest-feature.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//@ check-pass
//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

// Make sure `cfg(doctest)` is set when finding doctests but not inside
// the doctests.
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/doc-test-rustdoc-feature.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//@ check-pass
//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

#![feature(doc_cfg)]

Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/doctest-multiline-crate-attribute.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//@ compile-flags:--test --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ check-pass

/// ```
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/doctest-output-include-fail.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//@ edition:2024
//@ compile-flags:--test --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

// https://github.com/rust-lang/rust/issues/130470
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/doctest-output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
//@[edition2024]edition:2015
//@[edition2024]aux-build:extern_macros.rs
//@[edition2024]compile-flags:--test --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ check-pass

//! ```
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/failed-doctest-compile-fail.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
// adapted to use that, and that normalize line can go away

//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

/// ```compile_fail
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
// adapted to use that, and that normalize line can go away

//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

/// <https://github.com/rust-lang/rust/issues/91014>
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/failed-doctest-missing-codes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
// adapted to use that, and that normalize line can go away

//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

/// ```compile_fail,E0004
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/failed-doctest-output-windows.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

//@ compile-flags:--test --test-args --test-threads=1
//@ rustc-env:RUST_BACKTRACE=0
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

// doctest fails at runtime
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/failed-doctest-output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

//@ compile-flags:--test --test-args --test-threads=1
//@ rustc-env:RUST_BACKTRACE=0
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

// doctest fails at runtime
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/failed-doctest-should-panic-2021.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
// adapted to use that, and that normalize line can go away

//@ compile-flags:--test --edition 2021
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

/// ```should_panic
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/failed-doctest-should-panic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

//@ edition: 2024
//@ compile-flags:--test
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ failure-status: 101

/// ```should_panic
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/merged-ignore-no_run.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//@ edition: 2024
//@ compile-flags:--test --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ check-pass

/// ```ignore (test)
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/nested-main.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//@ check-pass
//@ compile-flags:--test --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

// Regression test for <https://github.com/rust-lang/rust/issues/131893>.
// It ensures that if a function called `main` is nested, it will not consider
Expand Down
4 changes: 2 additions & 2 deletions tests/rustdoc-ui/doctest/no-run-flag.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

//@ check-pass
//@ compile-flags:-Z unstable-options --test --no-run --test-args=--test-threads=1
//@ normalize-stdout-test: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout-test: "finished in \d+\.\d+s" -> "finished in $$TIME"
//@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
//@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"

/// ```
/// let a = true;
Expand Down
Loading
Loading