From 521d9371160e7055b2ee4a6ece6921091de3ba1c Mon Sep 17 00:00:00 2001 From: bjorn3 <17426603+bjorn3@users.noreply.github.com> Date: Mon, 17 Apr 2023 09:32:07 +0000 Subject: [PATCH] Pass --cap-lints=allow to tests --- build_system/tests.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build_system/tests.rs b/build_system/tests.rs index 0c25b4aadfa..3af74e1e97c 100644 --- a/build_system/tests.rs +++ b/build_system/tests.rs @@ -245,7 +245,7 @@ pub(crate) fn run_tests( let run_extended_sysroot = config::get_bool("testsuite.extended_sysroot"); if run_base_sysroot || run_extended_sysroot { - let target_compiler = build_sysroot::build_sysroot( + let mut target_compiler = build_sysroot::build_sysroot( dirs, channel, sysroot_kind, @@ -253,6 +253,9 @@ pub(crate) fn run_tests( bootstrap_host_compiler, target_triple.clone(), ); + // Rust's build system denies a couple of lints that trigger on several of the test + // projects. Changing the code to fix them is not worth it, so just silence all lints. + target_compiler.rustflags += " --cap-lints=allow"; let runner = TestRunner::new( dirs.clone(),