You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Bargon, Stuart" <sb...@clinphone.com> on 2004/06/09 14:05:17 UTC
Junit log4j xml paser error [priv]
Hi,
When I run the maven test:test goal I get the following warning from log4j
log4j:ERROR Parsing error on line 1 and column 1
log4j:ERROR Premature end of file.
log4j:ERROR Could not parse input source [org.xml.sax.InputSource@1f0aecc].
org.xml.sax.SAXParseException: Premature end of file.
at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:665)
at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:616)
at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:602)
at org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:460)
at org.apache.log4j.LogManager.<clinit>(LogManager.java:113)
at org.apache.log4j.Logger.getLogger(Logger.java:85)
I have tried forking Junit and the endorsed lib directory but it still doesn't get rid of the error.
Any ideas?
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Junit log4j xml paser error [priv]
Posted by Brett Porter <br...@apache.org>.
If you are forking junit then it is a problem in your log4j initialisation code.
I suggest putting a System.out in somewhere before any loggers are initialised
to see if the log4j configuration property is set to a dud file, because it
seems to be finding a default file, thinking it is XML, but not actually getting
XML.
Cheers,
Brett
Quoting "Bargon, Stuart" <sb...@clinphone.com>:
> Hi,
> When I run the maven test:test goal I get the following warning from log4j
>
> log4j:ERROR Parsing error on line 1 and column 1
> log4j:ERROR Premature end of file.
> log4j:ERROR Could not parse input source [org.xml.sax.InputSource@1f0aecc].
> org.xml.sax.SAXParseException: Premature end of file.
> at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
> at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
> at
> org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:665)
> at
> org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:616)
> at
> org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:602)
> at
>
org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:460)
> at org.apache.log4j.LogManager.<clinit>(LogManager.java:113)
> at org.apache.log4j.Logger.getLogger(Logger.java:85)
>
> I have tried forking Junit and the endorsed lib directory but it still
> doesn't get rid of the error.
>
> Any ideas?
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org