Skip to main content

Module wait

Module wait 

Source
Expand description

Helpers for waiting on conditions of test nodes.

Structs§

PollOpts
Timeout and interval of a single poll_until_with call.

Constants§

POLL_INTERVAL
Interval at which poll_until polls, assert_holds_for checks and NodeTestContext::advance_while advances the chain.
WAIT_TIMEOUT
Maximum time the wait helpers wait for a condition, e.g. for a node to sync to or commit a block.

Functions§

assert_holds_for
Asserts that the condition checked by check holds for duration.
poll_until
Calls poll every POLL_INTERVAL until it returns a value.
poll_until_with
Calls poll until it returns a value, with the timeout and interval of opts.