You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Ole Ersoy <ol...@yahoo.com> on 2006/12/03 01:14:26 UTC

Maven Experiments

OK - I Ran some tests.

Here's the Summary (Test description is below for
those interested).




Summary:
Multi Level inheritance of dependencyManagement
elements works.

Maven requires a version to be specified on
dependencies and will not
run if they are missing.









TEST DESCRIPTION

TLProject
---------------------------------------------
I created a project named TLProject and added 
a single JUnit Dependency to the 
dependencyManagement section

I completely deleted the dependencies section.

L1Project
-----------------------------------------------
Then I added a child project to this Project:
L1Project.

This project has packaging pom and no dependencies
or dependencyManagement sections.

L2Project
-----------------------------------------------
Then I added a child project to this project.

I just removed the version and scope from the Junit
dependency.




Test1: I want to know if the default test will run
---------------------------------------------------
Result: I now run mvn test, and it runs fine.




Test2: I want to know if it will run if I delete
the dependency in the dependencyManagement of the
TLProject.  This would mean that Maven allows 
dependencies without a scope and version.
--------------------------------------------------
Result: I run mvn test (In the L2Project root), and I
get a Failed to Validate POM exception.  That's good. 
Maven didn't just assume that I wanted the latest 
version in the repository.  

So we know maven requires versions on dependencies.


Summary:
Multi Level inheritance of POM Dependencies work.
Maven requires versions on dependencies and will not
run if they are missing.




 
____________________________________________________________________________________
Yahoo! Music Unlimited
Access over 1 million songs.
http://music.yahoo.com/unlimited

Re: Maven Experiments

Posted by Ole Ersoy <ol...@yahoo.com>.
Hey Emmanuel,

Good Test!

I discovered some vaaary interesting things.

So I'm shell scripting all the tests to that
they are repeatable.

I'll upload them to my sandbox asap.

Cheers,
- Ole


--- Emmanuel Lecharny <el...@gmail.com> wrote:

> Interesting test ! (May be maven's guy could be
> interested in such a test)
> 
> Could you try something? Suppose you have :
> TLP -> PL2 -> PL3
> (PLx means Project Level x)
> 
> with a test in each level, and each test depends on
> a very specific version
> of commons-collection. For instance, PL2 use
> commons-collection 2.1.1 and
> PL3 use version 3.2.
> 
> In the PL2 test, you use
>
ArrayEnumeration<http://jakarta.apache.org/commons/collections/api-2.1.1/org/apache/commons/collections/ArrayEnumeration.html>which
> does not exist anymore in
> 3.2
> In the PL3 test, you use
>
AbstractBagDecorator<http://jakarta.apache.org/commons/collections/api-release/org/apache/commons/collections/bag/AbstractBagDecorator.html>which
> does not exist in
> 2.1.1
> 
> Now, try to make it works with different
> combinations.
> 
> It could also be interesting that you push your test
> to your sandbox, so
> that we may experiment such tests without having to
> recreate all those poms
> :) (I know, i'm lazy :)
> 
> Thanks !
> 
> Emmanuel
> 
> On 12/3/06, Ole Ersoy <ol...@yahoo.com> wrote:
> >
> > OK - I Ran some tests.
> >
> > Here's the Summary (Test description is below for
> > those interested).
> >
> >
> >
> >
> > Summary:
> > Multi Level inheritance of dependencyManagement
> > elements works.
> >
> > Maven requires a version to be specified on
> > dependencies and will not
> > run if they are missing.
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > TEST DESCRIPTION
> >
> > TLProject
> > ---------------------------------------------
> > I created a project named TLProject and added
> > a single JUnit Dependency to the
> > dependencyManagement section
> >
> > I completely deleted the dependencies section.
> >
> > L1Project
> > -----------------------------------------------
> > Then I added a child project to this Project:
> > L1Project.
> >
> > This project has packaging pom and no dependencies
> > or dependencyManagement sections.
> >
> > L2Project
> > -----------------------------------------------
> > Then I added a child project to this project.
> >
> > I just removed the version and scope from the
> Junit
> > dependency.
> >
> >
> >
> >
> > Test1: I want to know if the default test will run
> >
> ---------------------------------------------------
> > Result: I now run mvn test, and it runs fine.
> >
> >
> >
> >
> > Test2: I want to know if it will run if I delete
> > the dependency in the dependencyManagement of the
> > TLProject.  This would mean that Maven allows
> > dependencies without a scope and version.
> > --------------------------------------------------
> > Result: I run mvn test (In the L2Project root),
> and I
> > get a Failed to Validate POM exception.  That's
> good.
> > Maven didn't just assume that I wanted the latest
> > version in the repository.
> >
> > So we know maven requires versions on
> dependencies.
> >
> >
> > Summary:
> > Multi Level inheritance of POM Dependencies work.
> > Maven requires versions on dependencies and will
> not
> > run if they are missing.
> >
> >
> >
> >
> >
> >
> >
>
____________________________________________________________________________________
> > Yahoo! Music Unlimited
> > Access over 1 million songs.
> > http://music.yahoo.com/unlimited
> >
> 
> 
> 
> -- 
> Cordialement,
> Emmanuel Lécharny
> 



 
____________________________________________________________________________________
Yahoo! Music Unlimited
Access over 1 million songs.
http://music.yahoo.com/unlimited

