lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dawid Weiss (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LUCENE-4045) Switch Maven test runner from maven-surefire-plugin to com.carrotsearch.randomizedtesting:junit4-maven-plugin
Date Thu, 10 May 2012 08:08:47 GMT

    [ https://issues.apache.org/jira/browse/LUCENE-4045?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13272171#comment-13272171
] 

Dawid Weiss commented on LUCENE-4045:
-------------------------------------

Wrt. maven3 vs. maven2 -- feel free to dive into the plugin mojo code and see if you can make
it work for both maven3 and 2. I admit I was stripping some code from maven source code to
make it work -- I'm sure it can be done better/ nicer but I don't have the necessary knowledge
of maven APIs.
                
> Switch Maven test runner from maven-surefire-plugin to com.carrotsearch.randomizedtesting:junit4-maven-plugin
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4045
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4045
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: general/test
>    Affects Versions: 4.0
>            Reporter: Steven Rowe
>            Priority: Minor
>
> {{com.carrotsearch.randomizedtesting:junit4-maven-plugin}} can be used to run all Lucene/Solr
tests under Maven, providing faster execution through load balancing, along with all the other
goodies CS.RT brings.  (Not to mention it would make testing under Maven much more like testing
under Ant.)
> From [a post Dawid Weiss made on the maven-dev mailing list in January|http://mail-archives.apache.org/mod_mbox/maven-dev/201201.mbox/%3CCAM21Rt8KDxOwWMy3UQ+fqVn979Fq3mbM_gvEqWOH226mH_zNgw@mail.gmail.com%3E]:
> {quote}
> http://labs.carrotsearch.com/randomizedtesting.html
> [...]
> Load balancing is just part of what the project is about [...]
> Maven integration can be seen as an integration test (with scarce documentation yet)
here:
> https://github.com/carrotsearch/randomizedtesting/blob/master/integration-maven/junit4-maven-plugin-tests/src/it/01-basic-test/pom.xml
> I've used it in another project, so a cleaner example of use from within a POM is here
(you should disable surefire or your tests will run twice):
> https://github.com/carrotsearch/hppc/blob/master/hppc-core/pom.xml#L217
> {quote}
> And from [a post Dawid made to the lucene-dev mailing list in April|http://mail-archives.apache.org/mod_mbox/lucene-dev/201204.mbox/%3CCAM21Rt-Rc_Z6X04fznvsbK-d8APiUuYCMC-kvg7i=HZThAQvSg@mail.gmail.com%3E]:
> {quote}
> I didn't mention it but there is actually an equivalent of <junit4> task as a maven
plugin... it basically redirects to the ant-plugin but has a maven-like facade for passing
the basic set of properties. I don't think it makes such a big difference for maven build
- we can stick to surefire. Let me know if you'd like to try that other plugin though -- an
example of a maven pom using it is here:
> https://github.com/carrotsearch/randomizedtesting/blob/master/examples/maven/pom.xml
> {quote}
> The CS.RT maven plugin requires Maven v3.0.2+; I asked Dawid whether Maven 2.2.1 could
be supported, and in private emails to me, he replied:
> {quote}
> I looked at it but it seems I need to stick to Maven 3 -- there are APIs for filtering
artefacts that seem to be available in 3.x only (copied and pasted from surefire and maven
core). If you want to dig the code is on github, I won't have the time to look into it in
the near future (first short vacation, then a backlog of crap to deal with).
> {quote}
> {quote}
> I admit I don't have enough Maven powers to actually think of a way to use either surefire
or another plugin (depending on a sysproperty or something). This could be a fallback for
folks who really need maven 2.x.
> {quote}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

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


Mime
View raw message