public void WithContext_accepting_instance_should_not_takeOwnership_by_default()
        {
            var step = _builder
                       .WithContext(new object())
                       .Build();

            Assert.That(step.SubStepsContext.TakeOwnership, Is.False);
        }
        public void It_should_allow_to_apply_context_instance()
        {
            var context   = new object();
            var stepGroup = _builder.WithContext(context).Build();
            var instance  = ResolveInstance(stepGroup);

            Assert.That(instance, Is.SameAs(context));
        }
Ejemplo n.º 3
0
        public void It_should_allow_to_apply_context_instance()
        {
            var context   = new object();
            var stepGroup = _builder.WithContext(context).Build();

            Assert.That(stepGroup.SubStepsContext.ContextProvider.Invoke(), Is.SameAs(context));
        }