Esempio n. 1
0
 static void AssertExpectationScopeIsMet(IExpectationScope expectationScope)
 {
     if (!expectationScope.HasBeenMet)
     {
         throw new ExpectationsException(expectationScope, "All expectations has not been met, expected:");
     }
 }
        public MockInvocationInterceptor(IExpectationScope expectationScope)
        {
            if (expectationScope == null)
            {
                throw new ArgumentNullException("expectationScope");
            }

            this.expectationScope = expectationScope;
        }
Esempio n. 3
0
 static void AddExpectation(IExpectationScope expectationScope, IInvocationMatcher invocationMatcher, NumberOfInvocationsConstraint numberOfInvocationsConstraint)
 {
     expectationScope.Add(new Expectation(invocationMatcher, numberOfInvocationsConstraint), false);
 }
 internal ExpectationsException(IExpectationScope expectationScope, string format, params object[] args)
     : this(FormatMessage(expectationScope, format, args))
 {
 }