diff mbox series

[meta-lts-mixins,kirkstone/rust,5/9] rust: Add patch to increase timeout in process-sigpipe rust selftest

Message ID 20241126181152.407253-6-scott.murray@konsulko.com
State New
Headers show
Series Upgrade to Rust 1.80.1 | expand

Commit Message

Scott Murray Nov. 26, 2024, 6:11 p.m. UTC
From: Peter Tatrai <peter.tatrai.ext@siemens.com>

This commit adds a patch to increase the timeout in the process-sigpipe
rust selftest to prevent occasional failures under heavy server load.
The patch aims to reduce the likelihood of false negatives when the test
environment is overloaded.

Patch file:
* oeqa-selftest-Increase-timeout-in-process-sigpipe-ru.patch

Fixes [YOCTO #15625]

Signed-off-by: Peter Tatrai <peter.tatrai.ext@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(adapted from oe-core commit 12c85933e2150ba78a8a914787e400c95c5cf585)
Signed-off-by: Scott Murray <scott.murray@konsulko.com>
---
 ...crease-timeout-in-process-sigpipe-ru.patch | 31 +++++++++++++++++++
 recipes-devtools/rust/rust-source.inc         |  1 +
 2 files changed, 32 insertions(+)
 create mode 100644 recipes-devtools/rust/files/oeqa-selftest-Increase-timeout-in-process-sigpipe-ru.patch
diff mbox series

Patch

diff --git a/recipes-devtools/rust/files/oeqa-selftest-Increase-timeout-in-process-sigpipe-ru.patch b/recipes-devtools/rust/files/oeqa-selftest-Increase-timeout-in-process-sigpipe-ru.patch
new file mode 100644
index 0000000..b42dda8
--- /dev/null
+++ b/recipes-devtools/rust/files/oeqa-selftest-Increase-timeout-in-process-sigpipe-ru.patch
@@ -0,0 +1,31 @@ 
+From b4524278985f517b0785b6f64a21380dcf1ff096 Mon Sep 17 00:00:00 2001
+From: Peter Tatrai <peter.tatrai.ext@siemens.com>
+Date: Mon, 4 Nov 2024 13:58:16 +0100
+Subject: [PATCH] oeqa/selftest: Increase timeout in process-sigpipe rust test
+
+This patch increases the timeout for the process-sigpipe rust test, which
+occasionally fails when the server is under heavy load. Increasing the timeout
+reduces the likelihood of false negatives under load.
+
+Fixes [YOCTO #15625]
+
+Upstream-Status: Inappropriate [OE testing specific]
+
+Signed-off-by: Peter Tatrai <peter.tatrai.ext@siemens.com>
+---
+ tests/ui/process/process-sigpipe.rs | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/tests/ui/process/process-sigpipe.rs b/tests/ui/process/process-sigpipe.rs
+index 11f363d62..c12d66016 100644
+--- a/tests/ui/process/process-sigpipe.rs
++++ b/tests/ui/process/process-sigpipe.rs
+@@ -23,7 +23,7 @@ use std::thread;
+ fn main() {
+     // Just in case `yes` doesn't check for EPIPE...
+     thread::spawn(|| {
+-        thread::sleep_ms(5000);
++        thread::sleep_ms(10000);
+         process::exit(1);
+     });
+     let output = process::Command::new("sh")
diff --git a/recipes-devtools/rust/rust-source.inc b/recipes-devtools/rust/rust-source.inc
index 929a4a9..f0681c8 100644
--- a/recipes-devtools/rust/rust-source.inc
+++ b/recipes-devtools/rust/rust-source.inc
@@ -9,6 +9,7 @@  SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n
             file://rustdoc-repro-issue-fix-cargo-config-for-codegenunits.patch;patchdir=${RUSTSRC} \
             file://rust-oe-selftest.patch;patchdir=${RUSTSRC} \
             file://repro-issue-fix-with-cc-crate-hashmap.patch;patchdir=${RUSTSRC} \
+            file://oeqa-selftest-Increase-timeout-in-process-sigpipe-ru.patch;patchdir=${RUSTSRC} \
 "
 SRC_URI[rust.sha256sum] = "ab826e84b8d48ec6eda3370065034dea8c006f6a946d78a9ba12bcb50e6d3c7a"