Skip to content

Commit 21c5f78

Browse files
committed
Remove condvar::two_mutexes test.
We don't guarantee this panics. On most platforms it doesn't anymore.
1 parent 9299e69 commit 21c5f78

File tree

1 file changed

+0
-21
lines changed

1 file changed

+0
-21
lines changed

library/std/src/sync/condvar/tests.rs

-21
Original file line numberDiff line numberDiff line change
@@ -188,24 +188,3 @@ fn wait_timeout_wake() {
188188
break;
189189
}
190190
}
191-
192-
#[test]
193-
#[should_panic]
194-
#[cfg(all(unix, not(target_os = "linux"), not(target_os = "android")))]
195-
fn two_mutexes() {
196-
let m = Arc::new(Mutex::new(()));
197-
let m2 = m.clone();
198-
let c = Arc::new(Condvar::new());
199-
let c2 = c.clone();
200-
201-
let mut g = m.lock().unwrap();
202-
let _t = thread::spawn(move || {
203-
let _g = m2.lock().unwrap();
204-
c2.notify_one();
205-
});
206-
g = c.wait(g).unwrap();
207-
drop(g);
208-
209-
let m = Mutex::new(());
210-
let _ = c.wait(m.lock().unwrap()).unwrap();
211-
}

0 commit comments

Comments
 (0)