protected void AndThenShouldBeAbleToRepeatProcessingFromConfiguration() { var config = FlowConfiguration.Load($@"{_flowConfig.BasePath}\flow-config.yaml"); var controller = _container.Resolve <FlowController>(); // clear prior results Directory.Delete(_flowConfig.BasePath, true); // re-create csv AndGivenAGeneratedDataSourceCsvFile(); // start controller.Start(config); // wait for jobs to finish processing var sw = new Stopwatch(); sw.Start(); // spin wait while (controller.Processed <= 2 && sw.Elapsed.TotalSeconds < 15) { Thread.Sleep(TimeSpan.FromSeconds(1)); } // resave _flowConfig.Save(); }