MinervaNeue/tests/selenium
Jdlrobson dac9039246 Revert "Beta mode cookie must be set on mobile domain"
This reverts commit 1903d1adae.
This didn't actually solve the problem.

Change-Id: Ic789e96dcc17268abe3690647e1d82a764491646
2019-04-10 20:28:17 +00:00
..
features Revert "Beta mode cookie must be set on mobile domain" 2019-04-10 20:28:17 +00:00
specs Revert "Beta mode cookie must be set on mobile domain" 2019-04-10 20:28:17 +00:00
.eslintrc.json Adding initial webdriver.io test 2019-04-08 16:05:22 -07:00
README.md Adding initial webdriver.io test 2019-04-08 16:05:22 -07:00
wdio.conf.cucumber.js Adding initial webdriver.io test 2019-04-08 16:05:22 -07:00
wdio.conf.js Adding initial webdriver.io test 2019-04-08 16:05:22 -07:00

README.md

Selenium tests

Please see tests/selenium/README.md file in mediawiki/core repository, usually at mediawiki/vagrant/mediawiki folder.

Setup

Set up MediaWiki-Vagrant:

cd mediawiki/vagrant
vagrant up
vagrant roles enable minerva
vagrant provision
cd mediawiki
npm install

Start Chromedriver and run all tests

Run both mediawiki/core and extension tests from mediawiki/core repository (usually at mediawiki/vagrant/mediawiki folder):

npm run selenium

Start Chromedriver

To run only some tests, you first have to start Chromedriver in one terminal tab (or window):

chromedriver --url-base=wd/hub --port=4444

Run test(s) from one file

Then, in another terminal tab (or window) run this from mediawiki/core repository (usually at mediawiki/vagrant/mediawiki folder):

npm run selenium-test -- --spec tests/selenium/specs/FILE-NAME.js

wdio is a dependency of mediawiki/core that you have installed with npm install.

Run specific test(s)

To run only test(s) which name contains string TEST-NAME, run this from mediawiki/core repository (usually at mediawiki/vagrant/mediawiki folder):

./node_modules/.bin/wdio tests/selenium/wdio.conf.js --spec extensions/EXTENSION-NAME/tests/selenium/specs/FILE-NAME.js --mochaOpts.grep TEST-NAME

Make sure Chromedriver is running when executing the above command.