public abstract class SimpleCompanion
extends com.itko.lisa.test.CompanionBase
implements java.io.Serializable
COMPANION_TAG, TYPE_TAG
Constructor and Description |
---|
SimpleCompanion() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getCustomParams()
This method shows if this particular companion require some custom settings to migrate
it to a companion controller.
|
ParameterList |
getParameters()
This is the base implementation of getParameters.
|
abstract java.lang.String |
getTypeName()
Override this method to provide a name for this Companion
|
void |
initialize(org.w3c.dom.Element compEl)
This method is called during the construction of a Companion.
|
protected ParameterList |
removeDuplicates(ParameterList plist)
A helper method to scrub duplicate Parameter values
|
void |
setParameters(ParameterList parameters)
Assigns the
parameters , which may contain custom parameters
and parameters injected by LISA (such as type , which indicates
the classname of the companion). |
abstract void |
testEnded(ParameterList params,
TestExec ts)
Called as LISA is ending the test.
|
void |
testEnded(TestExec ts)
Thisi is the mirror of the testStarted method; the Test has completed execution,
including sending the final event that would normally be sent to all the TestEvent
listeners.
|
protected abstract void |
testStarting(ParameterList params,
TestExec ts)
Called when LISA is about to execute the test.
|
void |
testStarting(TestExec ts)
This method is called by LISA after the TestCase has been loaded and
the state object for the given test execution has been initialized, but
before the test has begun.
|
void |
writeSubXML(java.io.PrintWriter ps) |
static void |
writeSubXML(java.io.PrintWriter ps,
ParameterList params) |
public abstract java.lang.String getTypeName()
getTypeName
in interface NamedType
public java.lang.Object getCustomParams()
CompanionInterface
getCustomParams
in interface CompanionInterface
getCustomParams
in class com.itko.lisa.test.CompanionBase
public ParameterList getParameters()
ParameterList pl = super.getParameters(); pl.addParameter( new Parameter( "New Additional Parameter: ", "mynewkey", "default" ) ); return pl;
public void setParameters(ParameterList parameters)
parameters
, which may contain custom parameters
and parameters injected by LISA (such as type
, which indicates
the classname of the companion).parameters
- this companion's parameters (custom or otherwise)protected abstract void testStarting(ParameterList params, TestExec ts) throws TestRunException
params
- - the parameters and their values that you requested by provided by the userts
- - the state object for the test that's about to startTestRunException
- if you want to prevent the test from runningpublic abstract void testEnded(ParameterList params, TestExec ts)
params
- - the same parameters given when the test startedts
- - the state object for this testpublic void testStarting(TestExec ts) throws TestRunException
CompanionInterface
testStarting
in interface CompanionInterface
ts
- is the TestExec (test execution object) that holds the current
state.
TestRunException
- when you need to report some kind of fatal error
that should halt test execution
TestExec
public void testEnded(TestExec ts)
CompanionInterface
testEnded
in interface CompanionInterface
ts
- is the TestExec object for the test that just endedpublic void initialize(org.w3c.dom.Element compEl) throws TestDefException
CompanionInterface
initialize
in interface CompanionInterface
compEl
- is the XML DOM for the FilterTestDefException
public void writeSubXML(java.io.PrintWriter ps)
writeSubXML
in class com.itko.lisa.test.CompanionBase
public static void writeSubXML(java.io.PrintWriter ps, ParameterList params)
protected ParameterList removeDuplicates(ParameterList plist)
plist
- the parameter list to scrub (remove duplicates from)plist
with duplicates removedCopyright © 1998-2014 CA, Inc. All Rights Reserved.