STARWEST 2021 Concurrent Session : The Screenplay Pattern: Better Interactions for Better Automation

SEE PRICING & PACKAGES

Wednesday, October 6, 2021 - 11:30am to 12:30pm

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!

Andrew Knight
PrecisionLender, a Q2 Company

Andrew Knight is the "Automation Panda"—an engineer, consultant, and international speaker who builds solutions for software testing problems. He has designed and implemented robust test automation projects for Web UIs, service APIs, and operating systems with thousands of tests running continuously. He is the lead developer for Boa Constrictor, the .NET Screenplay Pattern, and he is also renowned as a Behavior-Driven Development expert. Andy currently works full-time as the Lead Software Engineer in Test at PrecisionLender, a Q2 Company. Read his tech blog at AutomationPanda.com and follow him on Twitter.