Пример #1
0
        public void SetUp()
        {
            inner = Wrapper.For<SimpleBehavior>();
            chain = new BehaviorChain();

            chain.AddToEnd(inner);

            theNode = new BehaviorTracerNode(inner);
        }
        public void creating_an_object_def_for_full_tracing_should_wrap_with_a_behavior_tracer()
        {
            var node = new Wrapper(typeof(SimpleBehavior));
            var objectDef = new BehaviorTracerNode(node).As<IContainerModel>().ToObjectDef();

            objectDef.Type.ShouldEqual(typeof(BehaviorTracer));
            objectDef.DependencyFor<IActionBehavior>().As<ConfiguredDependency>()
                .Definition.Type.ShouldEqual(typeof(SimpleBehavior));
        }