C# Class NUnit.Framework.Internal.Execution.SimpleWorkItemDispatcher

SimpleWorkItemDispatcher handles execution of WorkItems by directly executing them. It is provided so that a dispatcher is always available in the context, thereby simplifying the code needed to run child tests.
Inheritance: IWorkItemDispatcher
Mostrar archivo Open project: nunit/nunit

Public Methods

Method Description
CancelRun ( bool force ) : void

Cancel (abort or stop) the ongoing run. If no run is in process, the call has no effect.

Dispatch ( WorkItem work ) : void

Dispatch a single work item for execution. The first work item dispatched is saved as the top-level work item and a thread is created on which to run it. Subsequent calls come from the top level item or its descendants on the proper thread.

Private Methods

Method Description
RunnerThreadProc ( ) : void

Method Details

CancelRun() public method

Cancel (abort or stop) the ongoing run. If no run is in process, the call has no effect.
public CancelRun ( bool force ) : void
force bool true if the run should be aborted, false if it should allow its currently running test to complete
return void

Dispatch() public method

Dispatch a single work item for execution. The first work item dispatched is saved as the top-level work item and a thread is created on which to run it. Subsequent calls come from the top level item or its descendants on the proper thread.
public Dispatch ( WorkItem work ) : void
work WorkItem The item to dispatch
return void