public class TestImageUtils extends NewCampaignTest {
@Test
public void testImage() {
ImageBean image = new ImageBean();
try {
image.setImage(new WebImage(
new URL(
"http://www.alteiar.net/wiki/lib/exe/fetch.php?cache=&media=applications:chat.jpg")));
BufferedImage target = ImageIO
.read(new URL(
"http://www.alteiar.net/wiki/lib/exe/fetch.php?cache=&media=applications:chat.jpg"));
compareImage(target, image.getImage().restoreImage());
assertEquals("get image must return null if no bean are found",
null, ImageBean.getImage(new UniqueID()));
} catch (MalformedURLException e) {
fail("problem with the url");