Exemplo n.º 1
0
        private TestResult GetResultFromScenario(CucumberObjects.Element cucumberScenario)
        {
            if (cucumberScenario == null) return TestResult.Inconclusive;

            bool wasSuccessful = CheckScenarioStatus(cucumberScenario);

            return wasSuccessful ? TestResult.Passed : TestResult.Failed;
        }
Exemplo n.º 2
0
        private TestResult GetResultFromFeature(CucumberObjects.Feature cucumberFeature)
        {
            if (cucumberFeature == null || cucumberFeature.elements == null) return TestResult.Inconclusive;

            bool wasSuccessful = cucumberFeature.elements.All(CheckScenarioStatus);

            return wasSuccessful ? TestResult.Passed : TestResult.Failed;
        }
Exemplo n.º 3
0
        private TestResult GetResultFromFeature(CucumberObjects.Feature cucumberFeature)
        {
            if (cucumberFeature == null) return new TestResult { WasExecuted = false, WasSuccessful = false };
            bool wasExecuted = true;
            bool wasSuccessful = cucumberFeature.elements.All(CheckScenarioStatus);

            return new TestResult { WasExecuted = wasExecuted, WasSuccessful = wasSuccessful };
        }
Exemplo n.º 4
0
        private TestResult GetResultFromScenario(CucumberObjects.Element cucumberScenario)
        {
            if (cucumberScenario == null) return new TestResult { WasExecuted = false, WasSuccessful = false };
            bool wasExecuted = true;
            bool wasSuccessful = CheckScenarioStatus(cucumberScenario);


            return new TestResult { WasExecuted = wasExecuted, WasSuccessful = wasSuccessful };
        }
Exemplo n.º 5
0
 private static bool CheckScenarioStatus(CucumberObjects.Element cucumberScenario)
 {
     return cucumberScenario.steps.All(x => x.result.status == "passed");
 }