# Web Test Troubleshooting Guide

# General (All Browsers)

# Cannot Connect To Webdriver

# Unable to run web test after running a test with browser that's not installed

Running a test configured with a browser that not installed can cause webdriver to not be released.

  1. Kill all webdriver processes (chromedriver, geckodriver or msedgedriver)
    • Windows: From the terminal run taskkill /F /IM chromedriver.exe /T replacing chromedriver.exe with geckodriver.exe if Firefox was the selected browser or msedgedriver.exe if it's Edge.
    • macOS/linux: From the terminal run pkill -f chromedriver replacing it will geckodriver if you're testing Firefox.
  2. Re-run your test using a browser you currently have installed.

# The browser is incompatible with the currently installed webdriver version

The selenium standalone process supports the latest browser version by default. If you're running an older version of browser, you'll need to upgrade it to the latest version or do some additional setup.
If you'd like to test an older browser version follow the guide here. You'll need to install the specific webdriver version for that browser version.
You'll also need to kill all active webdriver processes

# Selenium Standalone failed to download webdriver

Check your internet connection and try running the test again.

# Connection refused when running in parallel mode

A failed test can cause selenium-server to stop. There are several ways to overcome this:

  1. Start selenium server manually by running selenium-standalone start from the terminal
  2. Set up Selenium Grid for parallel testing

Note

This issues appears to have been fixed in the latest Selenium Standalone releases

# Runing test with Safari

This error occurs when your test suite hangs when finishing a test with Safari, while a popup is still open. It's Safari driver issue. While waiting for fix, we suggest the following work-around.

Environment:

WebdriverIO version: 5.18.5
Mode: WDIO Testrunner
Node.js version: v10.16.0
NPM version: 6.13.7
Safari: 13.0.5
MACOS: 10.15.3
@wdio/selenium-standalone-service: 5.16.10
Reporter: Mochawesome 4.1.0

Step to reproduce the issue:

  1. Go to a page that contains a popup.
  2. Check text of the popup.
  • The popup is still opening in Safari when the test case is finished.

  • Because of this, Webdriver cannot end the session after the test case.

  • Work-around solution: Call the "closePopup" API before the end of the test case. This will allow the test suite to finish normally.

Note

After waiting over 30 minutes, webdriver can end a session and generate a report.

# Unable to run WebDriver tests on Linux

You may encounter the following error when running WebDriver tests on Linux:
Linux web error As of March 1st 2021, Chromium Edge has not been officially released for Linux, therefore the WebdriverIO Selenium Standalone Service is currently unable to support downloading the Chromium Edge webdriver for Linux systems in a functional manner. Running WDIO Selenium Standalone Service version 6.10.3 or older can cause this issue on Linux even if you are not testing on Chromium Edge. To solve this issue, upgrade the WebdriverIO Selenium Standalone Service to a version that ignores Chromium Edge webdriver on Linux. To upgrade, follow the instructions below:

  1. Open the terminal in the project directory.
  2. Run the following command:
npm i @wdio/selenium-standalone-service@6.10.6
  1. After the installation has finished, you will be able to run the tests.

When Chromium Edge is officially released on Linux, the WebdriverIO Selenium Standalone Service may support downloading and installing the Chromium Edge webdriver. Until then, it's recommended that you upgrade to a version of WebdriverIO Selenium Standalone Service that doesn't download and install Chromium Edge.

Last Updated: 3/2/2021, 7:17:48 AM