@Test
public void testReadConfig() {

    JSONReader reader = null;
    try {
        reader = new JSONReader(new FileReader("src/test/resources/.metrics_scrape_config"));
        reader.startArray();
        List<ScrapeConfig> configs = new ArrayList<ScrapeConfig>();
        while(reader.hasNext()) {
            ScrapeConfig config = reader.readObject(ScrapeConfig.class);
            configs.add(config);
        }
        reader.endArray();
        reader.close();
        Assert.assertEquals(8006, configs.get(0).getPort());
        Assert.assertEquals(8007, configs.get(1).getPort());
    } catch (FileNotFoundException e) {
        Assert.fail("Error reading config file");
    }
}