browserstack / webdriverio-browserstack

Selenium examples for WebDriverIO and BrowserStack Automate
https://www.browserstack.com
68 stars 93 forks source link

ACE_3096, replaced synchronously written tests with async/ await to o… #35

Closed AnandGH5 closed 2 years ago

AnandGH5 commented 2 years ago

@wdio/sync module is deprecated in node version 16 onwards. So it has to be completely removed. All tests have now been written in asynchronous format with async-awaits. Read more about this deprecation here: https://webdriver.io/blog/2021/07/28/sync-api-deprecation/

Use: nvm install 16 to install node version 16 nvm use 16 to use this version of node perform npm install

then test the sample code using npm run local ,npm run single,npm run parallel

Once these changes are approved, Also need to ensure to make changes in Docs repository to update the sample codes with the updated ones. Have made the changes here: https://github.com/browserstack/docs/pull/1321

AnandGH5 commented 2 years ago

Looks good. Have we checked specs with lower versions of node as well?

Yup have tried running the same on node version 10 and 12 as well, runs fine.