public void DetermineInvoker_for_synchronous_actions()
        {
            var chain = BehaviorChain.For <Action2>(x => x.M1());

            chain.IsAsynchronous().ShouldBeFalse();

            StandardRoutePolicy.DetermineInvoker(theFactory, chain).ShouldBeOfType <BehaviorInvoker>();
        }
        public void DetermineHandlerSource_for_async_and_requires_session()
        {
            var chain = BehaviorChain.For <Action3>(x => x.M1Async());

            chain.IsAsynchronous().ShouldBeTrue();

            StandardRoutePolicy.DetermineHandlerSource(SessionStateRequirement.RequiresSessionState, chain)
            .ShouldBeOfType <AsynchronousHttpHandlerSource>();
        }
        public void DetermineHandlerSource_for_synchronous_with_session()
        {
            var chain = BehaviorChain.For <Action2>(x => x.M1());

            chain.IsAsynchronous().ShouldBeFalse();

            StandardRoutePolicy.DetermineHandlerSource(SessionStateRequirement.RequiresSessionState, chain)
            .ShouldBeOfType <SynchronousHttpHandlerSource>();
        }