public void use_a_different_strategy_that_catches()
        {
            var resolver = new TypeResolver();

            resolver.AddStrategy <ProxyDetector>();

            resolver.ResolveType(new InputModel()).ShouldEqual(typeof(InputModel));
            resolver.ResolveType(new Proxy <InputModel>()).ShouldEqual(typeof(InputModel));
        }
        public void SetUp()
        {
            graph = BehaviorGraph.BuildFrom(x =>
            {
                x.Actions.IncludeType <ChainResolverController>();
            });

            typeResolver = new TypeResolver();
            typeResolver.AddStrategy <ProxyDetector>();

            _resolutionCache = new ChainResolutionCache(typeResolver, graph);
        }
Example #3
0
        public void SetUp()
        {
            graph = new FubuRegistry(x =>
            {
                x.Actions.IncludeType <ChainResolverController>();
            }).BuildGraph();

            typeResolver = new TypeResolver();
            typeResolver.AddStrategy <ProxyDetector>();

            _resolutionCache = new ChainResolutionCache(typeResolver, graph);
        }
Example #4
0
        public void SetUp()
        {
            graph = new FubuRegistry(x =>
            {
                x.Actions.IncludeType <ChainResolverController>();
            }).BuildGraph();

            graph.Behaviors.Each(x => Debug.WriteLine(x.FirstCallDescription()));

            typeResolver = new TypeResolver();
            typeResolver.AddStrategy <ProxyDetector>();

            resolver = new ChainResolver(typeResolver, graph);
        }