Working with TruClient 2.0

TruClient 2.0 - Web scripts are created using the TruClient 2.0 engine, which has its own distinctive user interface and script structure.

TruClient user interface

TruClient scripts are developed using the TruClient Development window. The Development window presents the script steps graphically in a sidebar, next to the browser window for your selected browser.

For details on the components of the Development window, see TruClient 2.0 Development window.

Back to top

Developing a script

You create a script by recording, replaying, and enhancing the script in the Development window. These activities are not separate. For example, to solve a problem found while debugging during replay, you might enhance the script by making some steps conditional, or by recording additional steps in the script.

When you are developing a TruClient script within the Development window, this is referred to as working in interactive mode.

Record

TruClient records your actions while you perform a business process on the selected browser. When you stop recording, TruClient converts your actions into steps, and saves snapshots of the system states.

For details, see Record a TruClient 2.0 script.

Replay

You must replay your script at least once so TruClient can perform some background tasks. You will probably replay more than once, while you debug the script.

For details, see Replay TruClient 2.0 scripts.

Enhance

TruClient records exactly the actions that you take. However, when testing you may want the test to run differently than you recorded it. For example, you may want to run some steps only if a condition is true, or to vary the data you enter in the application.

In addition, the data collected may not be what you need. You may need to collect performance data separately on different steps or different groups of steps, rather than on the entire business process.

For details, see Enhance a TruClient 2.0 script.

Code

TruClient provides functionality to implement advanced scripting requirements for your scripts.

For details, see Program in TruClient and TruClient API Help.

Load test

TruClient 2.0 - Web scripts can be used for performance and load tests in multiple OpenText tools, including LoadRunner Professional, LoadRunner Enterprise, and LoadRunner Cloud. They can be run on Windows-based or Linux Ubuntu-based load generators.

For load testing tips, see Load tests with TruClient scripts.

Back to top

TruClient script structure

All TruClient scripts contain the following elements:

Steps

Steps are structures that contain a user action to perform, object identification, the point where the next step can start, and other data.

There are several types of steps. Step type examples include:

  • One user action and the application response.
  • A function call.
  • A flow statement that may contain other steps. For example, a for loop.

For details, see Manage step data in TruClient 2.0.

Actions

An action contains a series of steps you want to test as a sequential set. An action generally corresponds to a business process for your application, that is, a task users might perform. A business process can be very short and specific, like logging in, or larger, like a sequence that starts with a search and ends with a purchase.

For details, see Actions for TruClient 2.0 scripts.

Run Logic

The flow of your script, meaning the order actions run in and the number of times they run.

For details, see Run logic for TruClient 2.0 scripts.

You can think of steps as program statements, actions as sub-routines, and the run logic as the main routine.

Back to top

See also: