Forum Discussion
nmrao
10 years agoChampion Level 3
You can have do it with setup script for the test case.
1. Define a test case level property say PROPERTY_FILE_NAME and have absolute path of property file.
2. For the test case, do a double click, you can see Setup Script. Have below script.
This script will run each time when test case is invoked.
1. Define a test case level property say PROPERTY_FILE_NAME and have absolute path of property file.
2. For the test case, do a double click, you can see Setup Script. Have below script.
def props = new Properties()
new File(context.expand('{#TestCase#PROPERTY_FILE_NAME}')).withInputStream {
stream -> props.load(stream)
}
props.each {
testCase.setPropertyValue(it.key,it.value)
}
This script will run each time when test case is invoked.
Related Content
- 10 months ago
Recent Discussions
- 15 years ago