Targets, Target Types, and Target Options

Document created by Chris Sommerstad Employee on Jul 20, 2017Last modified by Jijius Jabez on Aug 11, 2017
Version 2Show Document
  • View in full screen mode

A Target points to an application, service, mobile device and app combination, or a web site that you want to test, including its location (URL), and any authentication information necessary to successfully run a test. In most cases, SOASTA recommends that target creation be accomplished via the provided recording technique(s) for the target type. The automatically created target can then be modified to include such information as authentication credentials.

A Target also contains a specification of the information needed to properly format and send messages to the given test service, mobile app, site, or in the case of WebSocket-based sites-the site's underlying protocol. A a serves as a template for Test Clips that will be created based upon its values—fill in Target values such as inputs, outputs, and validations, and they will also appear in messages using that Target.

The Targets list shows all configured targets (including SOAP WSDL, HTTP, WebUI/Ajax and other targets) that are currently defined. The target Name, Owner, Created, and Last Modified dates are displayed. Click the column headings to sort by any given field.—either by using the Recording Editor or the Clip Editor's recording mechanism.

Users should note that most targets are and should be created by using the recording methods provided

Create a New Target

Target creation for mobile apps and WebUI targets occurs automatically, on-the-fly as part of test clip creation. Target creation for HTTP(S) clips also occurs automatically as part of conversion from recording to clip. For all types, the underlying targets can be created manually and are always accessible when creating or modifying system or custom properties. If you're not sure what the target in use is, check the Clip Editor, Included Targets list in the lower panel.

  1. Select Targets in the Central list and then click New. If a different node is selected in the Central list, click the drop-down on the New button and then select New Target.
  2. The Target Editor appears with the Target Definition Wizard, Select Target Type page active. Use this wizard to select from among the possible types of targets to define.

Note: In some CloudTest instances, an additional Database target type will also appear. Refer to Direct to Database Testing for more information about this target type and database testing. This additional test type can be enabled by your SOASTA representative (contact support@soasta.com).

  • To create an HTTP(S) target, choose HTTP and click Next. Define the HTTP Target appears.

 

Choose HTTP to test a web site at the message level. For HTTP targets intended to test load on servers, you can automatically create the target and clips using the Recorder.

For HTTP you will be asked to enter a target name, location, and any associated authentication information. Use this option for HTTPS targets as well. Note that this target can be automatically created when an HTTP(S) recording is created via the Convert Recording to Clip Wizard.

Note: In general, the best practice is to automatically create HTTP and HTTPS targets and clips using the Click Editor, Record HTTP command or using the Recording Editor (Central < Recording).

If the target requires NTLM authentication, use the following syntax:

NTLM:<realm>:<user>, where

<realm> is the Windows realm and

<user> is the actual user name. Authentication settings can be added or updated in an existing target using the Target Editor, General tab, Authentication fields.

  • To create a WSDL target, choose SOAP with a WSDL URL and click Next. Choose this option if you have a web service that uses a WSDL URL. Define the WSDL Target appears. You will need the WSDL URL (or the equivalent code) to define the SOAP WSDL target. You will also need valid credentials to connect to that service. 

Use this option if you have a web service that uses a WSDL URL.

For WSDL you will be asked to enter a target name, WSDL URL, and any associated authentication information.

  • To create a WebUI / Ajax target, choose WebUI/ Ajax and click Next. Define the WebUI / Ajax Target appears.

Choose WebUI / Ajax if you have a web site user interface to test. Note that this target can be automatically created in the Clip Editor.

For WebUI/Ajax, you will be asked to enter a target name and location.

  • To create a Native / Mobile App target, choose Native/Mobile App and click Next. Define the Native / Mobile Target appears.

Choose Native/Mobile if you have a mobile app to test. Note that this target can be automatically created in the Clip Editor.

For Native/Mobile, you will be asked to enter a target name.

