You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cactus-user@jakarta.apache.org by An...@smartstream-stp.com on 2003/08/12 11:12:08 UTC

Partitioning/naming of test classes for differing xUnit tests?

Hi,

A bit of a theoretical question as I haven't got as far as having a
specific problem yet... :-)

What is the recommended way of partitioning your test code so that
different software such as Cactus, StrutsTestCase, JUnit can each run the
tests associated with them?  We currently have a few standard JUnit tests,
all in a mirrored 'test' directory alongside our source tree, where the
tests are named along the lines of 'xxxxxTest.java'.   Now we want to start
using Cactus and StrutsTestCase (and possibly TagUnit) to run more complex
tests but I'm not sure how best to split the test classes so that our Ant
build script can have each test framework run the relevant tests.

Any advice on the above would be appreciated as I've not found much help on
this on the web so far.

Thanks,

Andrew
--
Andrew Bate
SmartStream Technologies Ltd
Tel:  (01454) 855214
Web:  http://www.smartstream-stp.com/



RE: Partitioning/naming of test classes for differing xUnit tests?

Posted by Vincent Massol <vm...@pivolis.com>.
Hi Andrew,

The way I do it is by having separate source tree. For example:

<my project>
  |_ src
    |_ main
      |_ <package>
    |_ test         (pure junit tests)
      |_ <package>
    |_ test-cactus  (cactus tests)
      |_ <package>
    |_ test-aspect  (unit tests using AOP)
      |_ <package>
    |_ [...]

Hope it helps,
-Vincent

> -----Original Message-----
> From: Andrew.Bate@smartstream-stp.com [mailto:Andrew.Bate@smartstream-
> stp.com]
> Sent: 12 August 2003 11:12
> To: cactus-user@jakarta.apache.org
> Subject: Partitioning/naming of test classes for differing xUnit
tests?
> 
> Hi,
> 
> A bit of a theoretical question as I haven't got as far as having a
> specific problem yet... :-)
> 
> What is the recommended way of partitioning your test code so that
> different software such as Cactus, StrutsTestCase, JUnit can each run
the
> tests associated with them?  We currently have a few standard JUnit
tests,
> all in a mirrored 'test' directory alongside our source tree, where
the
> tests are named along the lines of 'xxxxxTest.java'.   Now we want to
> start
> using Cactus and StrutsTestCase (and possibly TagUnit) to run more
complex
> tests but I'm not sure how best to split the test classes so that our
Ant
> build script can have each test framework run the relevant tests.
> 
> Any advice on the above would be appreciated as I've not found much
help
> on
> this on the web so far.
> 
> Thanks,
> 
> Andrew
> --
> Andrew Bate
> SmartStream Technologies Ltd
> Tel:  (01454) 855214
> Web:  http://www.smartstream-stp.com/
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cactus-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: cactus-user-help@jakarta.apache.org