util: enable loom tests (#7644)

Co-authored-by: Benjamin Ran <[email protected]>
This commit is contained in:
Benjamin Ran
2025-11-06 19:20:08 +08:00
committed by GitHub
co-authored by Benjamin Ran
parent 0671c205cc
commit d84a9e9af3
12 changed files with 60 additions and 7 deletions
+3
View File
@@ -15,3 +15,6 @@ pub use poll_semaphore::PollSemaphore;
mod reusable_box;
pub use reusable_box::ReusableBoxFuture;
#[cfg(test)]
mod tests;
@@ -100,6 +100,9 @@ fn drop_token_no_child() {
});
}
// Temporarily disabled due to a false positive in loom -
// see https://github.com/tokio-rs/tokio/pull/7644#issuecomment-3328381344
#[ignore]
#[test]
fn drop_token_with_children() {
loom::model(|| {
@@ -125,6 +128,9 @@ fn drop_token_with_children() {
});
}
// Temporarily disabled due to a false positive in loom -
// see https://github.com/tokio-rs/tokio/pull/7644#issuecomment-3328381344
#[ignore]
#[test]
fn drop_and_cancel_token() {
loom::model(|| {
@@ -150,6 +156,9 @@ fn drop_and_cancel_token() {
});
}
// Temporarily disabled due to a false positive in loom -
// see https://github.com/tokio-rs/tokio/pull/7644#issuecomment-3328381344
#[ignore]
#[test]
fn cancel_parent_and_child() {
loom::model(|| {
+2 -1
View File
@@ -1 +1,2 @@
#[cfg(loom)]
mod loom_cancellation_token;