Once you have supplied the target information, click Next. A summary screen appears to display data you entered. Review this information and click Finish when you're ready.

Optionally, enter additional information about the new target in the Target Editor. For example, login information that will propagate to test clips based on this target. Click Save again if you make additional changes.

  • To create a WebSocket target, choose WebSocket and click Next. Define the WebSocket Target appears.

Choose WebSocket only if you have a WebSocket interface to test. Note that this target can be automatically created in the Clip Editor by recording a site that uses the WebSocket protocol.

For WebSocket, you will be asked to enter a target name and location.

Editing Target Info

 

 

 

All CloudTest targets include the Target Info screen, which consists of two tabs: General and Custom Properties. The Target Info fields vary by target type. For HTTP and SOAP targets most of the fields below are present. For WebUI/Ajax targets most of these fields are not relevant (refer to Editing Target Info (WebUI/Ajax) below).

The General tab features are described in this section. The Custom Properties tab can be used to add custom attribute/value pairs to a target.

The Target Info page for HTTP and WSDL targets is essentially the same and consists of the following fields.

Target Info - General - General Info

The first section of the Target Info screen shows general Information about a target. The screenshot on the right shows an HTTP URL for an HTTP target. This target may have been auto-generated from an HTTP.

  • Name

The target's name as it appears in the Targets list as well as in Available Targets and Included Targets lists.

  • Description

The optional description of the target.

  • Location/WSDL/Starting URL

This field defines the location or "target" itself. The label of this field varies depending upon the type of target.

  • Location

Location for an HTTP target

  • Starting URL

Starting URL for a WebUI/Ajax target

  • WSDL

The base WSDL URL for a SOAP WSDL target or a REST target

  • Geographic Location

The value of this field will display in the Activity Maps widget as the lable for this target in that map. Refer to Interacting with Activity Maps for more information about the Activity Maps widget.

Target Info - General - Authentication

The Authentication section provides a Target user ID and password. This is crucial for target sites that require authentication.

Target Info - General - Image

The Image section provides a drop-down for selecting among Repository images. The selected image for a target will appear in the Clip Editor for all messages or actions created from this target.

Click the Choose image drop-down to select an existing Repository image. The Preview field shows the current image selection. The default HTTP image is shown on the right.

Adding an Image to the Repository

You can add new images to the CloudTest Repository from Central > Images by clicking the New button. Supported image types include JPEG, PNG, and GIF. Images can be pre-edited to the requisite 110 pixels wide by 42 pixels tall or larger images can be cropped within the New Image dialog box once selected. Images that are not cropped will be shrunk to fit within the requisite dimensions.

Target Info - General - Connection Options

The Target Info - General - Connection Options section provides additional options for defining connection options in milliseconds. Default values are shown in the unedited field. These should be left as is unless a specific case for revising them exists.

  • Socket Read Timeout

Specify the timeout for a given socket. The timeout period starts when read is called.

  • Connection Timeout

Specify the timeout for a given connection before getting a new connection.

  • Maximum Connections per Host

Specify the maximum connections per host (of those available for a given browser).

  • Maximum Total Connections

Specify the maximum total of connections.

  • Connection Refresh (in seconds)

Specify the lifetime of a given connection issued by the Connection Manager in seconds. This setting overrides the Connection Manager’s default caching behavior, which often utilizes the same connection many times during the execution of a test clip. If CloudTest gets a connection older than this limit, it obtains a “fresh” connection.

  • Connection Idle Refresh (in seconds)

Specify the lifetime of an idle connection issued by the Connection Manager. If CloudTest obtains a connection that has been idle longer than this limit, it will obtain a “fresh” connection.

Target Info - SSL Options

The SSL Options section provides settings for enabling Secure Sockets Layer and related security protocols to enable an encrypted link between the test using the given target and target server(s) to ensure privacy.

  • Enable SSL 2.0 client handshake

