Open Vorobeyko opened 4 years ago
A workaround is explicitly declaring your locatorObj type to 'css'. Working example:
module.exports = () => {
codeceptjs.locator.addFilter(( providedLocator, locatorObj) => {
if (...) {
locatorObj.type = 'css';
...
I try to call:
but locator contains:
And the
waitForVisible
step checks if this locatorisCss
will makelocator.simplify
, else waitByXpath, butname
is not css, and CodeceptJS tries to search element by following xpath:'field_name'
, but it is invalid xpath