return testCases;
}
private TestCase testCaseFrom(Node item) {
Element testCaseElement = (Element) item;
TestCase testCase = getBasicTestCaseFrom(testCaseElement);
Optional<TestException> failure = exceptionElementIn(testCaseElement).ofType("failure");
if (failure.isPresent()) {
testCase = testCase.withFailure(failure.get());
}
Optional<TestException> error = exceptionElementIn(testCaseElement).ofType("error");
if (error.isPresent()) {
testCase = testCase.withError(error.get());
}
String skipped = skippedTextIn(testCaseElement);
if (StringUtils.isNotEmpty(skipped)) {
testCase = testCase.wasSkipped(skipped);
}
return testCase;
}