Webdriverio: Error: Promise was rejected with the following reason: selector needs to be typeof `string`

Created on 28 Nov 2017  路  4Comments  路  Source: webdriverio/webdriverio

The problem

Autotests didn't work which last version WebdriverIO: 4.9.10

Environment

  • WebdriverIO version: 4.9.10
  • Node.js version: v6.9.2
  • Standalone mode or wdio testrunner: wdio
  • if wdio testrunner, running synchronous or asynchronous tests: synchronous
  • Additional wdio packages used (if applicable):

Details

After update WebdriverIO I can have error about function isVisible or waitForExist where used it for my selector:
screenshot_1

Link to Selenium/WebdriverIO logs

SongLine_Auto_tests-Webdriver_Run_Auto_test_1450.log

Code To Reproduce Issue [ Good To Have ]

Example error for test gallery image and movies add correct

Error: Promise was rejected with the following reason: selector needs to be typeof `string`     
at Page.Object.create.waitVisible.value (tests/Pages/UploadPage.js:18:52)     
at Context.<anonymous> (tests/tests/gallery.add.rename.delete.test.js:65:20)     
at new Promise (node_modules/wdio-sync/node_modules/core-js/library/modules/es6.promise.js:171:7)
at elements() - isExisting.js:46:17     
at isExisting() - waitForExist.js:67:22

UploadPage view:
screenshot_2

Maybe it is duplicate https://github.com/webdriverio/webdriverio/issues/2481

Most helpful comment

@christian-bromann set "webdriverio": "4.9.9" - all work well
screenshot_5

All 4 comments

@ViaMay you need to use this.uploadFromComputerButtom.waitForExist() in there.
Join our Gitter for these kind of questions. This is not necessary an issue.

@christian-bromann still have this error
screenshot_4

yesterday all work well. Now didn't

@christian-bromann set "webdriverio": "4.9.9" - all work well
screenshot_5

Was this page helpful?
0 / 5 - 0 ratings

Related issues

christian-bromann picture christian-bromann  路  3Comments

briancullinan picture briancullinan  路  4Comments

mrahman2327 picture mrahman2327  路  3Comments

LaiaPR picture LaiaPR  路  4Comments

pfluegs picture pfluegs  路  4Comments