You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by ti...@apache.org on 2023/03/18 04:39:12 UTC
svn commit: r1908467 - in /pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration: TestInvalidFiles.java TestIsartorValidation.java TestValidFiles.java
Author: tilman
Date: Sat Mar 18 04:39:12 2023
New Revision: 1908467
URL: http://svn.apache.org/viewvc?rev=1908467&view=rev
Log:
PDFBOX-5572: fix some logging inconsistencies, by Axel Howind
Modified:
pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestInvalidFiles.java
pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestIsartorValidation.java
pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestValidFiles.java
Modified: pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestInvalidFiles.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestInvalidFiles.java?rev=1908467&r1=1908466&r2=1908467&view=diff
==============================================================================
--- pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestInvalidFiles.java (original)
+++ pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestInvalidFiles.java Sat Mar 18 04:39:12 2023
@@ -49,7 +49,7 @@ class TestInvalidFiles
private static final String ISARTOR_FILES = "invalid.files";
- protected static final Log staticLogger = LogFactory.getLog("Test");
+ protected static final Log LOG = LogFactory.getLog(TestInvalidFiles.class);
private static InvalidFileTester tester;
@@ -85,7 +85,7 @@ class TestInvalidFiles
String isartor = System.getProperty(ISARTOR_FILES);
if (isartor == null)
{
- staticLogger.warn(ISARTOR_FILES + " (where are isartor pdf files) is not defined.");
+ LOG.warn(ISARTOR_FILES + " (where are isartor pdf files) is not defined.");
return stopIfExpected();
}
File root = new File(isartor);
@@ -94,14 +94,14 @@ class TestInvalidFiles
String expectedPath = System.getProperty(EXPECTED_ERRORS);
if (expectedPath == null)
{
- staticLogger.warn(EXPECTED_ERRORS + " not defined, only check if file is invalid");
+ LOG.warn(EXPECTED_ERRORS + " not defined, only check if file is invalid");
}
else
{
File expectedFile = new File(expectedPath);
if (!expectedFile.exists() || !expectedFile.isFile())
{
- staticLogger.warn("'expected.errors' does not reference valid file, so cannot execute tests : "
+ LOG.warn("'expected.errors' does not reference valid file, so cannot execute tests : "
+ expectedFile.getAbsolutePath());
return stopIfExpected();
}
Modified: pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestIsartorValidation.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestIsartorValidation.java?rev=1908467&r1=1908466&r2=1908467&view=diff
==============================================================================
--- pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestIsartorValidation.java (original)
+++ pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestIsartorValidation.java Sat Mar 18 04:39:12 2023
@@ -49,7 +49,7 @@ class TestIsartorValidation
private static final String ISARTOR_FILES = "isartor.files";
- protected static final Log staticLogger = LogFactory.getLog("Test");
+ protected static final Log LOG = LogFactory.getLog(TestIsartorValidation.class);
private static InvalidFileTester tester;
@@ -85,7 +85,7 @@ class TestIsartorValidation
String isartor = System.getProperty(ISARTOR_FILES);
if (isartor == null)
{
- staticLogger.warn(ISARTOR_FILES + " (where are isartor pdf files) is not defined.");
+ LOG.warn(ISARTOR_FILES + " (where are isartor pdf files) is not defined.");
return stopIfExpected();
}
File root = new File(isartor);
@@ -93,13 +93,13 @@ class TestIsartorValidation
String expectedPath = System.getProperty(EXPECTED_ERRORS);
if (expectedPath == null)
{
- staticLogger.warn("'expected.errors' not defined, so cannot execute tests");
+ LOG.warn("'expected.errors' not defined, so cannot execute tests");
return stopIfExpected();
}
File expectedFile = new File(expectedPath);
if (!expectedFile.exists() || !expectedFile.isFile())
{
- staticLogger.warn("'expected.errors' does not reference valid file, so cannot execute tests : "
+ LOG.warn("'expected.errors' does not reference valid file, so cannot execute tests : "
+ expectedFile.getAbsolutePath());
return stopIfExpected();
}
Modified: pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestValidFiles.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestValidFiles.java?rev=1908467&r1=1908466&r2=1908467&view=diff
==============================================================================
--- pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestValidFiles.java (original)
+++ pdfbox/trunk/preflight/src/test/java/org/apache/pdfbox/preflight/integration/TestValidFiles.java Sat Mar 18 04:39:12 2023
@@ -54,7 +54,7 @@ class TestValidFiles
protected File path;
- protected static final Log staticLogger = LogFactory.getLog("Test");
+ protected static final Log LOG = LogFactory.getLog(TestValidFiles.class);
protected Log logger = null;
@@ -72,7 +72,7 @@ class TestValidFiles
String isartor = System.getProperty(ISARTOR_FILES);
if (isartor == null || isartor.isEmpty())
{
- staticLogger.warn(ISARTOR_FILES + " (where are isartor pdf files) is not defined.");
+ LOG.warn(ISARTOR_FILES + " (where are isartor pdf files) is not defined.");
return stopIfExpected();
}
File root = new File(isartor);