Environment variables for a Web-based environment

You can use predefined environment variables to specify the applications or browsers you want to use for your test. This can be useful if you want to test how your application works in different environments.

Note: For details on environment variables and how to use them in tests, see Environment variables for record and run settings.

To use environment variables to define the Web browser and URL to open, set the appropriate variable names as specified below:

Option

Variable Name

Description

Type

BROWSER_ENV

The browser program to open. For example, Microsoft Internet Explorer, Google Chrome, or Mozilla Firefox.

Possible values:

IE. Opens Internet Explorer.

IE64. Opens a 64-bit version of Internet Explorer.

CHROME. Opens Google Chrome.

FIREFOX. Opens the latest version of Mozilla Firefox that is both installed on the computer and supported by UFT.

FIREFOX64. Opens the latest version of 64-bit Mozilla Firefox that is both installed on the computer and supported by UFT.

FF<VersionNumber>. Opens the specified version of Mozilla Firefox. For example: FF36 (version 3.6), FF40 (version 4.0), FF140 (version 14.0).

SAFARI. Opens Safari on the remote Mac computer connected to UFT (defined in the Web tab of the Record and Run Settings dialog box or in the REMOTE_HOST environment variable).

EDGE. Opens the locally installed version of Microsoft Edge loaded with the Edge Agent for Functional Testing.

CHROME_EMULATOR: Opens the Chrome emulator with the specified device as entered in the EmulatedDevices.xml file (found in the <UFT installation folder>/bin folder)

PHANTOMJS: Runs the test on the locally installed version of the PhantomJS toolkit.

Address

URL_ENV

The Web address to display in the browser.

Remote Host

REMOTE_HOST

The host name or IP address of the Mac computer to which UFT connects.

By default, UFT connects to the Mac using port 8822. To use a different port, append the port number to the host name: <hostname>:<port number>.

Make sure to configure the same port number on the Mac, in the UFT port option in the UFT Connection Agent preferences.

For more details, see Connect to a remote Mac computer.

Relevant only for running tests and components on the Apple Safari browser.

use SSL flag USE_SSL

Specifies whether to secure the connection to the Mac computer by using SSL for the connection.

Possible values:

  • TRUE

  • FALSE (Default)

Relevant only for running tests and components on the Apple Safari browser.