From Protractor to WebdriverIO (WDIO)
Due to Protractor ending development, WDIO will now be used instead of Protractor going forward.
What this means for you...
- The biggest thing is that you'll need a new config. See the courgette-conf.js inside the Courgette repo that's used to test that Courgette itself works (it runs a small website to test against).
- The next thing is that Courgette is doing away with
.js
page objects (and component objects). From now on only the YAML syntax is supported. - Built-in step definitions are still all the same as before however some have been removed (see below). However if you have made your own step definitions, you'll need to use WDIO methods where you've used Protractor methods. E.g.
browser.executeScript
becomesbrowser.execute
. See all the methods on the WDIO site e.g. here: https://webdriver.io/docs/api/element/addValue/
See the contents of the indentical step definition between the Protractor way and the WDIO way.
- Inside page objects
xpaths:
items should now come underselectors:
Changes to methods on this
object (and associated step definitions have been removed)
- Deleted submitForm
- appendReactInputFieldValue, checkFocus, checkIsOpenedInNewWindow have been temporarily removed
- checkClass, checkElementBackgroundColour, checkElementBorderColour, checkElementColour have been removed but they can be re-introduced if there is a demand for it
Caveats
- Testing native mobile apps may have issues currently. Please create an issue or submit a pull request for any problems found.