Check this box during target creation (or while editing an existing target) if Secure Sockets Layer (SSL) should be used to connect to the server.

  • Enable SSL 3.0

Check this box during target creation (or while editing an existing target) if Secure Sockets Layer 3.0 (SSL 3.0) should be used to connect to the server.

  • Enable TLS 1.0

Check this box during target creation (or while editing an existing target) if Transport Layer Security 1.0 (TLS 1.0) should be used to connect to the server.

  • Enable TLS 1.1

Check this box during target creation (or while editing an existing target) if Transport Layer Security 1.1 (TLS 1.1) should be used to connect to the server.

  • Enable TLS 1.2

Check this box during target creation (or while editing an existing target) if Transport Layer Security 1.2 (TLS 1.2) should be used to connect to the server. TLS 1.2 requires SOASTA 54.03 or later.

Server Name Indication (SNI) support for testing sites that use the Server Name Indication (SNI) standard is also provided in builds 54.03 and later. SNI is an extension to the TLS computer networking protocol.

Target Info - General - Content Options

The Content Options section provides settings for clearing or releasing the response to SOAP or HTTP messages based on content length as well as for specifying response encoding (e.g. character sets).

You can specify a maximum number (in bytes) for the response content. This setting can also be set per server via the Servers > Maestro service settings (for Cloud users) as well as at the individual message level in the Clip Editor. See the Advanced Settings for a selected message's general properties.

Setting International Characters in a Target

The Response Encoding setting in the Content Options section of Target Info pertains to international character sets as shown on the right.

CloudTest includes support for international character sets as defined by the HTTP META tag convention. The full list of supported character sets varies by platform. For example, such as defined in the META tag below:

<META http-equiv="Content-Type" content="text/html; charset=EUC-JP">

International character sets for a platform can be reviewed and then specified in the Target Editor, Content Options, Response Encoding drop-down.

Target Info - General - DNS Options

The DNS Options section provides the ability to set a DNS server per target, and also to specify the lookup's Time to Live (TTL), in the Target Editor. DNS Options can be used in conjunction with HttpHostOverride settings for environments where load balancing architectures are in place.

  • DNS Server – Specify the URL for the Domain Name Server this target will use. This may be different than the target URL.
  • DNSMinTTL (seconds) - Sets the minimum amount of time that any DNS result will be cached. This setting can increase the amount of time that a result would normally be cached, if it is more than the TTL specified in an actual DNS result. If 0, then result caching will be disabled completely. If -1, then results will be cached up to the amount of time specified in the DNS result, with no minimum. This setting can be used to mimic the behavior of browsers such as Internet Explorer, which cache longer than the DNS result says to cache.
  • DNS Maximum TTL (seconds) – Specify the integer, in seconds, for the maximum time to live.

These settings are also seen in the Composition Editor when track properties are in display.

Setting International Characters in a Target

The Response Encoding setting in the Content Options section of Target Info pertains to international character sets as shown on the right.

CloudTest includes support for international character sets as defined by the HTTP META tag convention. The full list of supported character sets varies by platform. For example, such as defined in the META tag below:

 

 

<META http-equiv="Content-Type" content="text/html; charset=EUC-JP">

International character sets for a platform can be reviewed and then specified in the Target Editor, Content Options, Response Encoding drop-down.

Target Info - General - Advanced Settings

The Advanced Settings section contains a check box for HTTP Binary Conversion.

For a target with this check box checked, any HTTP traffic that is binary and whose content can be converted (not all of the binary content of all responses is convertible), that content is automatically converted to XML text and the exposed content can then be viewed, validated, and values can be extracted from it.

Editing Target Info (WebUI/Ajax)

The Target Info page for WebUI/Ajax targets includes only three sections—the General and the Image section are both described above, and the Settings section (shown on the right).

  • Browser

The Browser drop-down allows selection of a browser in which WebUI/Ajax tests will be driven

  • Conductor

