cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robin Rigby" <ro...@gondolier.org.uk>
Subject RE: AbstractTestCase
Date Mon, 28 Jan 2008 01:08:39 GMT
Neat.  Thank you 


 
Robin

-----Original Message-----
From: Grzegorz Kossakowski [mailto:gkossakowski@apache.org] 
Sent: 27 January 2008 23:03
To: users@cocoon.apache.org
Subject: Re: AbstractTestCase

Robin Rigby pisze:
> Hi 
> 
> Have written action.  Compile OK, Install OK.
> 
> Need to test.  Found AbstractTestCase in cocoon-sitemap-impl.
> 
> How can I add a dependency to my POM that will make AbstractTestCase
> available to my test cases?  It is not included in
> cocoon-sitemap-impl.nnn.jar, is it?  So, no kind of <scope>test</scope>
will
> help?  Do I have to copy it?

AbstractTestCase is stored in separate jar
cocoon-sitemap-impl-tests-nnn.jar. The reason for doing
that is that our testing framework still introduces quite a lot of heavy
dependencies (we are
constantly working on cleaning up things) so we decided to put it into
separate jar to not pollute
applications build on top of Cocoon. Fortunately enough, Maven has native
support for such practice.

All you have to do is to add:

    <dependency>
      <groupId>org.apache.cocoon</groupId>
      <artifactId>cocoon-sitemap-impl</artifactId>
      <type>test-jar</type>
      <scope>test</scope>
      <version>...</version>
    </dependency>

(the trick was: <type> tag)

Ok... it's not enough due to annying bug described here[1]. Full snippet you
need to add is:
    <dependency>
      <groupId>org.apache.cocoon</groupId>
      <artifactId>cocoon-core</artifactId>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.cocoon</groupId>
      <artifactId>cocoon-sitemap-impl</artifactId>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>

Voting for MNG-1378 is probably a good idea.

[1] http://jira.codehaus.org/browse/MNG-1378

-- 
Grzegorz Kossakowski
Committer and PMC Member of Apache Cocoon
http://reflectingonthevicissitudes.wordpress.com/

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




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


Mime
View raw message