Test scenario result shows passed even when test step failed
I am currently writing some test scenario which contains few independent test steps. I am using Specflow in visual studio and as I would like to document the results I am using LivingDoc as well.
As the test steps are independent I would like the test scenario to continue when one of the steps fails. I understand the current behavior of specflow which skips all following test steps after failed step but my question is: Is there any way to override this behavior?
I have already tried assigning the test result for step like below which works for step but the scenario evaluates with result "passed".
ScenarioContext.Current.StepContext.Status = ScenarioExecutionStatus.TestError;
Can you help me with this one please? Is there any way I can manually evaluate test scenario result?
Please sign in to leave a comment.