Test Automation Toolbox 2019- 05/03/2019
What tools to use for browser based automation in 2019?
Most of the browser automation tools use selenium to communicate with the browser but there are also tools that by-pass it by talking directly to the browser. Cypress.io and Puppeteer are such frameworks. They are faster and circumvent some of the problems related to Selenium. Both of these only support Chrome and they also do lack some of the tooling that has been built into frameworks such as WebdriverIO., which might be a showstopper for some projects.
- test frameworks
I’ve used WebdriverIO for the past three years and have been quite happy with the results. There are big changes between v4 and v5 and anyone starting a new project right now should opt for the new version.
The Test Runner
WebdriverIO comes with its own test runner that does several things out of the box. For example, it can run tests in parallel and retry flaky tests. The full list of options is available in the docs.
WebdriverIO can be used with several popular test frameworks by just including an adapter in
package.json and adding some configuration. The supported test frameworks are the following:
- Cucumber (currently only supported in v4)
There are a number of services that can be integrated with by just adding the
npm package to development dependencies and adding the service in the configuration. Usually the service can also be configured right in the WebdriverIO config file.
There are services for Browserstack and Sauce Labs, there is one for selenium-standalone and another one for Applitools. The full list is available in the Services section of the documentation.
Another area that makes is easy to get started and later on work with WebdriverIO is the reporter integration. There are a number of different reporters available that work well out of the box. These are described in detail in the Reporter section of the documentation. The documentation is not an exhaustive list and there are other good reporters available, for example:
WebdriverIO with its integrations and extensibility have worked well in some recent projects and I consider it as a safe choice also in 2019. It is also a good time to start looking at tools like Cypress.io depending on the organisations needs.