Chapter 3

Formalizing Examples into Scenarios

We prefer to separate the discovery step of BDD from the formalization and automation steps. Many teams get bogged down in trying to formalize examples too soon, rather than separating that out as a later task that can then be reviewed by the team.

Generating examples should be divergent and exploratory. As the team generates examples, the shape of the desired behavior emerges.

Formalizing examples is convergent. The team takes a single example and converges on a single precise set of words to describe it.

Rushing to formalization too quickly skips over important divergence and exploration.

In this chapter, we look at how to formalize examples into Cucumber scenarios using Cucumber’s Gherkin language. ...

Get Behavior-Driven Development with Cucumber: Better Collaboration for Better Software now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.