public ICondition WasDeleted() { return(new DelegatingCondition(() => { bool oldExists = fs.FileExists(folderName); if (oldExists) { return EvaluationResult.Error(FolderMessages.NotDeleted(folderName)); } return EvaluationResult.OK; })); }
public ICondition DeletedCreated() { return(new DelegatingCondition(() => { var results = new MultiEvaluationResult(); foreach (var name in names) { if (fileSystem.DirectoryExists(name)) { results.add(EvaluationResult.Error(FolderMessages.NotDeleted(name))); } } return results; })); }