You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Mark <ma...@liw.lt> on 2005/12/27 01:32:34 UTC

Testing with MAven2

Hello.

I'm extremely new to Maven2, therefore I strictly do everything according to
the tutorial. Well, I came to testing where I need to test some domain class
(User.class), which is under src/main/java/..., while my testcase class is
under src/test/java/... .
But maven2, running the testcase ("mvn test" command), reports an exception,
that the code in testcase does NOT find needed domain class (User.class)
from src/main/java/... .
So should I copy all classes that I want to test (or use in my tests) from
src/main/java/... to src/test/java/... or it must be configured or automated
somhow?

Thank You,
Mark.



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


Re: Testing with MAven2

Posted by Koen Maes <ko...@koma.be>.
easiest is to start here :

http://maven.apache.org/guides/mini/guide-creating-archetypes.html

actually, this does it all.

mvn archetype:create -DarchetypeGroupId=<archetype-groupId> 
-DarchetypeArtifactId=<archetype-artifactId> \ 
  -DarchetypeVersion=<archetype-version> -DgroupId=<my.groupid> 
-DartifactId=<my-artifactId>


On Tuesday 27 December 2005 01:32, Mark wrote:
> Hello.
>
> I'm extremely new to Maven2, therefore I strictly do everything according
> to the tutorial. Well, I came to testing where I need to test some domain
> class (User.class), which is under src/main/java/..., while my testcase
> class is under src/test/java/... .
> But maven2, running the testcase ("mvn test" command), reports an
> exception, that the code in testcase does NOT find needed domain class
> (User.class) from src/main/java/... .
> So should I copy all classes that I want to test (or use in my tests) from
> src/main/java/... to src/test/java/... or it must be configured or
> automated somhow?
>
> Thank You,
> Mark.
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org

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