示例#1
0
        /// <summary>
        /// Executes a scenario passing the given context to each step.
        /// </summary>
        public static Outcome <T> Execute <T>(this Scenario scenario, T context, IStepResolver resolver)
            where T : class
        {
            scenario.Pickle.Steps
            .Iterate(step => TryResolve(scenario.Pickle, step, resolver, context))
            .EvaluateAndIgnore();

            return(Outcome.Create(context, scenario));
        }