All Products
Search
Document Center

Performance Testing:Use a loop instruction

Last Updated:Nov 01, 2024

Loop instructions allow you to call APIs or run instructions for a specific number of times to simulate real business traffic. For example, you can enable loop logon and loop browsing. This topic describes how to add a loop instruction.

Procedure

  1. Log on to the PTS console, choose Performance Test > Create Scenario, and then click PTS.

  2. Configure the basic request parameters of an HTTP API. For more information, see Basic request parameters.

  3. In the Business Session section, click the Add Instruction drop-down list and select Loop.

  4. Expand Loop and configure the Number of Loops parameter.

    All actions involved between the Loop Starts and Loop Ends process are cyclically executed based on the value of the Number of Loops parameter. Valid values: 0 to 10. You can go to the next API only after the loop on the current API is closed.

    image

  5. Configure other APIs based on your business requirements.