SPA-CSW
12 years agoNew Contributor
[Resolved] Create rrequest xml tags with data driven testing
Hi,
I'm currently implementing some data driven tests and i want to dynamically create some xml tags based on the data that comes from the excel file.
For example, if i have data in a specific excel column i want to sent the xml tag with that data, if that column does not have data i do not want to send that specific xml tag in the request.
How can i implement this behavior?
SoapUI Pro already has some functionality that can deal with this type of situations?
Thanks a lot in advance
I'm currently implementing some data driven tests and i want to dynamically create some xml tags based on the data that comes from the excel file.
For example, if i have data in a specific excel column i want to sent the xml tag with that data, if that column does not have data i do not want to send that specific xml tag in the request.
How can i implement this behavior?
SoapUI Pro already has some functionality that can deal with this type of situations?
Thanks a lot in advance
- I've managed to solve the problem.
Basically I used the SoapUI Pro event (RequestFilter.filterRequest), and implemented a simple groovy script that filters the requests before they are sent to the server. So the request is created based on the data that i have in the excel sheet and then the event deletes the xml tags that I don't want to send.
I created two different event scripts, one for individual XML tags and other for xml nodes. With this approach is possible to have only one xml request template and the users can test all the combinations changing only the data in the excel file.