public virtual void Line(ILineExecution execution)
        {
            if (!_context.CanContinue())
            {
                return;
            }

            execution.Execute(_context);
        }
Ejemplo n.º 2
0
        public virtual void Line(ILineExecution execution)
        {
            if (!_context.CanContinue())
            {
                return;
            }

            // TODO -- shouldn't throw exceptions, but you know I'll slip up so try/catch here.
            execution.Execute(_context);
        }
Ejemplo n.º 3
0
        public void Composite(ICompositeExecution execution)
        {
            foreach (var executionStep in execution.Steps)
            {
                if (!_context.CanContinue())
                {
                    break;
                }

                executionStep.AcceptVisitor(this);
            }
        }
Ejemplo n.º 4
0
        public static void RunAll(SpecContext context, SpecificationPlan plan)
        {
            var gatherer = new LineStepGatherer(context);
            plan.AcceptVisitor(gatherer);

            foreach (var line in gatherer.Lines)
            {
                if (!context.CanContinue()) break;

                line.Execute(context);
            }
        }
        public static IEnumerable <PerfRecord> RunAll(SpecContext context, SpecificationPlan plan)
        {
            var gatherer = new LineStepGatherer(context);

            plan.AcceptVisitor(gatherer);

            context.Timings.Start(plan.Specification);

            foreach (var line in gatherer.Lines)
            {
                if (!context.CanContinue())
                {
                    break;
                }

                line.Execute(context);
            }

            return(context.FinalizeResults(1).Performance);
        }
Ejemplo n.º 6
0
 public void just_starting_with_default_options()
 {
     theContext.CanContinue().ShouldBe(true);
 }
 protected bool shouldStop(SpecContext context)
 {
     return(Request.IsCancelled || !context.CanContinue() || _timeout.IsCompleted);
 }
Ejemplo n.º 8
0
 protected bool shouldStop(SpecContext context)
 {
     return Request.IsCancelled || !context.CanContinue() || _timeout.IsCompleted;
 }