public bool Execute(ProcessRunnerArguments runnerArgs) { runnerArgs.Should().NotBeNull(); SuppliedArguments = runnerArgs; return(executeResult); }
public void Execute(ProcessRunnerArguments runnerArgs) { ExecuteCalled = true; runnerArgs.Should().NotBeNull(); // Expecting a single file name as input runnerArgs.CmdLineArgs.Count().Should().Be(1); using (var stream = new MemoryStream(responseToReturn)) using (var streamReader = new StreamReader(stream)) { runnerArgs.HandleOutputStream(streamReader); } }
public bool Execute(ProcessRunnerArguments runnerArgs) { ExecuteCalled = true; runnerArgs.Should().NotBeNull(); // Expecting a single file name as input runnerArgs.CmdLineArgs.Count().Should().Be(1); ExchangeFileName = runnerArgs.CmdLineArgs.First(); File.Exists(ExchangeFileName).Should().BeTrue(); // Replace the file with the response File.Delete(ExchangeFileName); WriteResponse(ExchangeFileName, responseToReturn); return(successCodeToReturn); }