have you checked the issues for the surefire project, or the surefire-plugin?

On 5/13/06, Simon Kitching <[EMAIL PROTECTED]> wrote:
Hi,

I've just gone through all the JIRA issues for SUREFIRE and can't see
any such issue. If it is true that src classes come before test classes
then I agree an issue should be raised. Ido, you could just add a test
which does
   System.out.println(
     this.getClassLoader().getResource("log4j.properties").toString());
or similar to see which log4j properties file is seen first.

Another possibility for the log4j.properties being ignored is that there
is a log4j.xml file in the classpath somewhere. Config files in xml
format are used in preference to ones in properties format.

Regards,

Simon

On Sat, 2006-05-13 at 02:47 +0300, Arik Kfir wrote:
> I think there's a JIRA on the surefire plugin which gives precedence
> to the main classes over the test classes - hence the log4j.properties
> in src/main/resources is used before the src/test/resources's file is
> loaded.
>
>
>
> On 5/12/06, Ido M. Tamir <[EMAIL PROTECTED]> wrote:
> > Hi,
> >
> > I am using maven 2.0.4
> > I have log4j.properties file in src/test/resources and
> > src/main/resources.
> >
> > after compilation directory structure:
> >
> > -- test-classes
> > |       |-- hibernate.cfg.xml
> > |       |-- import.properties
> > |       |-- log4j.properties
> > |       `-- org
> >
> > The settings in this file are ignored in unit tests
> > and other settings (assembly...).
> > When I remove both files log4j doesn't even
> > complain.
> >
> > The log level always seems to be info.
> > This is also true for unit test run from
> > eclipse (I use mvn eclipse:eclipse)
> >
> > This is independent of having commons-logging
> > as a dependency or not.
> >
> > thank you very much for your suggestions
> > ido
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
______________________________________
Cheers,
     Arik Kfir                                   [EMAIL PROTECTED]
     Linux user, number 415067 - http://counter.li.org/
     http://corleon.dnsalias.org

Reply via email to