...
The Extension tool allows you to implement a custom operation independently or in conjunction with your existingtest suite or Responder suite.test suite.Responder suite. This additional functionality gives you the ability to customize SOAtest and VirtualizeSOAtestVirtualize to Virtualize to your specific needs and is limited only by the capabilities of the scripting language that you are working with.
...
You can also create scripts that execute each time you startSOAtest and Virtualize.SOAtest. Virtualize. To do this, create a Jython or JavaScript script, then add it to the <INSTALL>/plugins/com.parasoft.ptest.libs.web_<VERSION>/root/startup directory.
...
Add an Extension toolusing one of the techniques described in End-to-end Test Scenarios.
Double-click the Extension tool’s Test Case Explorer or Virtual Asset ExplorerTest Case ExplorerVirtual Asset ExplorernodeAsset Explorernode. The tool configuration panel will open on the right.
- Give your method a name in the Name field.
If a return value for this tool indicates the tool’s success, select the Exit code indicates success check box. If this check box is not selected, the return value of the method is ignored regardless of whether the tool succeeded or failed.
- From the Language box, select the language that your method is or will be written in.
- Define the script to be implemented in the large text field.
- For Java methods, specify the appropriate class in the Class field. Note that the class you choose must be on your classpath (you can click the Modify Classpath link then specify it in the displayed Preferences page). Click Reload Class if you want to reload the class after modifying and compiling the Java file.
For other scripts, you can use an existing file as the source of code for your method or you can create the method in the UI.
- To use an existing file, select the File radio button and click Browse. Select the file from the file chooser that opens, then click OK to complete the selection.
To create the method in the UI from scratch, select the Text radio button and type or cut and paste your code in the associated text window.
To check that the specified script is legal and runnable, right-click the File or Text text field (click whichever one you used to specify your script), then choose Evaluate from the shortcut menu. Any problems found will be reported.
- Click Evaluate to check that the script will run (does not contain syntax errors).
- In the Error message field, specify what error message should be reported if the tool fails.
- Select the appropriate argument from the Method box at the bottom of the panel. This list will be composed of any definitions contained in your script. Since a script can contain multiple arguments, you can select the one that you want to use in this method.
...