From: Andreas Beeker Date: Sun, 29 Apr 2018 21:12:06 +0000 (+0000) Subject: disable ImageIO cache - probably need to set it in every test class or disable it... X-Git-Tag: REL_4_0_0_FINAL~183 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=51f5eaf5e567223993ce34fc0425e33073a5b459;p=poi.git 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 --- diff --git a/src/scratchpad/testcases/org/apache/poi/hslf/usermodel/TestPicture.java b/src/scratchpad/testcases/org/apache/poi/hslf/usermodel/TestPicture.java index 7a7a7b452d..72eee287c2 100644 --- a/src/scratchpad/testcases/org/apache/poi/hslf/usermodel/TestPicture.java +++ b/src/scratchpad/testcases/org/apache/poi/hslf/usermodel/TestPicture.java @@ -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.