public DispatchConfiguredMatchingCallBenchmark() { _interfaceProxy = Substitute.For <IInterfaceWithSingleMethod>(); _interfaceProxy.IntMethod("42").Returns(42); _interfaceProxy.When(x => x.VoidMethod("42")).Do(delegate { }); _abstractClassProxy = Substitute.For <AbstractClassWithSingleMethod>(); _abstractClassProxy.IntMethod("42").Returns(42); _abstractClassProxy.When(x => x.VoidMethod("42")).Do(delegate { }); _classPartialProxy = Substitute.For <ClassWithSingleMethod>(); _classPartialProxy.IntMethod("42").Returns(42); _classPartialProxy.When(x => x.VoidMethod("42")).Do(delegate { }); _intDelegateProxy = Substitute.For <IntDelegate>(); _intDelegateProxy.Invoke("42").Returns(42); _voidDelegateProxy = Substitute.For <VoidDelegate>(); _voidDelegateProxy.When(x => x.Invoke("42")).Do(delegate { }); }