The Conductor drop-down allows for the selection of configured Conductors. The selected Conductor will drive the WebUI/Ajax test selected in the Browser drop-down.

Note: You must have SOASTA Conductor installed on the client machine fro which a WebUI test will be run in order for it to play.

Editing SOAP WSDL Target Fields

An example SOAP WSDL Target is shown on the right. WSDL-based targets inherit their operations from the Web Service Description itself.

Input and output fields in a WSDL target can be edited in a form while in Target Definition view. Click the WSDL tab on the lower left to edit the WSDL itself.

CloudTest includes form support for "choice" elements in WSDLs via radio buttons. This allows the user to choose an option from the choice using the form. In prior releases, it was necessary to enter the XML manually since the form did not support it.

Here is an example of a "choice":

Editing WebUI/Ajax Targets

In addition to the Target Info node, WebUI/Ajax targets include the following additional nodes:

  • Ajax Libraries

When the Ajax Libraries node is selected in the Target, the available libraries are displayed. Check any box to enable the given library.

  • Recording Options

Recording Options allow greater control on the browser actions that are captured when this target is in use during the browser recording phase in the Clip Editor. Uncheck options to suppress recording them.

  • Recorder Handlers

The Recorder Handler permits the addition of event handler functions to extend or override the default recorder behavior.

 

Useful recorder fields:

recorder.clickedElement

Set during mousedown to the target element of the clicked event (set during the mousedown because it's the first event to fire during a click or a drag and drop).s

recorder.mouseDownElement

Set during mousedown to the target element of the mousedown event.

recorder.movementString

Set during mousedown to the x.y coordinate movement string.

Useful recorder methods:

recorder.findLocators(elem)

Returns the locator string that identifies the passed in element.

recorder.record(action, locator, arg1)

Adds the specified browser action to the test clip.

  • Runtime Options

Runtime Options permit the specification of waits, timeouts, intervals, and mouse speed during the WebUI test.

  • Custom Waits/Outputs/Validations

Define target-level waits, outputs, and validations that will carry over to actions based on this target.

XPath Builders

Define XPath builder classes to facilitate web application testing by defining unique strings to precisely identify an HTML element.

  • Location Strategies

Define Location strategies by defining strings to uniquely identify HTML elements.

Setting Scope on Targets in Test Clips

Every item has scope. Targets are a special case, they can only be public or local; they cannot be private, because Targets need to be accessed by the Messages or Browser Actions in the Test Clip. Scope for the targets in a test clip can be viewed and set in the Included Targets list of the Clip Editor.

Setting an item’s scope as restrictively as possible allows CloudTest to make memory optimizations during runtime by throwing away unnecessary information.

For example, if a Message is “private”, then its response will not be accessed by another item in the Composition, and therefore we don’t have to save it and can throw away the response as soon as we receive it. Therefore, for efficiency, the scope should be set to “private” whenever possible, and set to “local” or “public” only if it really needs to be. That is why we make everything “private” by default (except for Targets, which are “local” by default since they can’t be “private”).

 

Editing Native/Mobile App Targets

Mobile targets are considerably simpler than WebUI targets, since they lack Location Strategies and many of the other Ajax-related fields required for browser-based functional tests.

Use the remaining steps to ensure that a manually-created target is used for a given Device Agent / Mobile App combination.

  1. Specify the Device Agent by name from among those configured.
  2. Specify the Mobile App to use from among those configured.

Note: Mobile apps are configured by the Mobile Administrator. If your mobile app doesn¢t appear, discuss it with your Admin.

  1. Check the Terminate app at clip completion box to ensure that the mobile app is returned to its original state at the end of the test (or between clip plays in cases where the clip is used more than once in a given test composition).
  2. Save the target after making any changes.
  • Ajax Libraries

When the Ajax Libraries node is selected in the Target, the available libraries are displayed. Check any box to enable the given library.

Attachments

    Outcomes