public class TestcaseUtilities
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected static java.lang.String |
copyright
IBM Copyright
|
protected static java.lang.String |
sccsid
Version information
|
Constructor and Description |
---|
TestcaseUtilities() |
Modifier and Type | Method and Description |
---|---|
static void |
addTestDataToDatapool(java.lang.String dataPoolLocation,
java.util.List<TestData> testDataList,
boolean isOverwrite)
Add test data to a data pool
|
static void |
addTestDataToTestcase(java.lang.String testcaseLocation,
java.util.List<TestData> testDataList)
Add test data to a test cases data pool
|
static void |
createNewDataPool(java.lang.String dataPoolLocation,
java.util.List<TestData> testDataList)
Creates a new data pool file containing the list of test data
|
static void |
createNewTestCase(java.lang.String shlib,
java.lang.String testcaseName,
java.lang.String datapool,
java.lang.String msgFlow,
java.lang.String desc)
Create a new .testcase file
|
static TestData |
getTestData(TestDataType testDataType)
Get a TestData object suitable for injection into a flow from an unmarshalled TestDataType
|
static TestDataType |
getTestDataType(TestData testData)
Get a TestDataType object for marshalling from a TestData object retrieved from captured test data
|
static DataPoolType |
loadDataPoolFile(java.lang.String dataPoolLocation)
load an existing data pool xml file
|
static TestcaseType |
loadTestcaseFile(java.lang.String testcaseLocation)
load an existing .testcase file
|
static void |
saveDataPool(java.lang.String dataPoolLocation,
DataPoolType dataPool)
Saves an existing data pool to file
|
static void |
saveTestcase(java.lang.String testcaseLocation,
TestcaseType testcase)
Saves an existing testcase to file
|
protected static final java.lang.String copyright
protected static final java.lang.String sccsid
public static TestcaseType loadTestcaseFile(java.lang.String testcaseLocation) throws java.io.IOException, javax.xml.bind.JAXBException
testcaseLocation
- - the full path to the testcase filejavax.xml.bind.JAXBException
java.io.IOException
public static DataPoolType loadDataPoolFile(java.lang.String dataPoolLocation) throws javax.xml.bind.JAXBException, java.io.IOException
dataPoolLocation
- - the full path of the data pool filejavax.xml.bind.JAXBException
java.io.IOException
public static void createNewTestCase(java.lang.String shlib, java.lang.String testcaseName, java.lang.String datapool, java.lang.String msgFlow, java.lang.String desc) throws javax.xml.bind.JAXBException, java.io.IOException
shlib
- - the full destination foldertestcaseName
- - the name of the testcasedatapool
- - the full path to the associated datapool filemsgFlow
- - the message flow required by this testcasedesc
- - A description of the testcasejavax.xml.bind.JAXBException
java.io.IOException
public static void createNewDataPool(java.lang.String dataPoolLocation, java.util.List<TestData> testDataList) throws javax.xml.bind.JAXBException, java.io.IOException
dataPoolLocation
- - the full path of the data pool xml filetestDataList
- - list of test data to add to data pooljavax.xml.bind.JAXBException
java.io.IOException
public static void saveTestcase(java.lang.String testcaseLocation, TestcaseType testcase) throws java.io.IOException, javax.xml.bind.JAXBException
testcaseLocation
- - the full path of the destination filetestcase
- - the testcase to savejava.io.IOException
javax.xml.bind.JAXBException
public static void saveDataPool(java.lang.String dataPoolLocation, DataPoolType dataPool) throws javax.xml.bind.JAXBException, java.io.IOException
dataPoolLocation
- - the full path to the data pool filedataPool
- - The data pool to savejavax.xml.bind.JAXBException
java.io.IOException
public static void addTestDataToTestcase(java.lang.String testcaseLocation, java.util.List<TestData> testDataList) throws java.io.IOException, javax.xml.bind.JAXBException
testcaseLocation
- - the full path of the testcase filetestDataList
- - a list of test data to addjava.io.IOException
javax.xml.bind.JAXBException
public static void addTestDataToDatapool(java.lang.String dataPoolLocation, java.util.List<TestData> testDataList, boolean isOverwrite) throws java.io.IOException, javax.xml.bind.JAXBException
dataPoolLocation
- - the full path of the data pool filetestDataList
- - a list of test data to addjava.io.IOException
javax.xml.bind.JAXBException
public static TestDataType getTestDataType(TestData testData)
testData
- - test data from captured test datapublic static TestData getTestData(TestDataType testDataType)
testDataType
- - unmarshalled test data