Status
Description
To make migrating browser tests from Ruby to Node.js a more straight-forward affair we will setup the infrastructure for running both Ruby and Node.js browser tests. We will port over our most simple browser test to demonstrate it is working.
Once this is in place, we will be able to easily, safely and gradually port over our browser tests.
Acceptance criteria
- Minerva has two folders - 'browser' (containing the existing Ruby tests) and 'selenium' (containing the new Node.js tests)
- Make sure https://gerrit.wikimedia.org/r/#/c/421961/ has been merged to simplify implementation
- The categories.feature browser is moved from 'browser' to 'selenium'. We will retain the existing cucumber notation and .feature file and provide step_definitions written in Node.js
- Node.js browser tests and Ruby browser tests run with every commit
- A selenium-MinervaNeue-jessie test is listed on https://integration.wikimedia.org/ci/view/Reading-Web/ which runs the Node.js browser tests as well as the selenium-MinervaNeue test that runs the Ruby browser tests.
TODO
๐ T199116: Quibble should run `npm install` and `npm run selenium-test` for each extension/skin that has Selenium tests
๐ 423648 Adding initial webdriver.io test
๐ 425422 Adding "diff.feature" selenium test
Run tests
~/Documents/gerrit/mediawiki/vagrant$ vagrant up ... ~/Documents/gerrit/mediawiki/vagrant$ vagrant roles enable minerva Ok. Run `vagrant provision` to apply your changes. ~/Documents/gerrit/mediawiki/vagrant$ vagrant provision ... ~/Documents/gerrit/mediawiki/vagrant$ cd mediawiki/skins/MinervaNeue/ ~/Documents/gerrit/mediawiki/vagrant/mediawiki/skins/MinervaNeue$ git review -d 423648 ... ~/Documents/gerrit/mediawiki/vagrant/mediawiki/skins/MinervaNeue$ npm i ... ~/Documents/gerrit/mediawiki/vagrant/mediawiki/skins/MinervaNeue$ npm run selenium ... Number of specs: 2 13 passing (51.20s) sh: line 1: 7831 Terminated: 15 chromedriver --url-base=/wd/hub --port=4444