Ejemplo n.º 1
0
        public void SetResult_is_noop_when_not_implemented()
        {
            var handler = new Mock<HandlerBase>();
            var wrappedHandler = new WrappedHandler(handler.Object);

            wrappedHandler.SetResult("Value1");
        }
        public void SetResult_is_noop_when_not_implemented()
        {
            var handler        = new Mock <HandlerBase>();
            var wrappedHandler = new WrappedHandler(handler.Object);

            wrappedHandler.SetResult("Value1");
        }
Ejemplo n.º 3
0
        public void SetResult_invokes_when_implemented()
        {
            var handler = new Mock<HandlerBase>().As<IResultHandler>();
            var wrappedHandler = new WrappedHandler(handler.Object);

            wrappedHandler.SetResult("Value1");

            handler.Verify(h => h.SetResult("Value1"));
        }
        public void SetResult_invokes_when_implemented()
        {
            var handler        = new Mock <HandlerBase>().As <IResultHandler>();
            var wrappedHandler = new WrappedHandler(handler.Object);

            wrappedHandler.SetResult("Value1");

            handler.Verify(h => h.SetResult("Value1"));
        }
Ejemplo n.º 5
0
            public GetProviderServices(
                Executor executor,
                object handler,
                string invariantName,
                IDictionary <string, object> anonymousArguments)
            {
                Check.NotNull(executor, "executor");
                Check.NotNull(handler, "handler");
                Check.NotEmpty(invariantName, "invariantName");

                var wrappedHandler = new WrappedHandler(handler);

                var providerServicesTypeName = executor.GetProviderServicesInternal(invariantName);

                wrappedHandler.SetResult(providerServicesTypeName);
            }