Files
kalsport.pl/modules/ps_banner/tests/E2E
2024-11-05 12:22:50 +01:00
..
2024-11-05 12:22:50 +01:00
2024-11-05 12:22:50 +01:00
2024-11-05 12:22:50 +01:00
2024-11-05 12:22:50 +01:00
2024-11-05 12:22:50 +01:00
2024-11-05 12:22:50 +01:00

E2E tests

This folder contains tests about ps_banner module.

Supported versions

These tests can be run on 1.7.7.x and 1.7.6.x PrestaShop versions.

Stack

In these tests, we used the actual stack :

Running tests

Before running tests, you should run npm install, to install all dependencies.

Running all tests

PS_VERSION='1.7.7' URL_FO='http://localhost.com/' npm run e2e-tests 

Running all tests with fast fail mode

The fast fail mode give us the possibility to abort the run after first test failure. It uses the --bail option from mocha.

This mode is mostly used in CI (like here in Github Actions), to stop the tests as quickly as possible.

PS_VERSION='1.7.7' URL_FO='http://localhost/prestashop/' npm run e2e-tests-fast-fail

Env variables

Some variables can be used to run tests:

Parameter Description
PS_VERSION PrestaShop minor version (not patch version) (default to 1.7.7)
URL_FO URL of your PrestaShop website Front Office (default to http://localhost/prestashop/)
URL_BO URL of your PrestaShop website Back Office (default to URL_FO + admin-dev/)
BROWSER Specific browser to launch for tests (default to chromium)
HEADLESS Boolean to run tests in headless mode or not (default to true)

For more variables, please take a look on global vars on prestashop_test_lib.

Enjoy 😉 ✌️