mediawiki-extensions-Relate.../tests/selenium
jdlrobson daa7281381 QA: Move LocalSettings to folder with other browser tests
Depends-On: Ib069004f8dcb76550fe96a6544f2846d4a7af1b9
Bug: T164024
Change-Id: Iaae9709b7407738850cdfc47c7ff56cc6eb2b1ca
2017-08-14 15:33:36 +02:00
..
pageobjects Replace Ruby Related pages browser tests with node js version 2017-07-26 11:41:07 +00:00
specs Replace Ruby Related pages browser tests with node js version 2017-07-26 11:41:07 +00:00
.eslintrc.json Replace Ruby Related pages browser tests with node js version 2017-07-26 11:41:07 +00:00
LocalSettings.php QA: Move LocalSettings to folder with other browser tests 2017-08-14 15:33:36 +02:00
README.md Replace Ruby Related pages browser tests with node js version 2017-07-26 11:41:07 +00:00

Selenium tests

Please see tests/selenium/README.md file in mediawiki/core repository.

Usage

Set up MediaWiki-Vagrant:

cd mediawiki/vagrant
vagrant up
vagrant roles enable mobilefrontend relatedarticles
vagrant provision

From mediawiki/core folder:

echo 'include_once "$IP/extensions/RelatedArticles/tests/browser/LocalSettings.php";' >> LocalSettings.php

Run both mediawiki/core and RelatedArticles tests from mediawiki/core folder:

npm run selenium

To run only RelatedArticles tests in one terminal window or tab start Chromedriver:

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

In another terminal tab or window go to mediawiki/core folder:

./node_modules/.bin/wdio tests/selenium/wdio.conf.js --spec extensions/RelatedArticles/tests/selenium/specs/*.js

Run only one RelatedArticles test file from mediawiki/core:

./node_modules/.bin/wdio tests/selenium/wdio.conf.js --spec extensions/RelatedArticles/tests/selenium/specs/readmore.js