|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
org.apache.tools.ant.taskdefs.optional.testing.Funtest
public class Funtest
Task to provide functional testing under Ant, with a fairly complex workflow of:
| Field Summary | |
|---|---|
static java.lang.String |
APPLICATION_EXCEPTION
Application exception : "Application Exception" |
static java.lang.String |
APPLICATION_FORCIBLY_SHUT_DOWN
"Application forcibly shut down" |
static java.lang.String |
SHUTDOWN_INTERRUPTED
"Shutdown interrupted" |
static java.lang.String |
SKIPPING_TESTS
"Condition failed -skipping tests" |
static java.lang.String |
TEARDOWN_EXCEPTION
Teardown exception : "Teardown Exception" |
static java.lang.String |
WARN_OVERRIDING
"Overriding previous definition of " |
| Fields inherited from class org.apache.tools.ant.Task |
|---|
target, taskName, taskType, wrapper |
| Fields inherited from class org.apache.tools.ant.ProjectComponent |
|---|
description, location, project |
| Constructor Summary | |
|---|---|
Funtest()
|
|
| Method Summary | |
|---|---|
void |
addApplication(Sequential sequence)
Add an application. |
void |
addBlock(BlockFor sequence)
Add a block. |
void |
addReporting(Sequential sequence)
set reporting sequence of tasks. |
void |
addSetup(Sequential sequence)
Add a setup sequence. |
void |
addTeardown(Sequential sequence)
set teardown sequence of tasks. |
void |
addTests(Sequential sequence)
add tests. |
ConditionBase |
createCondition()
Add a condition element. |
void |
execute()
Run the functional test sequence. |
BuildException |
getApplicationException()
Get the application exception. |
BuildException |
getTaskException()
Get the task exception. |
BuildException |
getTeardownException()
Get the teardown exception. |
BuildException |
getTestException()
Get the test exception. |
protected void |
ignoringThrowable(java.lang.String type,
java.lang.Throwable thrown)
log that we are ignoring something rather than rethrowing it. |
protected void |
processExceptions()
Now faults are analysed. |
void |
setFailOnTeardownErrors(boolean failOnTeardownErrors)
Set the failOnTeardownErrors attribute. |
void |
setFailureMessage(java.lang.String failureMessage)
Set the failureMessage attribute. |
void |
setFailureProperty(java.lang.String failureProperty)
Set the failureProperty attribute. |
void |
setShutdownTime(long shutdownTime)
Set the shutdownTime attribute. |
void |
setShutdownUnit(WaitFor.Unit unit)
Set the shutdownunit attribute. |
void |
setTimeout(long timeout)
Set the timeout attribute. |
void |
setTimeoutUnit(WaitFor.Unit unit)
Set the timeoutunit attribute. |
| Methods inherited from class org.apache.tools.ant.Task |
|---|
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType |
| Methods inherited from class org.apache.tools.ant.ProjectComponent |
|---|
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String WARN_OVERRIDING
public static final java.lang.String APPLICATION_FORCIBLY_SHUT_DOWN
public static final java.lang.String SHUTDOWN_INTERRUPTED
public static final java.lang.String SKIPPING_TESTS
public static final java.lang.String APPLICATION_EXCEPTION
public static final java.lang.String TEARDOWN_EXCEPTION
| Constructor Detail |
|---|
public Funtest()
| Method Detail |
|---|
public ConditionBase createCondition()
ConditionBase.public void addApplication(Sequential sequence)
sequence - the application to add.public void addSetup(Sequential sequence)
sequence - the setup sequence to add.public void addBlock(BlockFor sequence)
sequence - the block for to add.public void addTests(Sequential sequence)
sequence - a sequence to add.public void addReporting(Sequential sequence)
sequence - a reporting sequence to use.public void addTeardown(Sequential sequence)
sequence - a teardown sequence to use.public void setFailOnTeardownErrors(boolean failOnTeardownErrors)
failOnTeardownErrors - the value to use.public void setFailureMessage(java.lang.String failureMessage)
failureMessage - the value to use.public void setFailureProperty(java.lang.String failureProperty)
failureProperty - the value to use.public void setShutdownTime(long shutdownTime)
shutdownTime - the value to use.public void setTimeout(long timeout)
timeout - the value to use.public void setTimeoutUnit(WaitFor.Unit unit)
unit - the value to use.public void setShutdownUnit(WaitFor.Unit unit)
unit - the value to use.public BuildException getApplicationException()
public BuildException getTeardownException()
public BuildException getTestException()
public BuildException getTaskException()
public void execute()
throws BuildException
execute in class TaskBuildException - if something was caught during the run or teardown.protected void processExceptions()
The priority is
protected void ignoringThrowable(java.lang.String type,
java.lang.Throwable thrown)
type - name of exceptionthrown - what was thrown
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||