about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/tools/clippy/tests/versioncheck.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/tools/clippy/tests/versioncheck.rs b/src/tools/clippy/tests/versioncheck.rs
index ea540d48a2b..f6fc2354ca0 100644
--- a/src/tools/clippy/tests/versioncheck.rs
+++ b/src/tools/clippy/tests/versioncheck.rs
@@ -93,6 +93,11 @@ fn check_that_clippy_has_the_same_major_version_as_rustc() {
 
 #[test]
 fn check_host_compiler() {
+    // do not run this test inside the upstream rustc repo:
+    if option_env!("RUSTC_TEST_SUITE").is_some() {
+        return;
+    }
+
     let version = rustc_tools_util::get_version_info!();
     assert_eq!(version.host_compiler, Some("nightly".to_string()));
 }