@Test public void getTotalDurationTest() { List<Element> elements = new ArrayList<>(); Element element = new Element(); List<Step> steps = new ArrayList<>(); Step step = new Step(); Result result = new Result(); result.setDuration(10000000); step.setResult(result); steps.add(step); element.setSteps(steps); elements.add(element); report.setElements(elements); assertThat(report.getTotalDuration(), is(10000000L)); }
public long getTotalDuration() { long totalDurationNanoseconds = 0; for (Element element : elements) { totalDurationNanoseconds += element.getTotalDuration(); } return totalDurationNanoseconds; }
Report implements Cloneable { public long getTotalDuration() { long totalDurationNanoseconds = 0; for (Element element : elements) { totalDurationNanoseconds += element.getTotalDuration(); } return totalDurationNanoseconds; } }
Report implements Cloneable { public long getTotalDuration() { long totalDurationNanoseconds = 0; for (Element element : elements) { totalDurationNanoseconds += element.getTotalDuration(); } return totalDurationNanoseconds; }  }
Report implements Cloneable { public long getTotalDuration() { long totalDurationNanoseconds = 0; for (Element element : elements) { totalDurationNanoseconds += element.getTotalDuration(); } return totalDurationNanoseconds; }  int getLine(); void setLine(final int line); List<Element> getElements(); void setElements(final List<Element> elements); String getName(); void setName(final String name); String getDescription(); void setDescription(final String description); String getId(); void setId(final String id); String getKeyword(); void setKeyword(final String keyword); String getUri(); void setUri(final String uri); int getFeatureIndex(); void setFeatureIndex(final int featureIndex); List<Tag> getTags(); void setTags(final List<Tag> tags); long getTotalDuration(); @Override Object clone(); }
Report implements Cloneable { public long getTotalDuration() { long totalDurationNanoseconds = 0; for (Element element : elements) { totalDurationNanoseconds += element.getTotalDuration(); } return totalDurationNanoseconds; }  int getLine(); void setLine(final int line); List<Element> getElements(); void setElements(final List<Element> elements); String getName(); void setName(final String name); String getDescription(); void setDescription(final String description); String getId(); void setId(final String id); String getKeyword(); void setKeyword(final String keyword); String getUri(); void setUri(final String uri); int getFeatureIndex(); void setFeatureIndex(final int featureIndex); List<Tag> getTags(); void setTags(final List<Tag> tags); long getTotalDuration(); @Override Object clone();  }