Exemple #1
0
        private void Verify(IMethod method)
        {
            var parameters = (from pi in method.Parameters
                              select this.Builder.CreateAnonymous(GuardClauseAssertion.GetParameterType(pi))).ToList();

            var i = 0;

            foreach (var pi in method.Parameters)
            {
                var expansion = new IndexedReplacement <object>(i++, parameters);

                var command   = new MethodInvokeCommand(method, expansion, pi);
                var unwrapper = new ReflectionExceptionUnwrappingCommand(command);
                this.BehaviorExpectation.Verify(unwrapper);
            }
        }