Asynchronous Selenium: How to Survive JS Testing
summary
The talk explains problems testing JavaScript UIs with Selenium when every WebDriver operation is asynchronous and returns a promise, which leads to callback hell. It demonstrates using promises, generators (co), async/await and fibers to linearize control flow and compares Selenium WebDriver JS, Protractor, webdriverio, Nightwatch, CucumberJS and CodeceptJS, showing tradeoffs; it also describes a higher‑level approach used in CodeceptJS that combines Cucumber‑style steps with global promise tracking to produce more readable linear tests while still exposing some async edge cases.
AI-written summary · about
chapters (24)
- 0:00Introduction
- 1:51Speaker background
- 3:37Synchronous programming problem
- 5:01Async as natural model
- 8:33Sync vs async approaches
- 9:36Async issues in automation
- 11:23JavaScript events explained
- 13:14Callback hell problem
- 13:54Promise solution
- 16:25Generators in async
- 17:50Async/await sugar
- 18:34Fibers critique
- 19:56Async testing libraries
- 22:03WebDriver JS integration
- 22:44WebDriverJS official
- 23:52WebdriverIO alternative
- 24:56Protractor issues
- 26:18Protractor async solution
- 28:50Cucumber testing tool
- 30:20Concept for async tests
- 33:51Summary and tool choice
- 35:35Async test challenges
- 38:10Why JavaScript for testing
- 40:40Q&A
related talks
43mEmbrace The Native Async Nature Of JavaScript In WebDriverJS
36mModern Web Testing: Going Beyond Selenium
41mDesign Decisions for the Perfect JS Testing Framework
30mModern Web Testing: Going Beyond Selenium
53mModern Web Testing: Going Beyond Selenium
55mModern Web Testing: Going Beyond Selenium
38mModern Web Testing: Going Beyond Selenium
23mLife After Selenium
