Example #1
0
File: Shim.cs Project: jonkeda/pose
 private Shim WithImpl(Delegate replacement)
 {
     ShimHelper.ValidateReplacementMethodSignature(this._original, replacement.Method, _instance?.GetType() ?? _type, _setter);
     _replacement = new ShimDelegate(replacement);
     return(this);
 }
Example #2
0
File: Shim.cs Project: jonkeda/pose
 private Shim(MethodBase original, object instanceOrType, object target, MethodInfo mockMethod) : this(original, instanceOrType)
 {
     _replacement = new ShimDelegate(target, mockMethod);
 }