Primary definition
Behaviour Driven Development (BDD): Practices, Tools and Examples

Behaviour driven development is a way of agreeing what software should do before it is built, by writing the agreement down as concrete examples in language the whole team shares. The examples are precise enough to run, which is why the practice is so often mistaken for a kind of testing.
Concrete values, one reading, an outcome a machine can check.
Requirement as written
What it resolves to
account.balance = 100
machine.cash ≥ 20
customer.requests(20)
machine.dispenses(20)
account.balance = 80
Every step reads two ways, so two teams build two systems.
Requirement as written
What it resolves to
account.balance = ?“sufficient” names no number
machine.cash = ?“adequately” against what demand
customer.requests(?)“large” is left to the reader
machine.?dispense, refuse, or offer a lower amount
account.balance = ?no arithmetic is implied
Nothing here is observable, so there is no assertion to write.
Requirement as written
What it resolves to
—“valued” is a judgement, not a state the system holds
—“interact” covers every button on the machine
—“feel fast” names no threshold and no measurement
—“delighted” is not a property of the system at all
On the left, a requirement as a team would write it. On the right, the same requirement with every clause pinned to something a machine can check. Nothing was added in translation, which is the test of whether the wording was good enough.
What behaviour driven development asks of a team
The practice makes one demand, and everything else follows from it: the people who want the software and the people who build it have to agree on specific examples before the work starts. Not a description of the feature, and not a definition of done. Specific cases, with specific values, including the ones where the answer is no.
That demand is organisational rather than technical, which is why behaviour driven development is harder to adopt than any tool suggests. Writing the examples takes a conversation between someone who understands the need, someone who will build it, and someone whose instinct is to look for the case nobody considered. The three together find the disagreement that none of them would have found alone.
What the team gets in return is a decision made once. The examples become the acceptance criteria, the specification and, once automated, the regression suite. They also stop being true the moment the behaviour changes, which is the property that ordinary documentation never has.
The practices BDD adds to an ordinary week
In day-to-day terms the practices are unglamorous. A short session before work begins, in which the examples get written on a board and argued over. A habit of stating outcomes in terms the person who asked for the feature would recognise. A rule that a scenario describing internal mechanics belongs in a unit test instead.
Teams that get value from BDD tend to apply these practices selectively. The features where the rules are contested, or where a misunderstanding would be expensive, earn the conversation. Well-understood mechanical work does not, and forcing it through the same process is the most common way the practice gets abandoned.
The vocabulary matters more than newcomers expect, because the examples are only useful if a non-programmer can spot that one is wrong. Getting the words right is a practice in its own right, and the reason the notation looks so plain.
Core vocabulary
Eight terms, each resolved
Story
A unit of work stated from the point of view of whoever benefits from it.Scenario
One concrete example of a behaviour, with real values rather than descriptions.Feature
A capability with business value, holding the scenarios that pin it down.Given
The context that already holds before anything happens.When
The single event under examination.Then
The outcome that must follow, stated so it can be checked.Acceptance criteria
The conditions under which the people who asked for the work agree it is done.Ubiquitous language
One vocabulary shared by the business and the code, with no translation layer.Worked examples resolve into checkable clauses
The value of writing examples this way shows up when one of them cannot be resolved. A clause that no machine can check is usually a clause no human agreed on either. "Then the customer is happy" fails both tests, and rewriting it forces the question that the original wording let everyone avoid.
Two further examples make the point. A scenario that begins with four Given clauses is describing a context so specific that the rule underneath it is probably narrower than the team thinks. A scenario with three When clauses is describing more than one behaviour and should be split.
BDD tools by language
Implementation matrix
| Framework | Languages | Gherkin | Status |
|---|---|---|---|
| Behat | PHP | Full | active |
| behave | Python | Full | maintained |
| Concordion | Java, C# | Own DSL | low-activity |
| Cucumber (Ruby) | Ruby | Full | active |
| Cucumber JVM | Java, Kotlin, Scala, Groovy | Full | active |
| Cucumber.js | JavaScript, TypeScript | Full | active |
| Cypress Cucumber Preprocessor | JavaScript, TypeScript | Full | active |
| Gauge | Java, C#, Python, Ruby, JavaScript | Own DSL | active |
Which BDD tools a team uses follows from the language it already writes. Thefull framework list records every option with its licence and the registry check behind its status.
Frequently asked questions
What does BDD stand for?
Behaviour driven development. The British spelling is the original, since the term was coined by Dan North; behavior driven development is the same practice.
Is BDD a testing technique?
Not primarily. The executable scenarios look like tests and are often run by a test runner, but the value sits in the agreement they record. A team with a green scenario suite and no conversation has the artefacts and none of the benefit.
Which BDD tools should a team pick?
It follows the language, not the other way round. The framework list by language gives the current options with their Gherkin support and maintenance status.
Do I need Gherkin to practise BDD?
No. Gherkin is one notation, and a widely understood one, but examples on a whiteboard in plain prose satisfy the practice. Gherkin syntax matters once you want the examples executed.
How many scenarios should a feature have?
As many as there are rules worth arguing about, which is usually a handful. Scenario count is not a progress measure; a large suite covering undisputed behaviour is a maintenance cost with no return.
Where did BDD come from?
From teaching test driven development. Dan North set out the account in Introducing BDD in 2006, after finding that the word "test" caused most of the resistance he met when coaching teams.