Scan via WebDriver

You can scan browsers, applications and debug ports by using WebDriver. In this chapter you will find information on how to scan Modules via WebDriver. For further details on how to scan modules with Tosca XScan, refer to chapter "Navigate the Tosca XScan UI".

Create Modules using WebDriver

In order to scan HTML controls using WebDriver, follow the steps below:

  1. Right-click onto a Module folder or use the dynamic menu Modules and select Scan->More->Web Driver.

  2. In the Select Application to Scan window, select if you want to scan a Browser, Application or Debug Port.

XScan - Select application to scan

  1. In the Select Application to Scan window, enter the according information for the browser, application or debug port to be scanned as described in the tables below.

  1. Select the window you want to scan and click on the Scan button, to start scanning the application.

For applications and debug ports only local scanning via WebDriver is supported.

You cannot scan headless browser instances.

Scan browser

To scan a browser define following parameters:

Select Browser to Scan options

Option

Description

Hub address

You can choose between three options:

  • Define the IP address of the grid hub, where you want the scan to happen.

  • To use BrowserStack for scanning, select the entry BrowserStack.

  • To scan locally, select the entry localhost. You can specify the path to the browser executable in the Settings dialog.

Browser

Select the browser type you want to start (Google Chrome, Mozilla Firefox, Microsoft Edge, Internet Explorer, or Safari).

Browser Version

Select the version of the browser you want to start.

OS

Select the operating system where the browser should be started.

Debug Port

Enter the debug port of an already running embedded Chromium application.

WebDriver Path

Define the path to the WebDriver file. If you don't specify a path the default location will be used.

URL

Enter the URL of the website you want to scan.

If you don't want to specify the Debug Port and the WebDriver Path every time you scan a browser, use the following settings:

  • Chrome WebDriver Path to use

  • Chrome WebDriver Port for embedded application to use

  • Edge WebDriver Path to use

  • Edge WebDriver Port for embedded application to use

For detailed information, see the list of settings for WebDriver.

Click on the Open Browser button to open the browser for scanning.

The hub will choose a node, which is able to open the browser type you specified. A new instance of the selected browser with the specified URL will be opened.

Each node on the grid hub has a maximum number of browser instances, which can be opened.

After the browser window was opened, the scan will automatically recognize it and it will show up as a scannable window in .

Note that Tosca XScan does not provide the full functionality when you scan remotely.

Scan application

To scan an application on your local machine define the following parameters:

Select Application to Scan options

Option

Description

Application Path

Define the path to the embedded Chromium application you want to start.

WebDriver Path

Define the path to the WebDriver file. If you don't specify a path the default location will be used.

URL

Enter the URL of the website you want to scan.

  • Click on the Open Application button to open the application for scanning.

Scan debug port

To scan debug port on your local machine define following parameters:

Select Application to Scan options

Option

Description

Debug Port

Enter the debug port of a already running embedded Chromium application.

WebDriver Path

Define the path to the WebDriver file. If you don't specify a path the default location will be used.

  • Click on the Connect to Port button to open the application for scanning.

Use BrowserStack

You can use BrowserStack for scanning Modules and executing your TestCases.

To use BrowserStack for scanning your Modules, follow the steps below:

  1. Specify the Access Key and the Username of the BrowserStack account and the Hub Address, which should be used for BrowserStack in the Settings dialog.

Settings dialog - BrowserStack settings

  1. In the Select Application to Scan window of the XScan, select the entry BrowserStack of the Hub address drop-down list.

  2. Click on the Start Browser button to open the browser.

After the browser window is opened, the scan will automatically recognize it and it will show up as a scannable window in the Tosca XScan.

  1. Select the window you want to scan and click the Start button, to start scanning the application.

For further details on how to scan modules with Tosca XScan, refer to chapter "Navigate the Tosca XScan UI".

When you close the XScan window, all browser instances that were previously opened via the remote XScan or the Module OpenURL with a specified hub address test configuration parameter are also closed. This includes browser windows that are opened locally as well as on any WebDriver grid node as well as on BrowserStack.