You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Steinar Bang <sb...@dod.no> on 2012/09/28 10:55:18 UTC

maven-archetype-simple: JUnit 3.8 is really old.

I created a project with maven-archetype-simple, and it creates a
project with a dependey to JUnit 3.8.1.

JUnit 3.8.1 is really old.  In fact it's so old I've been unable to
google when it was released.  The oldest relase I find is the release of
JUnit 4.5 in 2008 http://www.junit.org/node/401

Ah... found something: Release date: 5 September 2002.
 http://grepcode.com/snapshot/repo1.maven.org/maven2/junit/junit/3.8.1

Really, really old!

I would have liked to report an issue for this, but I have been unable
to figure out what the newest version is, and what issues have been
reported and fixed.

The newest site for maven-archetype-plugin seems to be for version
1.0-alpha7, dated February 8 2008
 http://maven.apache.org/plugins/maven-archetype-plugin-1.0-alpha-7/

The issue site shows versions 2.3, 2.4, and 2.x, all listed under the
heading of "Unreleased":
 http://jira.codehaus.org/browse/ARCHETYPE

I am confused...


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


Re: maven-archetype-quickstart: JUnit 3.8 is really old.

Posted by Steinar Bang <sb...@dod.no>.
>>>>> Steinar Bang <sb...@dod.no>:
>>>>> Steinar Bang <sb...@dod.no>:

>> If it's still 3.8.1, I'll file a bug.

> Hm... that didn't work...?

I have now filed a bug, in case anyone would like to vote on it:
 https://jira.codehaus.org/browse/MARCHETYPES-41

(Note: 3.8.1 is *really* old... 10 years is over half the lifetime of Java itself...)


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


Re: maven-archetype-quickstart: JUnit 3.8 is really old.

Posted by Steinar Bang <sb...@dod.no>.
>>>>> Steinar Bang <sb...@dod.no>:

> I haven't been able to list all Jira issues here yet.  I think I will
> try to instantiate a quickstart archetype from 5-SNAPSHOT and see what
> happens. 

> If it's still 3.8.1, I'll file a bug.

Hm... that didn't work...?

I tried the command example on this page:
 http://maven.apache.org/archetype/maven-archetype-bundles/maven-archetype-quickstart/

Ie. the command line:
 mvn archetype:generate -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-quickstart -DarchetypeVersion=5-SNAPSHOT

But the command line failed, because it couldn't find version 5-SNAPSHOT
of the quickstart archetype plugin:

[INFO] Generating project in Interactive mode
[INFO] Archetype repository missing. Using the one from [org.apache.maven.archetypes:maven-archetype-quickstart:1.1] found in catalog remote
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 26.596s
[INFO] Finished at: Fri Sep 28 19:35:27 CEST 2012
[INFO] Final Memory: 9M/21M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.2:generate (default-cli) on project standalone-pom: The desired archetype does not exist (org.apache.maven.archetypes:maven-archetype-quickstart:5-SNAPSHOT) -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException


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


maven-archetype-quickstart: JUnit 3.8 is really old. (Was: maven-archetype-simple: JUnit 3.8 is really old.)

Posted by Steinar Bang <sb...@dod.no>.
>>>>> Olivier Lamy <ol...@apache.org>:

> Agree it's old :-)

> Jira project is here: http://jira.codehaus.org/browse/MARCHETYPES

Thanks!  And from the above URL I got to here:
 http://maven.apache.org/archetype/maven-archetype-bundles/maven-archetype-quickstart/

"quickstart", not "simple".

Checking what I actually did, "quickstart" is what I used, not "simple".
I must have stumbled over maven-quickstart-simple, when googling.

Anyway, maven-archetype-quickstart also uses JUnit 3.8.1.  At least the
version that appeared for me with mvn 3.0.4.

I haven't been able to list all Jira issues here yet.  I think I will
try to instantiate a quickstart archetype from 5-SNAPSHOT and see what
happens. 

If it's still 3.8.1, I'll file a bug.


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


Re: maven-archetype-simple: JUnit 3.8 is really old.

Posted by Tim Pizey <ti...@gmail.com>.
Hi Steinar,

