|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.opencms.test.OpenCmsThreadedTestCaseSuite
public class OpenCmsThreadedTestCaseSuite
Allows to run a specific method of an OpenCmsTestCase
case concurrently.
Field Summary | |
---|---|
static CmsObject |
PARAM_CMSOBJECT
A not-initialized OpenCms user context. |
static Integer |
PARAM_COUNTER
A not-initialized OpenCms user context. |
Constructor Summary | |
---|---|
OpenCmsThreadedTestCaseSuite(int count,
OpenCmsTestCase testCase,
String method,
Object[] parameters)
Generates a new threaded test case suite with the selected test case method. |
Method Summary | |
---|---|
long |
getAllowedRuntime()
Returns the maximum allowed runtime of this test suite. |
long |
getRuntime()
Returns the runtime of this test suite. |
Throwable |
getThrowable()
Returns the error that that may have been caused while initializing or running this suite, or null in case no error was thrown. |
OpenCmsThreadedTestCase[] |
run()
Runs the initialized test concurrent test cases. |
void |
setAllowedRuntime(long allowedRuntime)
Sets the maximum allowed runtime of this test suite. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final CmsObject PARAM_CMSOBJECT
public static final Integer PARAM_COUNTER
Constructor Detail |
---|
public OpenCmsThreadedTestCaseSuite(int count, OpenCmsTestCase testCase, String method, Object[] parameters)
The parameters
array may contain the following placeholders:
PARAM_CMSOBJECT
: This will be replaced by a new CmsObject
instance.
PARAM_COUNTER
: This will be replaced by an integer counter with the number of the generated thread
count
- the number of concurrent test cases to executetestCase
- the test case class to usemethod
- the method to execute on the test caseparameters
- the parameter values for the methodMethod Detail |
---|
public long getAllowedRuntime()
If the given limit is exceeded, then this suite will stop waiting for the running test cases to finish and generate an internal exception.
The default is the number of threads multiplied by 100 milliseconds.
public long getRuntime()
public Throwable getThrowable()
null
in case no error was thrown.
null
in case no error was thrownpublic OpenCmsThreadedTestCase[] run()
Returns the array of generated OpenCmsThreadedTestCase
instances, which contain information
about the individual test results.
*
OpenCmsThreadedTestCase
instancespublic void setAllowedRuntime(long allowedRuntime)
allowedRuntime
- the maximum allowed runtime of this test suite to set
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |