xmlgraphics-fop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sstei...@apache.org
Subject svn commit: r1737214 - /xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/pdf/PDFVTTestCase.java
Date Thu, 31 Mar 2016 10:34:24 GMT
Author: ssteiner
Date: Thu Mar 31 10:34:24 2016
New Revision: 1737214

URL: http://svn.apache.org/viewvc?rev=1737214&view=rev
Log:
Correct PDFVT Test

Modified:
    xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/pdf/PDFVTTestCase.java

Modified: xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/pdf/PDFVTTestCase.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/pdf/PDFVTTestCase.java?rev=1737214&r1=1737213&r2=1737214&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/pdf/PDFVTTestCase.java (original)
+++ xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/pdf/PDFVTTestCase.java Thu
Mar 31 10:34:24 2016
@@ -22,7 +22,6 @@ import java.awt.geom.Rectangle2D;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.File;
-import java.io.FileInputStream;
 import java.io.IOException;
 import java.io.InputStream;
 import java.util.Collection;
@@ -137,17 +136,14 @@ public class PDFVTTestCase {
 
         Fop fop = fopFactory.newFop(mimeFopIf, userAgent, out);
         Transformer transformer = TransformerFactory.newInstance().newTransformer();
-        // [TBD] FIXME - use getResource() to access FO file [GA]
-        Source src = new StreamSource(
-          new FileInputStream("../fop-core/src/test/resources/org/apache/fop/pdf/PDFVT.fo"));
+        Source src = new StreamSource(PDFVTTestCase.class.getResource("PDFVT.fo").openStream());
         Result res = new SAXResult(fop.getDefaultHandler());
         transformer.transform(src, res);
     }
 
     private FopFactory getFopFactory() throws IOException, SAXException {
-        // [TBD] FIXME - use getResource() to access conf file [GA]
         return FopFactory.newInstance(new File(".").toURI(),
-                new FileInputStream("../fop-core/src/test/resources/org/apache/fop/pdf/PDFVT.xconf"));
+                PDFVTTestCase.class.getResource("PDFVT.xconf").openStream());
     }
 
     private void iFToPDF(InputStream is) throws IOException, SAXException, TransformerException,
IFException {



---------------------------------------------------------------------
To unsubscribe, e-mail: fop-commits-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-commits-help@xmlgraphics.apache.org


Mime
View raw message