File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
src/tools/miri/tests/pass/concurrency Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -203,7 +203,8 @@ fn park_timeout() {
203203 // know Miri's timed synchronization primitives do not do that.
204204 // We allow much longer sleeps as well since the macOS GHA runners seem very oversubscribed
205205 // and sometimes just pause for 1 second or more.
206- assert ! ( ( 200 ..2000 ) . contains( & start. elapsed( ) . as_millis( ) ) ) ;
206+ let elapsed = start. elapsed ( ) ;
207+ assert ! ( ( 200 ..2000 ) . contains( & elapsed. as_millis( ) ) , "bad sleep time: {:?}" , elapsed) ;
207208}
208209
209210fn park_unpark ( ) {
@@ -222,7 +223,8 @@ fn park_unpark() {
222223 // know Miri's timed synchronization primitives do not do that.
223224 // We allow much longer sleeps as well since the macOS GHA runners seem very oversubscribed
224225 // and sometimes just pause for 1 second or more.
225- assert ! ( ( 200 ..2000 ) . contains( & start. elapsed( ) . as_millis( ) ) ) ;
226+ let elapsed = start. elapsed ( ) ;
227+ assert ! ( ( 200 ..2000 ) . contains( & elapsed. as_millis( ) ) , "bad sleep time: {:?}" , elapsed) ;
226228
227229 t2. join ( ) . unwrap ( ) ;
228230}
You can’t perform that action at this time.
0 commit comments