Preface
Well, you are on the way to install the Magento Testing Framework!
Follow the next three steps:
Check pre-installation conditions
1. Install the Magento application you want to test
To install the Magento application, see Magento Installation Guide.
2. Adjust Magento application preferences
- Log in to the Magento Admin as an administrator. Example of Magento Admin URL:
http://magento.example.com/admin_1sgfym
. - On the vertical navigation bar click Stores > Configuration > Advanced > Admin > Security.
- Set Add Secret Key to URLs to No. This setting allows test to open pages using direct URLs and assures correct cURL requests.
- Go back to the vertical navigation bar of Magento Admin page.
- Click Stores > Configuration > General > Content Management > WYSIWYG Options.
- Set Enable WYSIWYG Editor to Disabled Completely to enable you to work with Selenium. You can change the setting later after you鈥檙e finished testing.
3. Check if all required software installed and configured
PHP
For more details about PHP verification, installation and configuration (Ubuntu, CentOS).
In php.ini
file, make sure extension=php_openssl.dll
is not commented out.
Check if the Magento Testing Framework has been already installed
- Find directory
<magento2>/dev/tests/functional/
. - Find the
vendor
directory. If the directory exists, you already have the Magento Testing Framework installed invendor/magento/mtf
.
Perform the installation
The Magento Testing Framework requires Composer, which downloads libraries defined in <magento2>/dev/tests/functional/composer.json
.
If you're not sure that Composer is installed, see Install Composer.
- Open a command prompt.
- Log in to your Magento server as a user with permissions to modify the Magento file system. (This is typically the Magento file system owner.)
cd <magento2>/dev/tests/functional/
composer install
If command failed, maybe Composer hasn't been installed globally.
Copy composer.phar
to /usr/local/bin/composer
.
To run it locally put composer.phar
into directory, where composer.json
file is located (that is, <magento2>/dev/tests/functional/
).
And run from this directory php composer.phar install
.
Check the installation
Find the Magento Testing Framework directory
Check whether the vendor
directory exists in <magento2>/dev/tests/functional/
.
cd <magento2>/dev/tests/functional/
ls
Find the mtf
directory.
cd vendor/magento
ls
Verify the Magento Testing Framework version
Open <magento2>/dev/tests/functional/vendor/magento/mtf/CHANGELOG.md
. The latest version in CHANGELOG.md
is version of the MTF you installed.
Find us on