@Test
public void testFetch() throws IOException {

    Fongo fongo = new Fongo("Mongo DB");
    Discoverer d = new Discoverer(fongo.getMongo());
    ArrayList<String> offerings = new ArrayList<String>();
    offerings.add("EC2");
    offerings.add("Azure");
    offerings.add("Openshift");
    for (String name: offerings) {
        d.addOffering(new Offering(name));
    }
    ArrayList<String> offeringIds = (new DiscovererAPI(d)).getOfferingIds();
    Assert.assertEquals(offeringIds.size(), offerings.size());
    for (String id: offeringIds) {
        Assert.assertTrue(offerings.contains(id));
    }
}