JimL
14 years agoContributor
Automatically populate element value?
Hi,
I had posted earlier in a thread:
viewtopic.php?f=5&t=7917
where I was trying to automate population of an attribute (IssueInstant) in an outgoing SOAP request.
Per that thread, I got that working, thanks to this forum, but I'm still trying to "find my way" around with using SOAPUI and automating stuff.
Now, I want to be able to populate an element value in outgoing SOAP requests, and, in particular, would like to be able to populate that value from, for example, a list of values in a text file.
For example, if I have a text file with:
cn=foo1,dc=whatever,dc=com
cn=foo2,dc=whatever,dc=com
.
.
etc.
I'd like to be able to run a load test using a testcase, and have the load test send out the same SOAP message, but each time, both populate the IssueInstant with the current date/timestamp (got that working) and an element value (e.g., <Subject>) populated from that text file.
Can this also be done in a startup script, maybe in the load test configuration, rather than in the testcase setup?
In other words, have the startup script in the test case continue to populate the IssueInstant, but have a startup script in the load test populate the <Subject> element value from the next line in the text file?
If so, can anyone tell me what the startup script would look like (not that familiar with Groovy) and also what the property reference in the SOAP message template would look like?
Thanks,
Jim
I had posted earlier in a thread:
viewtopic.php?f=5&t=7917
where I was trying to automate population of an attribute (IssueInstant) in an outgoing SOAP request.
Per that thread, I got that working, thanks to this forum, but I'm still trying to "find my way" around with using SOAPUI and automating stuff.
Now, I want to be able to populate an element value in outgoing SOAP requests, and, in particular, would like to be able to populate that value from, for example, a list of values in a text file.
For example, if I have a text file with:
cn=foo1,dc=whatever,dc=com
cn=foo2,dc=whatever,dc=com
.
.
etc.
I'd like to be able to run a load test using a testcase, and have the load test send out the same SOAP message, but each time, both populate the IssueInstant with the current date/timestamp (got that working) and an element value (e.g., <Subject>) populated from that text file.
Can this also be done in a startup script, maybe in the load test configuration, rather than in the testcase setup?
In other words, have the startup script in the test case continue to populate the IssueInstant, but have a startup script in the load test populate the <Subject> element value from the next line in the text file?
If so, can anyone tell me what the startup script would look like (not that familiar with Groovy) and also what the property reference in the SOAP message template would look like?
Thanks,
Jim