示例#1
0
 public void SetResultForLastCall(IReturn valueToReturn, MatchArgs matchArgs)
 {
     if (_pendingSpecification.HasPendingCallSpec())
     {
         SetResultForCall(_pendingSpecification.UseCallSpec(), valueToReturn, matchArgs);
     }
     else
     {
         var lastCall = _callStack.Pop();
         SetResultForCall(lastCall, valueToReturn, matchArgs);
     }
 }
 public ICallSpecification FromLastCall(MatchArgs matchArgs)
 {
     return(_pendingSpecification.HasPendingCallSpec()
                        ? FromExistingSpec(_pendingSpecification.UseCallSpec(), matchArgs)
                        : FromCall(_callStack.Pop(), matchArgs));
 }