private void AddScenarioElement(IProject project, UnitTestElementConsumer consumer, StorEvilStoryElement storyElement, IScenario scenario) { if (scenario is Scenario) { consumer(new StorEvilScenarioElement(_provider, storyElement, project, scenario.Name, (Scenario)scenario)); } else { var outline = (ScenarioOutline)scenario; var outlineElement = new StorEvilScenarioOutlineElement(_provider, storyElement, project, scenario.Name, outline); consumer(outlineElement); var i = 0; foreach (var child in scenario.Preprocess()) { consumer(new StorEvilScenarioElement(_provider, outlineElement, project, BuildExampleRowScenarioName(outline, i), child)); i++; } } }
private UnitTestTask GetStoryTask(StorEvilStoryElement storyEl, IList<UnitTestElement> explicitElements) { return new UnitTestTask(storyEl, new RunStoryTask(storyEl.Id, explicitElements.Contains(storyEl))); }
private UnitTestTask GetStoryTask(StorEvilStoryElement storyEl, IList <UnitTestElement> explicitElements) { return(new UnitTestTask(storyEl, new RunStoryTask(storyEl.Id, explicitElements.Contains(storyEl)))); }