Thank you for this, no doubt you are right.

We now superstitiously continue with JUnit 3 naming conventions for
test classes and test methods,
whether we are using Junit3, 4 or TestNG (yes we use all three!)

It was indeed when TestNG was introduced that we had this problem.

For my taste I would not move away from a classic version, but I am
not fashionable :)

If you have not yet used Jenkins have a go: you will not look back.

thanks
Tim


On 28 September 2012 16:08, Steinar Bang wrote:
>>>>>> Tim Pizey :
>
>> Not everyone uses annotations, the surefire plugin requires the JUnit
>> 3.8.1 naming conventions,
>
> That doesn't seem to be the case:
>  http://maven.apache.org/plugins/maven-surefire-plugin/examples/junit.html
>
> Quote:
>   "Surefire supports three different generations of JUnit: JUnit 3.8.x,
>    JUnit 4.x (serial provider) and JUnit 4.7 (junit-core provider with
>    parallel support)."
>
>> the Jenkins plugins assume the same conventions.
>
> Hm... I haven't yet tried Jenkins, but I would surprised if Jenkins does
> anything outside of what maven would do, for a maven build...?
>
>> We have been bitten by People using JUnit4 and TestNG and hence
>> skipping tests in Jenkins.
>
> I found this on Stack Overflow, someone who had surefire not picking up
> tests marked with annotations:
>  http://stackoverflow.com/questions/2021771/surefire-is-not-picking-up-junit-4-tests
>
> It seems that in this case, this was a case of TestNG requiring JUnit
> 3.8.1 and shadowing a later dependance of JUnit 4.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>



-- 
Tim Pizey - http://pizey.net/~timp

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


Re: maven-archetype-simple: JUnit 3.8 is really old.

Posted by Olivier Lamy <ol...@apache.org>.
note the feature -Dtest=MyTest#myMethod is not supported with 3.8

2012/9/28 Steinar Bang <sb...@dod.no>:
>>>>>> Tim Pizey <ti...@gmail.com>:
>
>> Not everyone uses annotations, the surefire plugin requires the JUnit
>> 3.8.1 naming conventions,
>
> That doesn't seem to be the case:
>  http://maven.apache.org/plugins/maven-surefire-plugin/examples/junit.html
>
> Quote:
>   "Surefire supports three different generations of JUnit: JUnit 3.8.x,
>    JUnit 4.x (serial provider) and JUnit 4.7 (junit-core provider with
>    parallel support)."
>
>> the Jenkins plugins assume the same conventions.
>
> Hm... I haven't yet tried Jenkins, but I would surprised if Jenkins does
> anything outside of what maven would do, for a maven build...?
>
>> We have been bitten by People using JUnit4 and TestNG and hence
>> skipping tests in Jenkins.
>
> I found this on Stack Overflow, someone who had surefire not picking up
> tests marked with annotations:
>  http://stackoverflow.com/questions/2021771/surefire-is-not-picking-up-junit-4-tests
>
> It seems that in this case, this was a case of TestNG requiring JUnit
> 3.8.1 and shadowing a later dependance of JUnit 4.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>



-- 
Olivier Lamy
Talend: http://coders.talend.com
http://twitter.com/olamy | http://linkedin.com/in/olamy

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


Re: maven-archetype-simple: JUnit 3.8 is really old.

Posted by Steinar Bang <sb...@dod.no>.
>>>>> Tim Pizey <ti...@gmail.com>:

> Not everyone uses annotations, the surefire plugin requires the JUnit
> 3.8.1 naming conventions,

That doesn't seem to be the case:
 http://maven.apache.org/plugins/maven-surefire-plugin/examples/junit.html

Quote:
  "Surefire supports three different generations of JUnit: JUnit 3.8.x,
   JUnit 4.x (serial provider) and JUnit 4.7 (junit-core provider with
   parallel support)."

> the Jenkins plugins assume the same conventions.

Hm... I haven't yet tried Jenkins, but I would surprised if Jenkins does
anything outside of what maven would do, for a maven build...?

> We have been bitten by People using JUnit4 and TestNG and hence
> skipping tests in Jenkins.

