At StarWest 2014 I presented a Selenium WebDriver tutorial and a track session on Page Object Abstractions.
“Selenium is an open source automation tool for test driving browser-based applications. WebDriver, the newly-introduced API for Selenium against which tests are written in Java, contains classes including ChromeDriver, AndroidDriver, and iPhoneDriver. Sometimes test authors find the API daunting and their initial automation code brittle and poorly structured. In this introduction, Alan Richardson provides hints and tips gained from his years of experience both using WebDriver and helping others improve their use of the tool. Alan starts at the beginning, explaining the basic WebDriver API capabilities—simple interrogation and navigation—and then moves on to synchronization strategies and working with AJAX applications. He covers tools and location strategies to find elements on web pages using CSS and XPath. Alan provides an introduction to abstraction approaches which help you build robust, reliable, and maintainable automation suites.”
The tutorial pre-requisite was the Free Get Started Selenium WebDriver course. This allows everyone to have the basic installs ready so that the tutorial can start quickly.
- The test pages we use on the tutorial: https://github.com/eviltester/seleniumTestPages
The tutorial was revamped from the StarEast 2014 incarnation so the exercises had more code templates to learn from rather than having people write a lot of code classes from scratch. This allows people new to Java to make a lot of progress without getting stuck on the Java parts.
Track Session: Page Object Abstractions and Beyond
“When you start writing automation for your projects, you quickly realize that you need to organize and design the code. You will write far more than ’test’ code; you also will write abstraction code because you want to make tests easier to read and maintain. But how do you design all this code? How do you organize and structure it? Should you use a domain specific language? Should you go keyword driven or use Gherkin? Should you use page objects with POJO or Factories? Do you create DOM level abstractions? Where do domain models fit in? Alan Richardson provides an overview of options available to you when modeling abstraction layers. Based on his experience with many approaches on real-world commercial projects, Alan helps you understand how to think about the modeling of abstraction layers. Illustrated with a number of code examples, Alan shows you a variety of approaches and discusses the pros and cons associated with each.”
This was the first time I presented this talk, although it was a cut down version of the Let’s Test Tutorial
Slides and Code
The code was released to github
The slides were released to slideshare: