Forum Discussion

DyHex's avatar
DyHex
New Contributor
7 years ago
Solved

One REST request step for running multiple variations

Hi, I'm pretty new to SoapUI Pro, been using it for about 2 months now. I like it but I'm sad to say I'm already staring to feel a little limited by it. Hopefully it's just me not utilizing the tool well enough, so here's the question: 

 

Is it possible to have a single REST request test step run multiple variations of a given request, by passing it the variables needed for headers, attribute fields in the request body each? 

 

The idea behind this is that I would only have one test step to edit if and when the developers changes some structure or functionality in the api. As right now I have quite a few very similar test steps with only small alterations between them, but if there where to come a change in the API I risk having to edit over 100 tests manually if not more.  

 

Thanks!

5 Replies

  • DyHex's avatar
    DyHex
    New Contributor

    Thanks! 
    A follow up question. Could you also do this through Groovy scripting and if you can, is there a reason why you wouldn't want to just use groovy to script every test?

    • nmrao's avatar
      nmrao
      Champion Level 3
      Sorry I am not if I got your question right.

      Of course, it is possible to use data driven test using Groovy script in SoapUI Open Source and you should be able to find example online.

      For SoapUI Pro users, software provides Data Driven feature out-of-the-box.
  • DyHex's avatar
    DyHex
    New Contributor

    No, you answered both my questions, thanks!

    As a side question, I'm just curious as to the pros and cons of using Groovy over the built in functionality in soap? 

    • nmrao's avatar
      nmrao
      Champion Level 3
      If some has got Pro licence, there is no need to write our own script, test it or have bugs in the script as one would get that as part of tested software. One can spend that time to automate more cases instead.

      For Open Source software users, they have no choice, have to write or get it online sample and adopt it to as per our needs.