private void readUserStory(final HierarchicalStreamReader reader, final TestOutcome testOutcome) { String storyId = reader.getAttribute(ID_FIELD); String storyName = reader.getAttribute(NAME_FIELD); String storyPath = reader.getAttribute(PATH_FIELD); ApplicationFeature feature = null; if (reader.hasMoreChildren()) { reader.moveDown(); String childNode = reader.getNodeName(); if (childNode.equals(FEATURE)) { feature = readFeature(reader); } reader.moveUp(); } Story story; if (feature == null) { story = Story.withIdAndPath(storyId, storyName,storyPath); } else { story = Story.withIdAndPathAndFeature(storyId, storyName, storyPath, feature.getId(), feature.getName()); } testOutcome.setUserStory(story); }
private void readUserStory(final HierarchicalStreamReader reader, final TestOutcome testOutcome) { String storyId = reader.getAttribute(ID_FIELD); String storyName = reader.getAttribute(NAME_FIELD); String storyPath = reader.getAttribute(PATH_FIELD); ApplicationFeature feature = null; if (reader.hasMoreChildren()) { reader.moveDown(); String childNode = reader.getNodeName(); if (childNode.equals(FEATURE)) { feature = readFeature(reader); } reader.moveUp(); } Story story; if (feature == null) { story = Story.withIdAndPath(storyId, storyName,storyPath); } else { story = Story.withIdAndPathAndFeature(storyId, storyName, storyPath, feature.getId(), feature.getName()); } testOutcome.setUserStory(story); }
private void readUserStory(final HierarchicalStreamReader reader, final TestOutcome testOutcome) { String storyId = reader.getAttribute(ID_FIELD); String storyName = reader.getAttribute(NAME_FIELD); String storyPath = reader.getAttribute(PATH_FIELD); ApplicationFeature feature = null; if (reader.hasMoreChildren()) { reader.moveDown(); String childNode = reader.getNodeName(); if (childNode.equals(FEATURE)) { feature = readFeature(reader); } reader.moveUp(); } Story story; if (feature == null) { story = Story.withIdAndPath(storyId, storyName,storyPath); } else { story = Story.withIdAndPathAndFeature(storyId, storyName, storyPath, feature.getId(), feature.getName()); } testOutcome.setUserStory(story); }