Tech Lead Journal cover image

Tech Lead Journal

#148 - Behavior-Driven Development (BDD) Essentials - Jan Molak & John Ferguson Smart

Sep 11, 2023
Jan Molak and John Smart, co-authors of 'BDD in Action: Second Edition', discuss behavior-driven development (BDD) and its essentials. They introduce BDD, its benefits, and the Gherkin language. They share advice on applying BDD, managing BDD specifications, and techniques like feature mapping and example mapping. They also discuss the screenplay pattern and the Serenity projects. They provide insights on testing layers to apply BDD and anti-patterns to avoid.
01:26:28

Podcast summary created with Snipd AI

Quick takeaways

  • The screenplay pattern in behavior-driven development (BDD) is a user-centered approach that improves code maintainability and understandability by capturing the business intent behind functionality through actors, tasks, interactions, abilities, and questions.
  • BDD can be incorporated into legacy software through incremental application to new features or retroactively adding executable specifications, ensuring improved quality and maintainability by focusing on communication, collaboration, and understanding requirements.

Deep dives

Screenplay pattern: A user-centered approach to automated acceptance tests

The screenplay pattern is a user-centered approach to writing high-quality automated acceptance tests. It encourages the use of layers of abstraction and helps capture the business vocabulary of a domain. The pattern consists of five building blocks: actors, tasks, interactions, abilities, and questions. Actors represent users or external systems interacting with the system under test. Tasks are the specific goals and actions performed by actors. Interactions are the lower-level actions performed by actors to interact with the system. Abilities are thin wrappers around integration libraries that enable interactions. Questions retrieve information from the system. The screenplay pattern provides a way to capture the business intent behind the functionality and improve code maintainability and understandability.

Remember Everything You Learn from Podcasts

Save insights instantly, chat with episodes, and build lasting knowledge - all powered by AI.
App store bannerPlay store banner