@Test
public void testMultiple() throws Exception {

    try (InputStream stream = GraphiteFormatParserTest.class.getResourceAsStream("/opentsdb-http-api-multiple.json")) {
        assertNotNull(stream);
        List<MetricTimeSeries> series = Lists.newArrayList(sut.parse(stream));
        // We should have two metrics
        assertThat(series.size(), is(2));
        MetricTimeSeries first = series.get(0);
        assertThat(first.getName(), is("sys.cpu.nice"));
        assertThat(first.getTimestamps().size(), is(2));
        assertThat(first.getValues().get(0), is(1.0));
        assertThat(first.getTimestamps().get(0), is(1346846400000L));
        assertThat(first.getValues().get(1), is(2.0));
        assertThat(first.getTimestamps().get(1), is(1346846400100L));
        MetricTimeSeries second = series.get(1);
        assertThat(second.getName(), is("sys.cpu.load"));
        assertThat(second.getTimestamps().size(), is(1));
        assertThat(second.getValues().get(0), is(2.0));
        assertThat(second.getTimestamps().get(0), is(1346846400000L));
    }
}