Class TestSequence
java.lang.Object
com.sun.ts.tests.common.webclient.TestSequence
- All Implemented Interfaces:
- TestCase
This class represents a logic sequence for executing a series of test cases in a specific order. In this case, the
 execution order will be the same order that the test cases were added to the sequence.
 The 
TestSequence has the added benefit of managing state between the test invocations.- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddTestCase(String identifier, TestCase cs) Adds a test case to the sequence denoted by a unique identifier.voidenableStateManagement(boolean value) enableStateManagement, when enabled, will cause the test sequence to manage state between test case invocations.voidexecute()Executes the test sequence.getName()Returns the name of this TestSequence.getState()Returns the state of the sequence.booleanReturns a value indicating whether state management is enabled or not.voidremoveTestCase(String identifier) Removes a test case from the sequence.voidSets the name of this TestSequence.voidSets the initial state for the test sequence to use when invoking test cases.
- 
Constructor Details- 
TestSequencepublic TestSequence()Creates a new instance of TestSequence
 
- 
- 
Method Details- 
executeExecutes the test sequence.- Specified by:
- executein interface- TestCase
- Throws:
- TestFailureException- if any test in the sequence fails.
 
- 
enableStateManagementpublic void enableStateManagement(boolean value) enableStateManagement, when enabled, will cause the test sequence to manage state between test case invocations. By default, a test sequence will not manage state.- Parameters:
- value- a value of true enables session management.
 
- 
isStateManagementEnabledpublic boolean isStateManagementEnabled()Returns a value indicating whether state management is enabled or not.- Returns:
- boolean value indicating state management status
 
- 
addTestCaseAdds a test case to the sequence denoted by a unique identifier.- Parameters:
- identifier- for this test case
- cs- the test case
 
- 
removeTestCaseRemoves a test case from the sequence.- Parameters:
- identifier-
 
- 
setNameSets the name of this TestSequence. If not set, the default value is "DEFAULT".
- 
getNameReturns the name of this TestSequence.
- 
setStateSets the initial state for the test sequence to use when invoking test cases.
- 
getStateReturns the state of the sequence. Note: This value can differ depending on when it has been called in relation to when execute has been called.
 
-