disable ImageIO cache - probably need to set it in every test class or disable it in the beginning of all tests

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1830520 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Andreas Beeker 2018-04-29 21:12:06 +00:00
parent e0f7014503
commit 34c9cffe5d

View File

@ -47,6 +47,7 @@ import org.apache.poi.sl.draw.DrawFactory;
import org.apache.poi.sl.usermodel.PictureData.PictureType;
import org.apache.poi.sl.usermodel.Slide;
import org.apache.poi.sl.usermodel.SlideShow;
import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.Test;
@ -58,6 +59,11 @@ import org.junit.Test;
public final class TestPicture {
private static POIDataSamples _slTests = POIDataSamples.getSlideShowInstance();
@BeforeClass
public static void disableImageIOCache() {
ImageIO.setUseCache(false);
}
/**
* Test that the reference count of a blip is incremented every time the picture is inserted.
* This is important when the same image appears multiple times in a slide show.