//! Shared polling helpers for chain_index tests.
//!
//! Tests often need to wait for an async background task (sync, migration,
//! mempool refresh) to reach an observable state. Prefer `poll_until` over a
//! fixed `tokio::time::sleep(...)` so the test pays only the time actually
//! needed, with a bounded worst case.
use ;
use ;
/// Calls `cond` every `interval` until it returns `Some(T)` or the total time
/// spent reaches `budget`. Returns the value from the successful probe, or
/// panics with `what` in the message on timeout.
pub async