Skip to content

Commit 93daf27

Browse files
committed
tests: ignore check_that_clippy_has_the_same_major_version_as_rustc() inside the rustc repo.
Do not check if clippy version matches rustc version when runnning tests inside the rustc repo. This makes sure that upstream rustc maintainers do not have to deal with our test failing/mismatching versions when the rustc version bump is happening. cc #6683
1 parent a507c27 commit 93daf27

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/versioncheck.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,12 @@ fn check_that_clippy_lints_has_the_same_version_as_clippy() {
2323

2424
#[test]
2525
fn check_that_clippy_has_the_same_major_version_as_rustc() {
26+
// do not run this test inside the upstream rustc repo:
27+
// https://github.com/rust-lang/rust-clippy/issues/6683
28+
if option_env!("RUSTC_TEST_SUITE").is_some() {
29+
return;
30+
}
31+
2632
let clippy_version = rustc_tools_util::get_version_info!();
2733
let clippy_major = clippy_version.major;
2834
let clippy_minor = clippy_version.minor;

0 commit comments

Comments
 (0)