Scripts

Scripts form the backbone of your performance test. Your test definition can contain one or multiple scripts.

Create a script

A script is the recorded actions of a business process in your application. Your load test can contain one or more scripts. You can access downloads to supported script tools from the Home > Get tools pane.

The following table lists the tools you can use to create scripts for your load tests.

Script Tool Description  Supported Protocols Vuser Type
TruClient

TruClient is a tool for recording web-based applications as you navigate through your business process.

For details on supported browsers in TruClient, see Supported browsers.

Note:

  • TruClient 12.02 scripts and above are supported.
  • Scripts created with TruClient Firefox .xpi extension are no longer supported.
  • TruClient - Web for Firefox, Internet Explorer and Chrome
  • TruClient - Mobile Web for Firefox

GUI Vuser

TruClient Lite

TruClient Lite is an extension to the Chrome browser that uses your local installation of Chrome to develop scripts.

TruClient - Web for Chrome GUI Vuser
TruClient Record user activity in native or hybrid mobile applications using TruClient technology. The replay is performed on real devices, enabling you to gather application related measurements and test your app’s performance. To create a load test for TruClient Native mobile scripts, see Test mobile apps in StormRunner Load. TruClient Native Mobile Mobile Vuser
TruAPI
  • TruAPI is an innovative scripting tool based on node.js.
  • TruAPI enables you to create JavaScript-based Vuser scripts and provides an API for handling transactions, think time, logging, and HTTP handling.
  • TruAPI scripts can be packaged and uploaded to StormRunner Load and added to a test definition.
  Web Vuser
VuGen

 

VuGen is a tool to record web-based applications on the transport level.

For further details on protocols, see VuGen Protocols in the VuGen Help Center.

  • Web HTTP/HTML
  • Mobile Application - HTTP/HTML
  • Web Services
  • Flex

    Flex scripts can run on on-premises load generators only.

  • Java

    Java protocols are supported on Windows only.

    The following Java protocols are supported:

    • Java Record Replay
    • Java Vuser
    • Java over HTTP
  • MQTT

Web Vuser

VuGen

Use VuGen to record scripts on supported Enterprise Resource Planning (ERP) protocols.

Note: SAP-GUI and Oracle NCA protocol scripts can run on on-premises load generators only.

  • SAP-GUI

  • SAP - Web
  • Oracle NCA

  • Siebel Web

    Note:

    • Siebel Web is supported only on cloud and Windows on-premises load generators.
    • You must add the ssdtcorr.dll file to the script. For details, see Siebel Correlation.
ERP Vuser
VuGen

Use VuGen to record scripts on supported legacy protocols.

Legacy protocol scripts can run on on-premises load generators only.

  • .Net

  • Citrix ICA

Legacy Vuser
Apache JMeter

Apache JMeter is an open source performance testing tool.

  • StormRunner Load supports JMeter scripts that use HTTP Request Sampler.
  • JMeter versions 2.11 - 3.2 are supported.
  • Upload a JMeter script to StormRunner Load in .zip format.
  • Include only one .jmx file in the root folder of the .zip file.

    If the JMeter script has dependencies on third party plugins, you can include them in the lib/ext sub folder of the .zip file.

    If the JMeter script has dependencies on external .jar files (for example, JDBC drivers), you can include them in the lib sub folder of the .zip file.

    Other dependent files, for example, a *.csv file for parametrization, and folders can be added into the .zip file.

  • If your JMeter script contains multiple ThreadGroups, only one will be enabled during a test run.
  • To report transaction data, use the Transaction Controller to enclose relevant test steps.

  • If you are running this script type with on-premises load generators, you will need to install the JDK (version 8 or later).
 

Dev Vuser

Gatling

Gatling is an open source performance testing tool.

  • StormRunner Load supports Gatling scripts that use HTTP requests.
  • Gatling version 2.1.7 is supported.
  • Upload a Gatling script to StormRunner Load in .zip format.
  • If there are multiple Gatling scenarios in a simulation, only the first scenario will be executed.
  • If you are running this script type with on-premises load generators, you will need to install the JDK.

For details, see Gatling scripts in StormRunner Load.

 

Dev Vuser

Selenium

Selenium is an open source performance testing tool.

  • StormRunner Load supports Selenium scripts that use the JUnit testing framework (version 4.12).
  • Selenium version 3.2.0 is supported.
  • You can only run Selenium scripts on cloud based load generators and not on on-premises load generators.
  • Upload a Selenium script to StormRunner Load in .zip format.
  • Metrics for Throughput and Hits per Second are not supported.
  • Taking snapshots on error is not supported.

For details, see Selenium scripts in StormRunner Load.

  GUI Vuser
LeanFT

LeanFT is a powerful and lightweight functional testing solution.

  • StormRunner Load supports LeanFT scripts that use the JUnit testing framework (version 4.12).
  • LeanFT version 14 is supported.
  • StormRunner Load LeanFT scripts support the Chrome 56 browser.
  • You can only run LeanFT scripts on cloud based load generators and not on on-premises load generators.
  • Upload a LeanFT script to StormRunner Load in .zip format.
  • Metrics for Throughput and Hits per Second are not supported.
  • Taking snapshots on error is not supported.

For details, see LeanFT scripts in StormRunner Load.

  GUI Vuser

Localized script support

StormRunner Load supports scripts written in non-Latin alphabets. However, you still must use Latin characters for file and folder names.

For scripts developed prior to VuGen 12.53, do one of the following:

  • On a machine whose region locale is set to a non-Latin alphabet, open and save the script using VuGen 12.53.

  • Manually update the .usr file by adding the following setting to the General section:

    ScriptLocale=<language code>

    For details, see Language codes.

