Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Async webdriverjs

1,065 views

Published on

Embrace The Native Async Nature Of JavaScript In WebDriverJS
Selenium Conference Austin 2017

Published in: Software
  • Be the first to comment

Async webdriverjs

  1. 1. http://assertselenium.com
  2. 2. • •
  3. 3. HOW MANY USE JAVASCRIPT FOR TESTING ?
  4. 4. ACHILLE'S HEEL
  5. 5. CONTINUATION PASSING OR PYRAMID OF DOOM
  6. 6. VERBOSE
  7. 7.
  8. 8. • •
  9. 9. • •
  10. 10. WebdriverJs with Promise Manager Equivalent Java code
  11. 11. • • •
  12. 12. • •
  13. 13.  
  14. 14. • •
  15. 15. • • • • task.js •
  16. 16. Yield blocks until execution is done.
  17. 17. • • •
  18. 18. • •
  19. 19. • • • • • •
  20. 20. • • PROMISE.USE_PROMISE_MANAGER = FALSE • •
  21. 21. • • •
  22. 22. • • •
  23. 23.
  24. 24. • • •
  25. 25. Untouched for 3 years now Long! Long !! Ago!!!…...
  26. 26. • https://github.com/SeleniumHQ/selenium/blob/master/javascript/node/selenium- webdriver/example/async_await_test.js • https://github.com/tourdedave/elemental-selenium-tips/ • https://github.com/airware/webdriver-mocha-async-await-example

×