Skip to content

Commit e4b9d01

Browse files
committed
Auto merge of #142930 - cuviper:normalize-beta-versions, r=workingjubilee
Account for beta revisions when normalizing versions Several UI tests have a `normalize-stderr` for "you are using x.y.z" rustc versions, and that regex is flexible enough for suffixes like "-nightly" and "-dev", but not for "-beta.N". We can just add '.' to that trailing pattern to include this.
2 parents 99b18d6 + 8469966 commit e4b9d01

File tree

8 files changed

+8
-8
lines changed

8 files changed

+8
-8
lines changed

tests/ui/deprecation/deprecated_no_stack_check.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
1+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
22

33
#![deny(warnings)]
44
#![feature(no_stack_check)]

tests/ui/feature-gates/feature-gate-coverage-attribute.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
1+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
22

33
#![crate_type = "lib"]
44
#![feature(no_coverage)] //~ ERROR feature has been removed [E0557]

tests/ui/feature-gates/gated-bad-feature.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
1+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
22
#![feature(foo_bar_baz, foo(bar), foo = "baz", foo)]
33
//~^ ERROR malformed `feature`
44
//~| ERROR malformed `feature`

tests/ui/feature-gates/removed-features-note-version-and-pr-issue-141619.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
1+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
22

33
#![feature(external_doc)] //~ ERROR feature has been removed
44
#![doc(include("README.md"))] //~ ERROR unknown `doc` attribute `include`

tests/ui/macros/macro-reexport-removed.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//@ aux-build:two_macros.rs
2-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
2+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
33

44
#![feature(macro_reexport)] //~ ERROR feature has been removed
55

tests/ui/rustdoc/renamed-features-rustdoc_internals.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
1+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
22

33
#![feature(doc_keyword)] //~ ERROR
44
#![feature(doc_primitive)] //~ ERROR

tests/ui/traits/const-traits/const-trait-impl-parameter-mismatch.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// Regression test for issue #125877.
77

88
//@ compile-flags: -Znext-solver
9-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
9+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
1010

1111
#![feature(const_trait_impl, effects)]
1212
//~^ ERROR feature has been removed

tests/ui/unsized-locals/yote.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
1+
//@ normalize-stderr: "you are using [0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?( \([^)]*\))?" -> "you are using $$RUSTC_VERSION"
22

33
#![feature(unsized_locals)] //~ERROR feature has been removed
44
#![crate_type = "lib"]

0 commit comments

Comments
 (0)