Nightwatch.js Selenium e2e test: input field clearing issue
While doing the e2e (end to end) tests for a Vue.JS frontend, I bumped into something interesting, which was really fun to fix/find a workaround for.
Firstly, for the e2e tests, I've used Nightwatch.js, which uses the Selenium API, and is written in Node.js.
The problem was that, I was not being able to clear some input
tag field data using the API provided by Nightwatch -- browser.clearValue
. For example:
browser.clearValue('input[type="text"]')