I found this on Stack Overflow, someone who had surefire not picking up
tests marked with annotations:
 http://stackoverflow.com/questions/2021771/surefire-is-not-picking-up-junit-4-tests

It seems that in this case, this was a case of TestNG requiring JUnit
3.8.1 and shadowing a later dependance of JUnit 4.


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


Re: maven-archetype-simple: JUnit 3.8 is really old.

Posted by Tim Pizey <ti...@gmail.com>.
Hi,

Yes it is old, but it is the best JUnit :)
The 4 series jumped the shark for meĀ·

Old != bad.

I am not trying to start a flame war here, but assumed that it was
3.8.1 deliberately,
as this is the best JUnit can get.

Not everyone uses annotations, the surefire plugin requires the JUnit
3.8.1 naming conventions,
the Jenkins plugins assume the same conventions. We have been bitten
by People using JUnit4 and TestNG
and hence skipping tests in Jenkins.

I would do not think it would be an improvement to change this.

cheers
Tim




On 28 September 2012 11:25, Olivier Lamy <ol...@apache.org> wrote:
> Hi,
> Agree it's old :-)
>
> Jira project is here: http://jira.codehaus.org/browse/MARCHETYPES
>
> 2012/9/28 Steinar Bang <sb...@dod.no>:
>> I created a project with maven-archetype-simple, and it creates a
>> project with a dependey to JUnit 3.8.1.
>>
>> JUnit 3.8.1 is really old.  In fact it's so old I've been unable to
>> google when it was released.  The oldest relase I find is the release of
>> JUnit 4.5 in 2008 http://www.junit.org/node/401
>>
>> Ah... found something: Release date: 5 September 2002.
>>  http://grepcode.com/snapshot/repo1.maven.org/maven2/junit/junit/3.8.1
>>
>> Really, really old!
>>
>> I would have liked to report an issue for this, but I have been unable
>> to figure out what the newest version is, and what issues have been
>> reported and fixed.
>>
>> The newest site for maven-archetype-plugin seems to be for version
>> 1.0-alpha7, dated February 8 2008
>>  http://maven.apache.org/plugins/maven-archetype-plugin-1.0-alpha-7/
>>
>> The issue site shows versions 2.3, 2.4, and 2.x, all listed under the
>> heading of "Unreleased":
>>  http://jira.codehaus.org/browse/ARCHETYPE
>>
>> I am confused...
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>
>
>
> --
> Olivier Lamy
> Talend: http://coders.talend.com
> http://twitter.com/olamy | http://linkedin.com/in/olamy
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>



-- 
Tim Pizey - http://pizey.net/~timp

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


Re: maven-archetype-simple: JUnit 3.8 is really old.

Posted by Olivier Lamy <ol...@apache.org>.
Hi,
Agree it's old :-)

Jira project is here: http://jira.codehaus.org/browse/MARCHETYPES

2012/9/28 Steinar Bang <sb...@dod.no>:
> I created a project with maven-archetype-simple, and it creates a
> project with a dependey to JUnit 3.8.1.
>
> JUnit 3.8.1 is really old.  In fact it's so old I've been unable to
> google when it was released.  The oldest relase I find is the release of
> JUnit 4.5 in 2008 http://www.junit.org/node/401
>
> Ah... found something: Release date: 5 September 2002.
>  http://grepcode.com/snapshot/repo1.maven.org/maven2/junit/junit/3.8.1
>
> Really, really old!
>
> I would have liked to report an issue for this, but I have been unable
> to figure out what the newest version is, and what issues have been
> reported and fixed.
>
> The newest site for maven-archetype-plugin seems to be for version
> 1.0-alpha7, dated February 8 2008
>  http://maven.apache.org/plugins/maven-archetype-plugin-1.0-alpha-7/
>
> The issue site shows versions 2.3, 2.4, and 2.x, all listed under the
> heading of "Unreleased":
>  http://jira.codehaus.org/browse/ARCHETYPE
>
> I am confused...
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>



-- 
Olivier Lamy
Talend: http://coders.talend.com
http://twitter.com/olamy | http://linkedin.com/in/olamy

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