compiletest: add ignore-hurd support and annotate some tests
authorDebian Rust Maintainers <pkg-rust-maintainers@alioth-lists.debian.net>
Thu, 13 Jun 2024 09:16:39 +0000 (11:16 +0200)
committerFabian Grünbichler <debian@fabian.gruenbichler.email>
Tue, 29 Oct 2024 12:18:35 +0000 (13:18 +0100)
These tests hang or make the box OOM

Forwarded: no

Signed-off-by: Fabian Grünbichler <git@fabian.gruenbichler.email>
Gbp-Pq: Topic upstream
Gbp-Pq: Name u-hurd-tests.patch

src/tools/compiletest/src/command-list.rs
src/tools/compiletest/src/header/tests.rs
tests/crashes/115994.rs
tests/run-make/long-linker-command-lines/foo.rs
tests/ui/associated-consts/issue-93775.rs
tests/ui/issues/issue-74564-if-expr-stack-overflow.rs
tests/ui/threads-sendsync/mpsc_stress.rs

index a559d6f81a240e4c4d5410e5adc11cbf8be6134f..1c2ff8787af173251a627faa57d8fbe2492c4b25 100644 (file)
@@ -54,6 +54,7 @@ const KNOWN_DIRECTIVE_NAMES: &[&str] = &[
     "ignore-gnu",
     "ignore-haiku",
     "ignore-horizon",
+    "ignore-hurd",
     "ignore-i686-pc-windows-gnu",
     "ignore-i686-pc-windows-msvc",
     "ignore-illumos",
index 29e11e77f1ce1ada734fe5602aa3d3b8a1a8b5e2..eeb54e98cb9fe2cd860f7d8ef6facf1a40e72ee1 100644 (file)
@@ -282,6 +282,7 @@ fn ignore_target() {
     assert!(check_ignore(&config, "//@ ignore-x86_64-unknown-linux-gnu"));
     assert!(check_ignore(&config, "//@ ignore-x86_64"));
     assert!(check_ignore(&config, "//@ ignore-linux"));
+    assert!(check_ignore(&config, "//@ ignore-hurd"));
     assert!(check_ignore(&config, "//@ ignore-unix"));
     assert!(check_ignore(&config, "//@ ignore-gnu"));
     assert!(check_ignore(&config, "//@ ignore-64bit"));
index 23d1507136f7ca62ff0d2a24fb9a63eb9bba8589..e0714e5b93e0e0c92b08447dd3fd26c1bd11ebda 100644 (file)
@@ -1,5 +1,6 @@
 //@ known-bug: #115994
 //@ compile-flags: -Cdebuginfo=2 --crate-type lib
+//@ ignore-hurd
 
 // To prevent "overflow while adding drop-check rules".
 use std::mem::ManuallyDrop;
index 5b30c06fac9e023b6955ac9e1f50ce5d8864d7b7..9ef0d5add4630649d72b10c76c8c60dfc05c2437 100644 (file)
@@ -33,6 +33,13 @@ fn read_linker_args(path: &Path) -> String {
     }
 }
 
+#[cfg(target_os = "hurd")]
+// Debian: test causes build to fail on hurd
+fn main() {
+    return;
+}
+
+#[cfg(not(target_os = "hurd"))]
 fn main() {
     let ok = PathBuf::from("ok");
     if env::var("YOU_ARE_A_LINKER").is_ok() {
index c9044e27e0e7f7692a65c662da042f0e7b329c92..5fb093d4fc6d59b753b2b9fe7e7e153dab7eb164 100644 (file)
@@ -1,5 +1,6 @@
 //@ build-pass
 // ignore-tidy-linelength
+//@ ignore-hurd
 
 // Regression for #93775, needs build-pass to test it.
 
index c0ffed27e6fb4687d6bd7b2e82f65f1ddc274ce3..1e97353af06285c98f83af34040e797bafb0776a 100644 (file)
@@ -1,5 +1,6 @@
 //@ build-pass
 // ignore-tidy-filelength
+//@ ignore-hurd
 #![crate_type = "rlib"]
 
 fn banana(v: &str) -> u32 {
index fe0b47f3a842e4b1b5da4f4445186320c5c8b67a..77ce6d5f0f1c31a9378a85232527fe8e7d3796d4 100644 (file)
@@ -1,6 +1,7 @@
 //@ run-pass
 //@ compile-flags:--test
 //@ needs-threads
+//@ ignore-hurd
 
 use std::sync::atomic::{AtomicUsize, Ordering};
 use std::sync::mpsc::{channel, RecvError, RecvTimeoutError, TryRecvError};