예제 #1
0
			public void Intercept(ICastleInvocation invocation)
			{
				if (invocation.Method.DeclaringType == typeof (IMocked)) {

				}

				this.mock.Invoke(new InvocationAdapter(invocation, this.mock));
			}
예제 #2
0
 internal InvocationAdapter(ICastleInvocation invocation, IMock mock)
 {
     this.invocation = invocation;
     this.mock = mock;
 }
예제 #3
0
 public void Intercept(ICastleInvocation invocation)
 {
     this.mock.Invoke(new InvocationAdapter(invocation, this.mock));
 }
예제 #4
0
 private IInvocation TranslateInvocation(Castle.DynamicProxy.IInvocation castleInvocation)
 {
     return(new Invocation(castleInvocation));
 }
예제 #5
0
            public void Intercept(Castle.DynamicProxy.IInvocation castleInvocation)
            {
                var invocation = TranslateInvocation(castleInvocation);

                _interceptor.Intercept(invocation);
            }
예제 #6
0
 internal Invocation(Castle.DynamicProxy.IInvocation underlying) : base(underlying.Proxy.GetType(), underlying.Method, underlying.Arguments)
 {
     this.underlying = underlying;
 }
예제 #7
0
 internal InvocationAdapter(CastleInvocation invocation, IProxied mock)
 {
     this.invocation = invocation;
     this.mock       = mock;
 }
 public void Intercept(Castle.DynamicProxy.IInvocation invocation)
 {
     this.underlying.Intercept(new Invocation(underlying: invocation));
 }