diff mbox series

rust: restore unit tests that were marked as ignored

Message ID 20250423112604.3718426-1-Deepesh.Varatharajan@windriver.com
State New
Headers show
Series rust: restore unit tests that were marked as ignored | expand

Commit Message

Deepesh Varatharajan April 23, 2025, 11:26 a.m. UTC
From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>

Some unit tests were previously marked as ignored due to failures
in earlier Rust versions. Following the upgrade to Rust 1.85.1,
these tests now pass reliably and have been re-enabled. They have
been verified to run successfully on the latest version.

Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
---
 .../rust/files/rust-oe-selftest.patch         | 93 -------------------
 1 file changed, 93 deletions(-)

Comments

Mathieu Dubois-Briand April 24, 2025, 10 a.m. UTC | #1
On Wed Apr 23, 2025 at 1:26 PM CEST, Deepesh via lists.openembedded.org Varatharajan wrote:
> From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>
> Some unit tests were previously marked as ignored due to failures
> in earlier Rust versions. Following the upgrade to Rust 1.85.1,
> these tests now pass reliably and have been re-enabled. They have
> been verified to run successfully on the latest version.
>
> Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> ---

Hi Deepesh,

Thanks for your patch.

I believe we can still see some test failures on the autobuilder:

2025-04-24 08:28:31,576 - oe-selftest - INFO - rust.RustSelfTestSystemEmulated.test_rust (subunit.RemotedTestCase)
2025-04-24 08:28:31,590 - oe-selftest - INFO -  ... FAIL
...
test fs::tests::file_lock_drop ... FAILED

https://autobuilder.yoctoproject.org/valkyrie/#/builders/42/builds/1422

Can you have a look at this issue please?

Best regards,
Mathieu
Deepesh Varatharajan April 29, 2025, 4:23 a.m. UTC | #2
Hi Mathew,

I attempted to reproduce this failure locally on two different servers 
using qemuarm as the machine,
but I was unable to replicate the issue. Additionally, I observed that 
the failing unit test had not been
previously ignored and it was not part of the unit tests I re-enabled 
for execution. Do you think I should
investigate with any additional configurations?

Regards,
Deepesh

On 24-04-2025 15:30, Mathieu Dubois-Briand wrote:
> CAUTION: This email comes from a non Wind River email account!
> Do not click links or open attachments unless you recognize the sender and know the content is safe.
>
> On Wed Apr 23, 2025 at 1:26 PM CEST, Deepesh via lists.openembedded.org Varatharajan wrote:
>> From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>>
>> Some unit tests were previously marked as ignored due to failures
>> in earlier Rust versions. Following the upgrade to Rust 1.85.1,
>> these tests now pass reliably and have been re-enabled. They have
>> been verified to run successfully on the latest version.
>>
>> Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>> ---
> Hi Deepesh,
>
> Thanks for your patch.
>
> I believe we can still see some test failures on the autobuilder:
>
> 2025-04-24 08:28:31,576 - oe-selftest - INFO - rust.RustSelfTestSystemEmulated.test_rust (subunit.RemotedTestCase)
> 2025-04-24 08:28:31,590 - oe-selftest - INFO -  ... FAIL
> ...
> test fs::tests::file_lock_drop ... FAILED
>
> https://autobuilder.yoctoproject.org/valkyrie/#/builders/42/builds/1422
>
> Can you have a look at this issue please?
>
> Best regards,
> Mathieu
>
> --
> Mathieu Dubois-Briand, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com
>
Mathieu Dubois-Briand April 29, 2025, 8:26 a.m. UTC | #3
On Tue Apr 29, 2025 at 6:23 AM CEST, Deepesh Varatharajan wrote:
> Hi Mathew,
>
> I attempted to reproduce this failure locally on two different servers 
> using qemuarm as the machine,
> but I was unable to replicate the issue. Additionally, I observed that 
> the failing unit test had not been
> previously ignored and it was not part of the unit tests I re-enabled 
> for execution. Do you think I should
> investigate with any additional configurations?
>

Hi Deepesh,

I was able to reproduce it locally with
https://web.git.yoctoproject.org/poky-ci-archive/tag/?h=autobuilder.yoctoproject.org/valkyrie/a-full-1453
and following commands

. oe-init-build-env
echo 'MACHINE = "qemuarm"' >> conf/local.conf
echo 'SANITY_TESTED_DISTROS = ""' >> conf/local.conf
oe-selftest -r rust.RustSelfTestSystemEmulated.test_rust
diff mbox series

Patch

