diff options
author | Vincent Hennebert <vhennebert@apache.org> | 2007-02-14 14:24:36 +0000 |
---|---|---|
committer | Vincent Hennebert <vhennebert@apache.org> | 2007-02-14 14:24:36 +0000 |
commit | 404013f30e23b12ab477650846eb0e65b58a1394 (patch) | |
tree | 68d16c7870a4a6beb3ea5c07f02a4bf46c5f8610 /test/java/org/apache/fop/render | |
parent | dfb9bf9c3a9d1300d1575a9151580208f1ed994f (diff) | |
download | xmlgraphics-fop-404013f30e23b12ab477650846eb0e65b58a1394.tar.gz xmlgraphics-fop-404013f30e23b12ab477650846eb0e65b58a1394.zip |
Stricter user config file validation.
Add a configuration parameter (strict-configuration), enabled by default, which makes FOP throw an exception instead of logging an error when a problem occurs.
Invalid resource paths should be catched now. Fixes bug #40120.
Submitted by: Adrian Cumiskey (fop-dev AT cumiskey DOT com)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@507539 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'test/java/org/apache/fop/render')
-rw-r--r-- | test/java/org/apache/fop/render/pdf/BasePDFTestCase.java | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/test/java/org/apache/fop/render/pdf/BasePDFTestCase.java b/test/java/org/apache/fop/render/pdf/BasePDFTestCase.java index 54e2ba9d8..3e399e064 100644 --- a/test/java/org/apache/fop/render/pdf/BasePDFTestCase.java +++ b/test/java/org/apache/fop/render/pdf/BasePDFTestCase.java @@ -29,17 +29,16 @@ import javax.xml.transform.stream.StreamSource; import org.apache.commons.io.FileUtils; import org.apache.commons.io.output.ByteArrayOutputStream; +import org.apache.fop.AbstractFOPTestCase; import org.apache.fop.apps.FOUserAgent; import org.apache.fop.apps.Fop; import org.apache.fop.apps.FopFactory; import org.apache.fop.apps.MimeConstants; -import junit.framework.TestCase; - /** * Base class for automated tests that create PDF files */ -public class BasePDFTestCase extends TestCase { +public class BasePDFTestCase extends AbstractFOPTestCase { /** the FopFactory */ protected final FopFactory fopFactory = FopFactory.newInstance(); @@ -53,7 +52,13 @@ public class BasePDFTestCase extends TestCase { */ protected BasePDFTestCase(String name) { super(name); + init(); + } + /** + * initalizes the test + */ + protected void init() { final File uc = getUserConfigFile(); try { |