Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.
How do I use scripts to send random numeric values

LegacyForum
Posts: 1,664 ✭✭
as part of the SOAP request?
- Select the SOAP Client node you would like to configure.
- In the Parameters section of the right GUI panel, select Method from the Value drop-down menu.
- Click the User Method Properties button. The User Method Properties dialog box displays.
- Enter the following script in the Text box.
# Creates a a random integer in the range [0, 10].
from java.util import Random
randomGenerator = Random()
def getRandom():
return randomGenerator.nextInt(10)
0