pub struct MockWorker { /* private fields */ }Expand description
A worker that replays a MockScript.
Implementations§
Source§impl MockWorker
impl MockWorker
Trait Implementations§
Source§impl Worker for MockWorker
impl Worker for MockWorker
Source§fn descriptor(&self) -> &WorkerDescriptor
fn descriptor(&self) -> &WorkerDescriptor
The worker’s self-description, used by the scheduler to resolve a node’s
capability
needs to a concrete worker.Source§fn execute<'life0, 'async_trait>(
&'life0 self,
_request: ExecuteRequest,
events: EventSink,
cancel: CancellationToken,
) -> Pin<Box<dyn Future<Output = Result<ExecuteResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute<'life0, 'async_trait>(
&'life0 self,
_request: ExecuteRequest,
events: EventSink,
cancel: CancellationToken,
) -> Pin<Box<dyn Future<Output = Result<ExecuteResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Do one unit of work. Returns the normalized result, or an error if the
worker could not be driven at all (distinct from a worker that ran and
reported
ExecStatus::Failed).Auto Trait Implementations§
impl Freeze for MockWorker
impl RefUnwindSafe for MockWorker
impl Send for MockWorker
impl Sync for MockWorker
impl Unpin for MockWorker
impl UnsafeUnpin for MockWorker
impl UnwindSafe for MockWorker
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more