This topic explains how to determine which browser is used to play previously recorded scenarios. This allows you to setup cross-browser testing. For information on how to playback/execute recorded browser tests, see Executing Functional Tests.

About Browser Playback Options

By default, the browser used for recording the web scenario is also the browser used for playback, but you can configure the scenario to play back in a different browser or all available browsers. You can also create configurations that allow you to specify which browsers to use for playback at runtime.

If you want to ensure that a scenario is played only in the browser with which it was recorded, you can configure the scenario to be played only in the specified browser. This provides assurance when, for example, the web page structure is significantly different on other browsers, requiring the scenario to be constructed differently for those browsers.

Modifying Browser Playback Settings

The scenario’s browser playback settings are used during playback unless another option is explicitly selected as described in Specifying the Browser at the Time of Playback:

  1. Double-click on the scenario to open its configuration panel.
  2. Open the Browser Playback Options tab.
  3. In the Default Browser Playback section, enable the browser(s) you want the scenario to use to play the scenario back.
  4. Enable one of the following options in the Browsers Supported section: 
    • Browsers specified here only: Enable this option to ensure that the scenario is only played in the specified browser. 
    • Any browser: Enable this option to allow the scenario to be played in additional browsers that may be specified in the test configuration, in addition to the browsers specified in the scenario. 

Specifying the Browser at the Time of Playback 

You can override the scenario’s browser playback settings at the time of execution if the scenario does not have Run in specified browser only enabled by configuring your Run Configuration to use the desired browser (via Execution tab settings), then running the action suite with that Run Configuration.

  1. Select the web scenario’s Test Case Explorer node.
  2. Choose the desired Test Configuration from Parasoft > Test Using > Built-In > Functional Testing:
    • Run Web Functional Tests in All Browsers: Executes each test in all available browsers.
    • Run Web Functional Tests in Browser Specified by Tests: Executes each test using the browser playback settings configured in the test scenario’s Browser Playback Options tab. If you have multiple scenarios, each with different browser playback settings, this Test Configuration would run all the scenarios in the designated browser(s).
    • Run Web Functional Tests in Chrome: Executes each test in Chrome. If a test was configured to only run in other browsers, no testing will be performed.
    • Run Web Functional Tests in Edge: Executes each test in Microsoft Edge. If a test was configured to only run in other browsers, no testing will be performed.
    • Run Web Functional Tests in Firefox: Executes each test in Firefox. If a test was configured to only run in other browsers, no testing will be performed.
    • Run Web Functional Tests in Safari: Executes each test in Safari. If a test was configured to only run in other browsers, no testing will be performed.

  • No labels