### Question:
ReportAnalyzer { @SuppressWarnings("unchecked") public List<MetricsResource> getMetricsResources(Map<String, Object> report) { List<MetricsResource> metricsResources = new ArrayList<MetricsResource>(); if (report == null) { return metricsResources; } Map<String, Object> metrics = (Map<String, Object>) report.get("metrics"); if (metrics == null) { return metricsResources; } Map<String, Object> resources = (Map<String, Object>) metrics.get("resources"); if (resources == null) { return metricsResources; } List<List<Object>> values = (List<List<Object>>) resources.get("values"); if (values == null) { return metricsResources; } for (List<Object> value : values) { String name = value.get(1).toString(); int count = Integer.parseInt(value.get(2).toString()); MetricsResource metricsResource = new MetricsResource(); metricsResource.setName(name); metricsResource.setCount(count); metricsResources.add(metricsResource); } return metricsResources; }  @SuppressWarnings("unchecked") List<MetricsResource> getMetricsResources(Map<String, Object> report); @SuppressWarnings("unchecked") List<MetricsTime> getMetricsTimes(Map<String, Object> report); @SuppressWarnings("unchecked") List<MetricsChange> getMetricsChanges(Map<String, Object> report); String getStatus(Map<String, Object> report);  }### Answer:
@Test @Ignore public void testGetMetricsResources() { Map<String, Object> report = reportLoader.loadReport("test", "test.yaml"); List<MetricsResource> metricsResources = reportAnalyzer.getMetricsResources(report); for (MetricsResource metricsResource : metricsResources) { log.trace(ReflectionToStringBuilder.toString(metricsResource, ToStringStyle.SHORT_PREFIX_STYLE)); } assertEquals(8, metricsResources.size()); }