diff --git a/meta/recipes-devtools/rust/files/rust-oe-selftest.patch b/meta/recipes-devtools/rust/files/rust-oe-selftest.patch
index 909bc971db..43a849dc8e 100644
--- a/meta/recipes-devtools/rust/files/rust-oe-selftest.patch
+++ b/meta/recipes-devtools/rust/files/rust-oe-selftest.patch
@@ -43,66 +43,6 @@  diff --git a/compiler/rustc_interface/src/tests.rs b/compiler/rustc_interface/sr
  fn test_can_print_warnings() {
      sess_and_cfg(&["-Awarnings"], |sess, _cfg| {
          assert!(!sess.dcx().can_emit_warnings());
-diff --git a/library/std/src/sync/poison/rwlock/tests.rs b/library/std/src/sync/poison/rwlock/tests.rs
-index 1a9d3d3f12f..0a9cfc48806 100644
---- a/library/std/src/sync/poison/rwlock/tests.rs
-+++ b/library/std/src/sync/poison/rwlock/tests.rs
-@@ -47,6 +47,7 @@ fn frob() {
- }
-
- #[test]
-+#[ignore]
- fn test_rw_arc_poison_wr() {
-     let arc = Arc::new(RwLock::new(1));
-     let arc2 = arc.clone();
-@@ -72,6 +73,7 @@ fn test_rw_arc_poison_mapped_w_r() {
- }
-
- #[test]
-+#[ignore]
- fn test_rw_arc_poison_ww() {
-     let arc = Arc::new(RwLock::new(1));
-     assert!(!arc.is_poisoned());
-@@ -100,6 +102,7 @@ fn test_rw_arc_poison_mapped_w_w() {
- }
-
- #[test]
-+#[ignore]
- fn test_rw_arc_no_poison_rr() {
-     let arc = Arc::new(RwLock::new(1));
-     let arc2 = arc.clone();
-@@ -127,6 +130,7 @@ fn test_rw_arc_no_poison_mapped_r_r() {
- }
-
- #[test]
-+#[ignore]
- fn test_rw_arc_no_poison_rw() {
-     let arc = Arc::new(RwLock::new(1));
-     let arc2 = arc.clone();
-@@ -192,6 +196,7 @@ fn test_rw_arc() {
- }
-
- #[test]
-+#[ignore]
- fn test_rw_arc_access_in_unwind() {
-     let arc = Arc::new(RwLock::new(1));
-     let arc2 = arc.clone();
-@@ -275,6 +280,7 @@ fn drop(&mut self) {
- }
-
- #[test]
-+#[ignore]
- fn test_into_inner_poison() {
-     let m = new_poisoned_rwlock(NonCopy(10));
-
-@@ -299,6 +305,7 @@ fn test_get_mut() {
- }
-
- #[test]
-+#[ignore]
- fn test_get_mut_poison() {
-     let mut m = new_poisoned_rwlock(NonCopy(10));
-
 diff --git a/library/std/src/thread/tests.rs b/library/std/src/thread/tests.rs
 index 5d6b9e94ee9..a5aacb2eb87 100644
 --- a/library/std/src/thread/tests.rs
@@ -147,39 +87,6 @@  index 5d6b9e94ee9..a5aacb2eb87 100644
  fn test_try_panic_any_message_unit_struct() {
      struct Juju;
 
-diff --git a/library/test/src/tests.rs b/library/test/src/tests.rs
---- a/library/test/src/tests.rs
-+++ b/library/test/src/tests.rs
-@@ -424,6 +424,7 @@
- }
-
- #[test]
-+#[ignore]
- fn test_time_options_threshold() {
-     let unit = TimeThreshold::new(Duration::from_millis(50), Duration::from_millis(100));
-     let integration = TimeThreshold::new(Duration::from_millis(500), Duration::from_millis(1000));
-diff --git a/library/std/src/sync/poison/mutex/tests.rs b/library/std/src/sync/poison/mutex/tests.rs
---- a/library/std/src/sync/poison/mutex/tests.rs
-+++ b/library/std/src/sync/poison/mutex/tests.rs
-@@ -193,6 +193,7 @@
- }
-
- #[test]
-+#[ignore]
- fn test_mutex_arc_poison_mapped() {
-     let arc = Arc::new(Mutex::new(1));
-     assert!(!arc.is_poisoned());
-diff --git a/library/std/src/sync/poison/mutex/tests.rs b/library/std/src/sync/poison/mutex/tests.rs
---- a/library/std/src/sync/poison/mutex/tests.rs
-+++ b/library/std/src/sync/poison/mutex/tests.rs
-@@ -272,6 +272,7 @@
- }
-
- #[test]
-+#[ignore]
- fn panic_while_mapping_unlocked_poison() {
-     let lock = Mutex::new(());
-
 diff --git a/library/std/src/sync/rwlock/tests.rs b/library/std/src/sync/poison/rwlock/tests.rs
 --- a/library/std/src/sync/poison/rwlock/tests.rs
 +++ b/library/std/src/sync/poison/rwlock/tests.rs