reth_exex_test_utils

Trait PollOnce

Source
pub trait PollOnce {
    // Required method
    fn poll_once(
        &mut self,
    ) -> impl Future<Output = Result<(), PollOnceError>> + Send;
}
Expand description

An extension trait for polling an Execution Extension future.

Required Methods§

Source

fn poll_once( &mut self, ) -> impl Future<Output = Result<(), PollOnceError>> + Send

Polls the given Execution Extension future once. The future should be (pinned)std::pin::pin.

§Returns
  • Ok(()) if the future returned Poll::Pending. The future can be polled again.
  • Err(PollOnceError::FutureIsReady) if the future returned Poll::Ready without an error. The future should never resolve.
  • Err(PollOnceError::FutureError(err)) if the future returned Poll::Ready with an error. Something went wrong.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<F: Future<Output = Result<()>> + Unpin + Send> PollOnce for F