/// <summary> /// Performs the currently built action. /// </summary> public async Task Perform(CancellationToken cancellationToken = default(CancellationToken)) { IActionExecutor actionExecutor = this.driver as IActionExecutor; if (await actionExecutor.IsActionExecutor(cancellationToken).ConfigureAwait(false)) { await actionExecutor.PerformActions(this.actionBuilder.ToActionSequenceList()).ConfigureAwait(false); } else { await action.Perform().ConfigureAwait(false); } }
public void Perform() { IActionExecutor actionExecutor = this.driver as IActionExecutor; if (actionExecutor.IsActionExecutor) { actionExecutor.PerformActions(this.actionBuilder.ToActionSequenceList()); } else { this.action.Perform(); } }