Often there appears to be confusion about the concept of Behavior Driven Development (BDD) and far too often BDD is seen as a testing approach. Is this maybe because BDD grew from a response to Test Driven Development (TDD), as explained by BDD pioneer Daniel Terhorst-North?
Although there may be misunderstandings regarding the concept of BDD, this blog does not intend to delve deeply into the complete concept of BDD or provide a comprehensive guide on how to perform BDD correctly. Numerous other blogs have already extensively covered these topics. However, for the purpose of this blog, it is important to at least acknowledge that BDD emphasizes the importance of collaboration between developers, testers, and business stakeholders. It centers around creating a common language that is easily understood by everyone involved, to get a deeply shared understanding of the requirements.
TestCompass
In this blog we explore how the collaborative modeling tool TestCompass, in addition to the early Model Based Testing (eMBT) approach (see our other blog https://www.compass-testservices.com/embt-with-testcompass-in-practice), supports BDD in a very easy to use way. And specifically for the BDD phases Discovery and Formulation. Therefore we will take a closer look how to perform the BDD requirements Discovery practices ‘Example mapping’ and ‘Feature mapping’ (known as 3-amigos sessions) in TestCompass and how to turn the results (concrete examples) of these Discovery practices automatically into business readable language (as Gherkin feature files), in the Formulation phase.
As described in the intro of this blog, Behavior-Driven Development (BDD) is a powerful approach to software development that emphasizes collaboration and communication between all stakeholders (business and technical). However, executing the 3 different phases of BDD (Discovery, Formulation and Automation) can be challenging. Fortunately, there are tools and practices available to help teams execute these BDD phases more effectively.
TestCompass is such a tool, which can help you streamline, simplify and automate the BDD phases Discovery and Formulation.
Discovery
In the BDD phase Discovery, we need to answer the question “What could it do?” and collaboration between business stakeholders, developers and testers is essential here. The goal of this phase is to ensure that everyone is on the same page regarding the requirements. To facilitate this collaboration, often workshops or meetings are hold, like ‘Example mapping’ and ‘Feature mapping’ (also known as requirements discovery workshops and 3-amigos sessions). In this meeting, a group of individuals (including at least a business stakeholder, developer and tester) convene to discuss a user story and document specific examples on index cards or sticky notes that serve as illustrations for that user story. These examples, typically associated with a particular business rule, generally comprise of the context, action, and outcome, effectively demonstrating the behavior described by the story.
TestCompass can support these requirements discovery practices, ‘Example mapping’ and ‘Feature mapping’, by the possibility to model out the Example map and Feature map by simply drag and drop different used colored sticky notes onto the canvas. For ‘Example mapping’ normally yellow sticky notes for the story, blue for the rules, green for the examples and red sticky notes for the questions that arise, are being used. In `Feature mapping’ normally yellow sticky notes for the story, blue for rules, green for examples, yellow for the steps and purple for the consequences are used. Also here red sticky notes for the questions that arise.
See below an example of an Example map and a Feature map modelled in TestCompass.