You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by Jeremy Boynes <je...@coredevelopers.net> on 2003/08/13 21:49:45 UTC

[test] maven unit tests

I just added the unit tests for Maas van den Berg's JSR-88 impl and they do
not seem to be run. Could this be because they are in a javax.* package?
Anyone have any other ideas?

Also, when I ran maven --debug it seemed that every unit test was run in a
separate shell. Is this true, deliberate, and if so desirable given we
should end up with a *lot* of these?

--
Jeremy


RE: [test] maven unit tests

Posted by Jeremy Boynes <je...@coredevelopers.net>.
Duh - I couldn't see it for looking either - will fix now.

> -----Original Message-----
> From: Maas van den Berg [mailto:email@dds.nl]
> Sent: Wednesday, August 13, 2003 1:11 PM
> To: geronimo-dev@incubator.apache.org
> Subject: Re: [test] maven unit tests
> 
> 
> Jeremy,
> 
> Oops, I used the naming convention from work. All test classes are
> prefixed with Test instead of postfixed with Test. Sorry about that.
> 
> Maas


Re: [test] maven unit tests

Posted by Maas van den Berg <em...@dds.nl>.
Jeremy,

Oops, I used the naming convention from work. All test classes are
prefixed with Test instead of postfixed with Test. Sorry about that.

Maas

On Wed, 2003-08-13 at 21:49, Jeremy Boynes wrote:
> I just added the unit tests for Maas van den Berg's JSR-88 impl and they do
> not seem to be run. Could this be because they are in a javax.* package?
> Anyone have any other ideas?
> 
> Also, when I ran maven --debug it seemed that every unit test was run in a
> separate shell. Is this true, deliberate, and if so desirable given we
> should end up with a *lot* of these?
> 
> --
> Jeremy
> 


Re: [test] maven unit tests

Posted by Maas van den Berg <em...@dds.nl>.
Jeremy,

Every unit test running in a freshly forked JVM makes sense if you think
about 'static' resources. 

Maas
On Wed, 2003-08-13 at 21:49, Jeremy Boynes wrote:
> I just added the unit tests for Maas van den Berg's JSR-88 impl and they do
> not seem to be run. Could this be because they are in a javax.* package?
> Anyone have any other ideas?
> 
> Also, when I ran maven --debug it seemed that every unit test was run in a
> separate shell. Is this true, deliberate, and if so desirable given we
> should end up with a *lot* of these?
> 
> --
> Jeremy
> 


RE: [test] maven unit tests

Posted by Jeremy Boynes <je...@coredevelopers.net>.
> > Would it be better to set it to false so we deal with these from the
> > outset?
>
> Not IMHO. Unless you fancy debugging class loader issues in maven /
> junit / ant / jaxp which has nothing whatsoever to do with Geronimo.
> Note we're talking about class loader issues of actually running the
> Ant JUnit tasks inside Maven here - not Geronimo based class loading
> problems.
>
> After suffering various class loader issues in the past (especially
> about using XML inside a JUnit test case) I always set this flag to
> true. Though be my guest if you wanna turn it off - just be warned &
> get ready to flip it back on later.
>

It a compromise to run one junit task in a separate VM so there is one fork
not a bizillion? This would isolate us from maven/ant issues leaving us with
just junit/geronimo ones (which we ought to fix if this thing is going to be
embeddable).

--
Jeremy


Re: [test] maven unit tests

Posted by James Strachan <ja...@yahoo.co.uk>.
On Wednesday, August 13, 2003, at 09:53  pm, Jeremy Boynes wrote:

>> FWIW right now we're using maven.test.fork=true (in
>> etc/project.properties) to spawn new JVMs when running the unit tests 
>> -
>> this fixes all kinds of classpath issues you often get with unit 
>> tests,
>> JUnit, Ant & XML parsers etc.
>>
>
> Would it be better to set it to false so we deal with these from the 
> outset?

Not IMHO. Unless you fancy debugging class loader issues in maven / 
junit / ant / jaxp which has nothing whatsoever to do with Geronimo. 
Note we're talking about class loader issues of actually running the 
Ant JUnit tasks inside Maven here - not Geronimo based class loading 
problems.

After suffering various class loader issues in the past (especially 
about using XML inside a JUnit test case) I always set this flag to 
true. Though be my guest if you wanna turn it off - just be warned & 
get ready to flip it back on later.

James
-------
http://radio.weblogs.com/0112098/


RE: [test] maven unit tests

Posted by Jeremy Boynes <je...@coredevelopers.net>.
> FWIW right now we're using maven.test.fork=true (in 
> etc/project.properties) to spawn new JVMs when running the unit tests - 
> this fixes all kinds of classpath issues you often get with unit tests, 
> JUnit, Ant & XML parsers etc.
> 

Would it be better to set it to false so we deal with these from the outset?

Re: [test] maven unit tests

Posted by James Strachan <ja...@yahoo.co.uk>.
On Wednesday, August 13, 2003, at 08:49  pm, Jeremy Boynes wrote:
> Also, when I ran maven --debug it seemed that every unit test was run 
> in a
> separate shell. Is this true, deliberate, and if so desirable given we
> should end up with a *lot* of these?

FWIW right now we're using maven.test.fork=true (in 
etc/project.properties) to spawn new JVMs when running the unit tests - 
this fixes all kinds of classpath issues you often get with unit tests, 
JUnit, Ant & XML parsers etc.

James
-------
http://radio.weblogs.com/0112098/