/// <summary> /// Execute asynchronously with the command line arguments. Useful for testing Oakton applications /// </summary> /// <param name="commandLine"></param> /// <returns></returns> public Task <int> ExecuteAsync(string commandLine) { commandLine = applyOptions(commandLine); var run = _factory.BuildRun(commandLine); return(execute(run)); }
/// <summary> /// Execute with the command line arguments. Useful for testing Oakton applications /// </summary> /// <param name="commandLine"></param> /// <returns></returns> public int Execute(string commandLine) { commandLine = applyOptions(commandLine); return(execute(() => { var run = _factory.BuildRun(commandLine); return run.Execute(); })); }
public bool Execute(string commandLine) { var run = _factory.BuildRun(commandLine); return(run.Execute()); }