Suncrusher
4 years agoNew Contributor
LoadTest - setup script - set properties
Hi, I want to initialize a JSON database with some dynamic values before the load test really starts. When accessing the properties I can't read the values. Here is what I have so far: ...
- 4 years ago
Seems that this value can only be read but not changed. Via this code I could extract the value:
def project = loadTestRunner.getLoadTest().getTestCase().getTestSuite().getProject(); log.info("loadTestRunner - loadTest: " + loadTestRunner.getLoadTest().getTestCase().getLabel()); for (String key : loadTestRunner.getLoadTest().getTestCase().properties.keySet()) { log.info("propertiesMap value: " + key); log.info("Value: " +loadTestRunner.getLoadTest().getTestCase().properties[key]); def prop = loadTestRunner.getLoadTest().getTestCase().properties[key]; log.info("internal value: " + prop.getProperties()["value"]); }
Here is a 10 years old version of this class: https://github.com/oysteing/soapui/blob/master/src/java/com/eviware/soapui/impl/wsdl/support/XmlBeansPropertiesTestPropertyHolder.java