Getting Started with MFTF - magento/inventory GitHub Wiki
-
Disable
Add Secret Key in URLsoption inStores->Configuration->Admin->Security. -
Run the Selenium Server:
- Download the latest Selenium Server Standalone JAR.
- Download a Selenium web driver for your web browser into the same directory that contains the Selenium server.
- Add the directory with the web driver to PATH.
- Run the Selenium server in terminal (or other command line interface):
java -jar <path_to_selenium_directory>/selenium-server-standalone-<version>.jar
Below is a rough overview of the key steps outlined in the Official MFTF Dev Docs tailored to Extension Developers and the MSI project.
- Clone MSI Repo:
*
git clone https://github.com/magento/inventory.git [PATH_TO_MAGENTO_MSI] -
CD to the acceptance test directory of msi:
cd [PATH_TO_MAGENTO_MSI]/dev/tests/acceptance
- Install the dependencies:
composer install
- Build the project:
./vendor/bin/robo build:project
- Locate and Open the .env file.
- Fill in the minimal necessary details:
#Magento Base url. It should include `index.php/` if rewrites rules are not enabled. MAGENTO_BASE_URL=http://magento.url/ #Magento backend route name MAGENTO_BACKEND_NAME=admin #admin username MAGENTO_ADMIN_USERNAME=admin #admin password MAGENTO_ADMIN_PASSWORD=admin123
- Generate the tests:
./vendor/bin/robo generate:tests
- Execute the MSI group of the tests in Single Source/Stock Mode:
cd [PATH_TO_MAGENTO_MSI]/dev/tests/acceptance./vendor/bin/robo group single_mode
- Execute the MSI group of the tests in Multi Source/Stock Mode:
cd [PATH_TO_MAGENTO_MSI]/dev/tests/acceptance./vendor/bin/robo group multi_mode