pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1619876 - /pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/graphics/image/ValidateXImage.java
Date Fri, 22 Aug 2014 17:53:15 GMT
Author: tilman
Date: Fri Aug 22 17:53:14 2014
New Revision: 1619876

URL: http://svn.apache.org/r1619876
Log:
PDFBOX-2275: add a test that the resource map is filled at PDF creation time

Modified:
    pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/graphics/image/ValidateXImage.java

Modified: pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/graphics/image/ValidateXImage.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/graphics/image/ValidateXImage.java?rev=1619876&r1=1619875&r2=1619876&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/graphics/image/ValidateXImage.java
(original)
+++ pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/graphics/image/ValidateXImage.java
Fri Aug 22 17:53:14 2014
@@ -99,11 +99,15 @@ public class ValidateXImage
         contentStream.drawXObject(ximage, 150, 300, width, height);
         contentStream.drawXObject(ximage, 200, 350, width, height);
         contentStream.close();
+        
+        // check that the resource map is up-to-date
+        assertEquals(1, document.getPage(0).getResources().getXObjects().size());
 
         document.save(pdfFile);
         document.close();
 
         document = PDDocument.loadNonSeq(pdfFile, null);
+        assertEquals(1, document.getPage(0).getResources().getXObjects().size());
         new PDFRenderer(document).renderImage(0);
         document.close();
     }



Mime
View raw message