public void testShouldNotBuildBufferWhenTransparencyChanges() throws Exception {
    SimpleCache<limelight.ui.Panel, BufferedImage> cache =
        new SimpleCache<limelight.ui.Panel, BufferedImage>();
    Context.instance().bufferedImageCache = cache;
    cache.cache(panel, new BufferedImage(1, 1, BufferedImage.TYPE_INT_ARGB));

    panel.styleChanged(Style.TRANSPARENCY, new SimplePercentageAttribute(20));
    assertNotNull(cache.retrieve(panel));
  }
  public void testShouldBuildBufferWhenStyleChanges() throws Exception {
    SimpleCache<limelight.ui.Panel, BufferedImage> cache =
        new SimpleCache<limelight.ui.Panel, BufferedImage>();
    Context.instance().bufferedImageCache = cache;
    cache.cache(panel, new BufferedImage(1, 1, BufferedImage.TYPE_INT_ARGB));

    panel.styleChanged(Style.WIDTH, new StaticDimensionAttribute(20));
    assertEquals(null, cache.retrieve(panel));
  }