Magento 2.1.18 is the final 2.1.x release. After June 2019, Magento 2.1.x will no longer receive security patches, quality fixes, or documentation updates.
To maintain your site's performance, security, and PCI compliance, upgrade to the latest version of Magento.

Quick start. Prepare environment for test run

Run the Selenium Server on default browser

The Selenium Server drives a browser to execute your tests. You can download the Selenium Server from Selenium project website.

Install Java to work with Selenium Server.

Specific versions of the Selenium Server are compatible with specific versions of browsers. Read more about compatibility of browser version and Selenium server version.

Use Mozilla Firefox ESR 45 with Selenium 2.53.1. Later versions have compatibility issues.

Enter in terminal:

1
java -jar <path_to_selenium_directory>/selenium-server.jar

Run tests on non-default browser

If the Selenium Server does not work directly with your browser, find the corresponding web driver.

In config.xml define the browser that the FTF must use for tests.

Run the Selenium Server with an additional argument.

Example for Google Chrome with Selenium 2:

1
java -jar <path_to_selenium_directory>/selenium-server.jar -Dwebdriver.chrome.driver=<path_to_chrome_driver>/chromedriver.exe

Selenium 3

For Selenium 3 add the web driver to the directory where selenium-server.jar is located and run tests without additional argument:

1
java -jar <path_to_selenium_directory>/selenium-server.jar

Run generator

Generator generates fixtures, repositories, and page objects. Once the FTF is initialized, all classes must be pre-generated to facilitate creating and running the tests. Modules in the FTF are processed by generator in the same order that they are processed during Magento loading.

Enter in terminal:

1
cd <magento2_root_dir>/dev/tests/functional/utils
1
php generate.php

Next Steps

<< Prepare Magento application Test run >>
Updated