Scale your test from VS Code

You can use LoadRunner Developer, together with any IDE, to scale up your DevWeb tests on LRC and LRE. This topic describes working with the Visual Studio Code (VS Code) IDE.

For information on using predefined tasks for DevWeb tests in VS Code, see Scripting with Visual Studio Code.

Set up a task in VS Code

The LoadRunner Developer ScaLRD tool works with VS Code. Use the tool to set up a tasks.json file to run your DevWeb script.

Tip: A predefined tasks.json template for VS Code is provided for use with LoadRunner Developer. The template is based on running a test on LRC, and is available here: <DevWeb root folder>\examples\VsCodeTemplate

To set up a task for ScaLRD in VS Code:

  1. Create your DevWeb script, and test it in LoadRunner Developer.
  2. Open the script in VS Code.
  3. Either open an existing tasks.json file, or add a new task.

    To add a new task:

    1. Select Terminal > Configure Tasks (in older versions of VS Code, select Tasks > Configure Tasks).  
    2. Select Create tasks.json file from template from the task list.
    3. In the Select a Task Template list, select Others. VS Code creates a tasks.json file as a basic template.
  4. Add the relevant content to the tasks.json file, as follows:

    Property name Value
    task Define your own label to identify the task.
    type Define as shell.
    panel Define as new. Every run will be in a new panel.
    <Platform> You can run the task on Windows, Mac, or Linux OS (windows, osx, linux).
    command Define the path to the ScaLRD executable file, for the specified platform.
    args Add the path to the relevant script folder, and the flags you want to include (these flag definitions override the settings in the lrc_uploader.yml or lre_uploader.yml file).

    Example (for LRC):

  5. Save the file.

Back to top

Run a test from VS Code

When you run the task that you defined in VS Code, your DevWeb script is uploaded and executed in LRC or LRE.

To run the test:

  1. In VS Code, select Terminal > Run Task.
  2. In the Select the task to run list, select your task (the label you defined previously).
  3. In the displayed list of options, select Continue without scanning the task output. The task starts running, and the script is uploaded to LRC or LRE. Progress is displayed in the Terminal pane.

  4. A brief replay summary is displayed, providing information on the run and a transaction summary. It also provides the path to the report, containing the full details and graphs for the test run.

    Example:

Back to top

See also: