Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions library/std/tests/sync/oneshot.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,15 @@ fn send_before_recv_timeout() {

assert!(sender.send(22i128).is_ok());

let start = Instant::now();

let timeout = Duration::from_secs(1);
match receiver.recv_timeout(timeout) {
Ok(22) => {}
_ => panic!("expected Ok(22)"),
}

assert!(start.elapsed() < timeout);
// FIXME(#152648): There previously was a timing assertion here.
// This was removed, because under load there's no guarantee that the main thread is
// scheduled and run before `timeout` expires
}

#[test]
Expand Down
Loading