@Test
public void testGetInstance() {
for (String zone : api.getConfiguredZones()) {
InstanceApi instanceApi = api.getInstanceApiForZone(zone);
for (Instance instance : instanceApi.list()) {
Instance instanceFromGet = instanceApi.get(instance.getId());
assertNotNull(instanceFromGet.getHostname());
assertNull(instance.getHostname());
assertEquals(instanceFromGet.getId(), instance.getId());
assertEquals(instanceFromGet.getName(), instance.getName());
assertEquals(instanceFromGet.getStatus(), instance.getStatus());
assertEquals(instanceFromGet.getFlavor(), instance.getFlavor());
assertEquals(instanceFromGet.getSize(), instance.getSize());
assertEquals(instanceFromGet.getLinks(), instance.getLinks());
}
}
}