예제 #1
0
 public ICondition WasDeleted()
 {
     return(new DelegatingCondition(() => {
         bool oldExists = fs.FileExists(fileName);
         if (oldExists)
         {
             return EvaluationResult.Error(FileMessages.NotDeleted(fileName));
         }
         return EvaluationResult.OK;
     }));
 }
예제 #2
0
 public ICondition DeletedCreated()
 {
     return(new DelegatingCondition(() => {
         var results = new MultiEvaluationResult();
         foreach (var name in names)
         {
             if (fileSystem.FileExists(name))
             {
                 results.add(EvaluationResult.Error(FileMessages.NotDeleted(name)));
             }
         }
         return results;
     }));
 }