| 323 | // Using WASMTIME_LOG, observe that this test calls poll() until the timer is ready. |
| 324 | #[test] |
| 325 | fn subscribe_some_duration() { |
| 326 | crate::runtime::block_on(async { |
| 327 | let reactor = Reactor::current(); |
| 328 | let pollable = wasip2::clocks::monotonic_clock::subscribe_duration(10_000_000); |
| 329 | let sched = reactor.schedule(pollable); |
| 330 | sched.wait_for().await; |
| 331 | }) |
| 332 | } |
| 333 | |
| 334 | // Using WASMTIME_LOG, observe that this test results in a single poll() on the second |
| 335 | // subscription, rather than spinning in poll() with first subscription, which is instantly |