Re: Maven Experiments

Posted by Emmanuel Lecharny <el...@gmail.com>.
Interesting test ! (May be maven's guy could be interested in such a test)

Could you try something? Suppose you have :
TLP -> PL2 -> PL3
(PLx means Project Level x)

with a test in each level, and each test depends on a very specific version
of commons-collection. For instance, PL2 use commons-collection 2.1.1 and
PL3 use version 3.2.

In the PL2 test, you use
ArrayEnumeration<http://jakarta.apache.org/commons/collections/api-2.1.1/org/apache/commons/collections/ArrayEnumeration.html>which
does not exist anymore in
3.2
In the PL3 test, you use
AbstractBagDecorator<http://jakarta.apache.org/commons/collections/api-release/org/apache/commons/collections/bag/AbstractBagDecorator.html>which
does not exist in
2.1.1

Now, try to make it works with different combinations.

It could also be interesting that you push your test to your sandbox, so
that we may experiment such tests without having to recreate all those poms
:) (I know, i'm lazy :)

Thanks !

Emmanuel

On 12/3/06, Ole Ersoy <ol...@yahoo.com> wrote:
>
> OK - I Ran some tests.
>
> Here's the Summary (Test description is below for
> those interested).
>
>
>
>
> Summary:
> Multi Level inheritance of dependencyManagement
> elements works.
>
> Maven requires a version to be specified on
> dependencies and will not
> run if they are missing.
>
>
>
>
>
>
>
>
>
> TEST DESCRIPTION
>
> TLProject
> ---------------------------------------------
> I created a project named TLProject and added
> a single JUnit Dependency to the
> dependencyManagement section
>
> I completely deleted the dependencies section.
>
> L1Project
> -----------------------------------------------
> Then I added a child project to this Project:
> L1Project.
>
> This project has packaging pom and no dependencies
> or dependencyManagement sections.
>
> L2Project
> -----------------------------------------------
> Then I added a child project to this project.
>
> I just removed the version and scope from the Junit
> dependency.
>
>
>
>
> Test1: I want to know if the default test will run
> ---------------------------------------------------
> Result: I now run mvn test, and it runs fine.
>
>
>
>
> Test2: I want to know if it will run if I delete
> the dependency in the dependencyManagement of the
> TLProject.  This would mean that Maven allows
> dependencies without a scope and version.
> --------------------------------------------------
> Result: I run mvn test (In the L2Project root), and I
> get a Failed to Validate POM exception.  That's good.
> Maven didn't just assume that I wanted the latest
> version in the repository.
>
> So we know maven requires versions on dependencies.
>
>
> Summary:
> Multi Level inheritance of POM Dependencies work.
> Maven requires versions on dependencies and will not
> run if they are missing.
>
>
>
>
>
>
> ____________________________________________________________________________________
> Yahoo! Music Unlimited
> Access over 1 million songs.
> http://music.yahoo.com/unlimited
>



-- 
Cordialement,
Emmanuel Lécharny