rust/library/std
Matthias Krüger bf17f139d3
Rollup merge of #142224 - joshtriplett:remove-gratuitous-wait-in-stress-test, r=workingjubilee
Avoid a gratuitous 10s wait in a stress test

`stress_recv_timeout_two_threads`, in the mpmc and mpsc testsuites, is a stress test of the `recv_timeout` function. This test processes and ignores timeouts, and just ensures that every sent value gets received. As such, the exact length of the timeouts is not critical, only that the timeout and sleep durations ensure that at least one timeout occurred.

The current tests have 100 iterations, half of which sleep for 200ms, causing the test to take 10s. This represents around 2/3rds of the *total* runtime of the `library/std` testsuite, and is the only standard library test that takes more than a second.

Reduce this to 50 iterations where half of them sleep for 10ms, causing the test to take 0.25s.

Add a check that at least one timeout occurred.
2025-06-09 10:20:54 +02:00
..
benches Fix import in bench for wasm 2025-02-12 14:44:30 -08:00
src Rollup merge of #142053 - heiher:loong32-none, r=wesleywiser 2025-06-08 17:17:53 -07:00
tests Avoid a gratuitous 10s wait in a stress test 2025-06-08 20:22:07 -07:00
build.rs Use feature(target_has_reliable_f16_f128) in library tests 2025-04-27 20:10:33 +00:00
Cargo.toml Add new Tier-3 targets: loongarch32-unknown-none* 2025-06-06 08:19:38 +08:00