### Question:
XMLCoverageReport implements ICoverageReport { @Override public void create() throws IOException { try { DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); dbFactory.setFeature("http: DocumentBuilder dBuilder = null; dBuilder = dbFactory.newDocumentBuilder(); Document doc = dBuilder.parse(reportFile); NodeList nList = doc.getElementsByTagName("packages"); if(nList.getLength() == 1) { readPackages(nList.item(0)); System.out.println("OK"); } else { System.err.println("Error in xml report coverage format"); } } catch (ParserConfigurationException e) { e.printStackTrace(); } catch (SAXException e) { e.printStackTrace(); } } XMLCoverageReport(File reportFile); @Override void create(); @Override double codeFragmentCoverage(CodeFragment stmt); @Override int opCodeCoverage(CtMethod method, int indexOpcode); @Override double elementCoverage(CtElement operator); @Override List<Integer> getCoverageDistribution(CodeFragment stmt); @Override double positionCoverage(SourcePosition position);  }### Answer:
@Test public void testCreation() throws IOException { File coverageFile = new File(XMLCoverageReportTest.class.getClassLoader().getResource("coverage.xml").getFile()); assertTrue(coverageFile.exists() && coverageFile.isFile()); XMLCoverageReport report = new XMLCoverageReport(coverageFile); report.create(); assertTrue(report.report.size() != 0); }