Zipped files

Upload to the repository scripts that have been manually zipped.

Back to top

Manage scripts in the repository

The cloud repository houses all the scripts that you attach to your load tests. The following table lists the actions available to manage your scripts in the repository.

Action How to
Upload
  1. Click Upload.
  2. Select a .zip file to upload to the cloud repository.

    The TruClient extension automatically saves the script as a .zip file.

    For VuGen scripts, select File > Manage Zip Files > Export to Zip File.

    Tip: Drag and drop script files to upload.

Reload

Click Reload to refresh a script in the cloud repository.

If you want to keep the script's current runtime settings and apply them to the reloaded script, select the Keep runtime settings check box.

Note:

  • You can only keep runtime settings for scripts of the same type.
  • The option to keep runtime settings is not applicable for scripts loaded from a Git repository.
Delete Click Delete to remove a script from the cloud repository.
Download Click Download to copy a script from the cloud repository to your local computer.
Runtime settings

Click Runtime Settings to view or edit a script's runtime settings.

Note: Changes made in runtime settings will affect the script in related tests.

Assign labels Assign a label to a script. For details, see Labels below.
Copy runtime settings

Copy runtime settings from one script to another:

  1. Select a script with the runtime settings you want to copy.
  2. Click the Copy runtime settings button.
  3. Select the script or scripts to be updated.

  4. Click Apply to apply the settings to the selected scripts.

Note:

  • Only scripts recorded in VuGen have runtime settings.
  • You can only copy runtime settings between scripts of the same type.
  • Only settings configured directly in the Runtime Settings dialog box, and that are common to both the source and target scripts, are copied.
  • Changes made in runtime settings will affect the script in related tests.

Back to top

Manage scripts in your Git repository

You can connect to an existing Git script repository and add those scripts to your StormRunner Load load tests.

For details, see Git integration.

Do the following to add or update a script from your Git repository to StormRunner Load:

Action How to
Access the Git repository

Click and select Upload from Git to open the Git repository dialog box.

Select an agent

From the drop-down menu, select the agent that connects to the script repository you want to use.

For details on managing your Git agents, see Agents.

Select a script

Select one or more scripts from the Git repository. Click Add.

Sync Git scripts

Do the following to sync Git scripts:

  1. Select .
  2. Click and select Sync all or Sync selected to sync your scripts with the Git repository.

View script details

The right panel displays identifying script details including script name, description, and who created and last modified it.

Related test tab

This tab displays other load tests that contain this script.

Runtime settings tab

View or edit common runtime settings for the script.

Setting Description View
Pacing

Control the time between iterations. The pace tells the Vuser how long to wait between iterations of your actions.

You can control pacing either from the Load test > Script tab or Runtime settings > Pacing view. To select which setting is applied during run time, toggle the Local pacing check box in the script's settings in the Load test > Script tab.

 

Replay Configure the replay of TruClient scripts.
Log Configure the amount and types of information that are recorded in the log.
Think time Configure the think time settings, controlling the time that a script run waits between actions. These settings are designed to help you emulate a real user.
Additional Attributes Provide additional arguments for a Vuser script. Using this view, you can pass external parameters to prepared scripts.

Miscellaneous

 

Configure snapshot generation and action on error for TruClient.

Caution: Always option is not supported.

Browser Emulation Configure the user agent and simulate browser cache for browser related runtime settings for Web HTTP,Mobile HTTP, SAP Web, Flex, and Java HTTP scripts.
Browser Configure the browser for TruClient Web scripts and the user agent for TruClient Native Mobile and TruClient Web scripts. Also configure proxy server connection settings for TruClient Native Mobile, TruClient Web, and TruClient Mobile Web scripts.
Mobile Device Enables you to change mobile device properties for TruClient Mobile Web scripts.
Timeout The maximum time to wait before failing a step.
Proxy

Configure the proxy sever connection settings for Web HTTP,Mobile HTTP, SAP Web, Flex, and Java HTTP scripts.

Note: Proxy settings are ignored by cloud based load generators.

JMS Advanced Enables you to set the JMS advanced runtime settings for Web Services scripts. For more information, see JMSTransport Overview below.
MQTT Enables you to change the MQTT runtime settings for MQTT scripts.

View snapshots

Snapshots, a visual representation of each script step, are displayed in a carousel on the right hand side of the script page. Double click the thumbnail to see the images in an enlarged view.

Note: Snapshots are currently supported only for TruClient scripts.

Back to top

Labels

Use labels to organize scripts in the repository. Labels can be nested in sub-categories:

Example:  

Version1

Feature1.1

Feature1.2

Version2

Feature2.1

Feature2.2

Do one of the following:

Action How to

Create a label

 

  1. From the Labels pane, select to open the new label dialog box.
  2. Give the label a name.
  3. If desired, nest the label under another label.
  4. Click to select a label color.
Edit a label

From the Labels pane, highlight a label.

Click and select Edit.

Delete a label

From the Labels pane, highlight a label.

Click and select Remove.

Removing a label also removes any sub-labels.

Assign a color to the label

From the Labels pane, highlight a label.

Click and select Color.

Add a sub-label

From the Labels pane, highlight a label.

Click and select Add Sub-label.

Assign a label to a script
  1. From the scripts grid, highlight one or more scripts.
  2. Expand the drop down.
  3. Select the labels to assign to the script.

Use to search for a label name.

Filter scripts by a label

Filter scripts by a specific label.

In the Labels pane, highlight the label to search for.

Use to search for a label name.

Next steps: