Behavior-driven development: Difference between revisions

Content deleted Content added
m capitalisation
m Popups-assisted redirection bypass from Test driven development to Test-driven development
Line 1:
{{context}}
 
'''Behavior Driven Development''' (BDD) is a programming technique which emphasizes the specification of the behavior of software at a very fine level of granularity. BDD is a variant of or perhaps a reaction to [[Test-driven development|test driven development]].
 
It changes the focus from thinking in terms of testing to thinking about ''behavior''. In TDD you write a test, have it fail, and then have it pass by writing code. In BDD, you think of a specification in a given context, using method names beginning with "should". These define the behavior of the class you are writing, so a method called <tt>shouldDoSomethingCool</tt> in a class <tt>FooBehavior</tt> would be read as: ''Class Foo '''should''' do something cool.''