On 11/24/06, Raphaël Piéroni <[EMAIL PROTECTED]> wrote:
Where could i find information about TestSetup and example in shale,
i have searched in the shale source repository, but can't find it.
TestSetup is a JUnit thing, so consult JUnit docs and tutorials for
info on that. Generally, the usual setUp/tearDown methods in a test
case run before and after every test. Obviously, starting and
stopping the container once for each testXxx method would take
forever. A TestSetup class allows you to run setUp and tearDown
methods once for an entire suite of tests.
The link in my previous message was straight to CargoTestSetup in the
Apache svn repo, so... try that again.
It was in the 1.0.3 release, so you can add a dependency:
<dependency>
<groupId>org.apache.shale</groupId>
<artifactId>shale-test</artifactId>
<version>1.0.3</version>
<scope>test</scope>
</dependency>
(Shale Test doesn't have any required dependencies on JSF, so you can
use it with any project. In addition to the CargoTestSetup class,
there's also a convenience HtmlUnit base test class.)
It's used in the shale-usecases example app:
http://svn.apache.org/repos/asf/shale/framework/trunk/shale-apps/shale-usecases/
for example
http://svn.apache.org/repos/asf/shale/framework/trunk/shale-apps/shale-usecases/src/test/java/org/apache/shale/usecases/systest/ViewControllerTestCase.java
The pom config for shale-usecases is somewhat... complex since we keep
the integration tests and the unit tests in the same module, but you
can see how we pass in the System properties that CargoTestSetup
needs.
Please come join us on [EMAIL PROTECTED] if you have more questions...
http://shale.apache.org/mail-lists.html
--
Wendy
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]