use of org.jbehave.core.annotations.ScenarioType in project jbehave-core by jbehave.
the class StepsBehaviour method assertFailureReturnedOnStepsPerformed.
private void assertFailureReturnedOnStepsPerformed(Steps steps) {
ScenarioType scenarioType = ScenarioType.NORMAL;
List<BeforeOrAfterStep> beforeOrAfterStepList = steps.listBeforeOrAfterScenario(scenarioType);
StepResult stepResult = beforeOrAfterStepList.get(0).createStep().perform(null);
assertThat(stepResult, instanceOf(Failed.class));
assertThat(stepResult.getFailure(), instanceOf(UUIDExceptionWrapper.class));
assertThat(stepResult.getFailure().getCause(), instanceOf(BeforeOrAfterFailed.class));
}
Aggregations