You are viewing a plain text version of this content. The canonical link for it is here.
Posted to doxia-commits@maven.apache.org by lt...@apache.org on 2011/01/21 10:19:38 UTC
svn commit: r1061700 -
/maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidator.java
Author: ltheussl
Date: Fri Jan 21 09:19:37 2011
New Revision: 1061700
URL: http://svn.apache.org/viewvc?rev=1061700&view=rev
Log:
avoid deprecated logger calls
Modified:
maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidator.java
Modified: maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidator.java
URL: http://svn.apache.org/viewvc/maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidator.java?rev=1061700&r1=1061699&r2=1061700&view=diff
==============================================================================
--- maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidator.java (original)
+++ maven/doxia/doxia/trunk/doxia-core/src/test/java/org/apache/maven/doxia/xsd/AbstractXmlValidator.java Fri Jan 21 09:19:37 2011
@@ -30,8 +30,10 @@ import java.util.Map;
import junit.framework.AssertionFailedError;
import org.apache.maven.doxia.parser.AbstractXmlParser;
+import org.apache.maven.doxia.parser.Parser;
import org.codehaus.plexus.PlexusTestCase;
+import org.codehaus.plexus.logging.Logger;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
@@ -98,13 +100,15 @@ public abstract class AbstractXmlValidat
public void testValidateFiles()
throws Exception
{
+ final Logger logger = getContainer().getLoggerManager().getLoggerForComponent( Parser.ROLE );
+
for ( Iterator it = getTestDocuments().entrySet().iterator(); it.hasNext(); )
{
Map.Entry entry = (Map.Entry) it.next();
- if ( getContainer().getLogger().isDebugEnabled() )
+ if ( logger.isDebugEnabled() )
{
- getContainer().getLogger().debug( "Validate '" + entry.getKey() + "'" );
+ logger.debug( "Validate '" + entry.getKey() + "'" );
}
List errors = parseXML( entry.getValue().toString() );
@@ -119,9 +123,9 @@ public abstract class AbstractXmlValidat
}
else
{
- if ( getContainer().getLogger().isDebugEnabled() )
+ if ( logger.isDebugEnabled() )
{
- getContainer().getLogger().debug( entry.getKey() + EOL + error.toString() );
+ logger.debug( entry.getKey() + EOL + error.toString() );
}
}
}