webdriverio-boneyard / wdio-sync

A WebdriverIO v4 plugin. Helper module to run WebdriverIO commands synchronously.
http://v4.webdriver.io
MIT License
17 stars 31 forks source link

Renamed `*Async` commands conflict with those already defined #1

Closed georgecrawford closed 8 years ago

georgecrawford commented 9 years ago

I noticed that wrapAsync in https://github.com/webdriverio/webdriverio/blob/562db5d1b90b2f7d34d4c6b282f087c9eb07a79e/lib/helpers/wrapAsync.js#L22 moves a synchronous command into the main commandName space, but copies the async equivalent to commandName + 'Async'. This doesn't work where there's already an equivalent - the executeAsync command thereafter uses the asynchronous version of execute, which is not what's desired.

I think the exact problem is replicated in this repo, at https://github.com/webdriverio/wdio-sync/blob/master/index.js#L17.