The Screenplay Pattern: Better Interactions for Better Automation
For more than a decade, the Page Object Model with Selenium WebDriver or Appium has been the predominant design pattern for automating UI interactions. Unfortunately, page objects have problems with code duplication and flakiness at scale. It's time for a better pattern. The Screenplay Pattern is a much better alternative: Actors use Abilities to perform Interactions. In this talk, I will show you how to use the Screenplay Pattern using Boa Constrictor, the .NET Screenplay implementation. First, we will see problems with writing WebDriver-based tests the "traditional" way by attempting to code a simple search engine test. Second, we will learn how the Screenplay Pattern overcomes these limitations with a separation of concerns. And third, we will rewrite the search engine test using Boa Constrictor's Screenplay calls. All example code will be written in C#. By the end of this talk, you will be able to write your own automation code in C# using the Screenplay Pattern and Boa Constrictor!