maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Dillon <ja...@planet57.com>
Subject Re: Adding extra dirs for surefire classpath
Date Sun, 01 Apr 2007 22:10:18 GMT
On Apr 1, 2007, at 2:38 PM, David J. M. Karlsen wrote:
> Jason Dillon skrev:
>> Whats the easiest way to add an extra directory to the classpath  
>> which surefire will use when running tests?
> http://jira.codehaus.org/browse/SUREFIRE-180
> Also - you could try defining system scoped dependencies - or  
> define them as testResource's

Not sure how system scoped dependencies would help at all... the  
sources are in the module I'm testing, to make that work I'd have to  
split up the module, which is lame.

I did try adding them as testResources, but stupid Surefire complains  
about duplicate test sets.  I'm really not happy with Surefire, I've  
spent the last day or so fighting with it to simply run some tests.   
I'm starting to think about just using Antrun and the Junit task.

Why does surefire need to be so damn magical?  Just let me run Junit  
or TestNG like the ant-versions do and be done with it.

Or fix the plugin so I can actually have full control over what its  
doing.  For example, I don't want any *.xml based tests to be run,  
but with surefire if I happen to have a file named like MyTest.xml,  
and then include **/*Test.* to run, then if I have a MyTest.java  
surefire complains about duplicate test tests.

I've also seen surefire complain about pojo-based tests... where did  
I configure surefire to use pojo muck?  This is all junit and I don't  
want any thing else to be run except for normal junit things.

And why is the include/exclude list so dang magical too... I never  
really understood why you configure the *.java bits to include vs.  
the class names/packages to run.  I'm even more confused by this,  
since I have *.java and *.groovy tests... so wtf is surefire doing...  
as with its default includes which are all *.java based, I can  
execute *.groovy tests with no additional configuration.

Anyways... I hope something can be done to make the surefire plugin  
more robust and compatible.  I keep running into problems with it and  
have to work around it, which is a HUGE PITA.

I guess its getting better slowly, but it seems to also get new bugs  
when features are added like when redirectTestOutputToFile is true,  
output might be corrupted.  Or altering the default classloading,  
which broke in 2.3 with tests that worked with 2.2.

:-(

--jason

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Mime
View raw message