4. introduction
Dan North
want to
improve TDD
a unit test
is more meaningful
in a full sentence
should_login_a_user_to_his_account() {}
Behavior
is also described
by Business Analysts
Eric Evens:
ubiquitous language
Chris Matts
The Business Analyst GOAL:
readable requirements
and automated
acceptance tests
GIVEN
WHEN
THEN
10. write a Story
Title
Narrative:
As a [role]
I want [feature]
So that [benefit]
Scenario 1: Title
Given [context]
And [some more context]...
When [event]
Then [outcome]
And [another outcome]...
Scenario 2: ...
Title: A customer should add items to his cart
Narrative:
As a customer
I want to add items to my shopping cart
So that I can place an new order
Scenario: Customer should add an item
to shopping cart
Given a shopping cart
When a customer adds an item to his shopping cart
Then the shopping cart contains 1 different item
14. at a glance
Pros
• reduces waste
• changes are saver
• spread the knowledge
• brings the team together
• domain language
• find design smells
• serves as documentation
• (reduces costs)
Keep in mind
• high business engagement
• don’t use with design up front
• won’t work in silos
• bad tests lead to bad code
15.
16.
17. bibliography
Books
BDD in Action
Growing Object-Oriented Software, Guided by Tests
Specification By Example
ATDD By Example
Online
http://dannorth.net/whats-in-a-story/
https://weblogs.java.net/blog/manningpubs/archive/2013/06/10/introducing-behavior-driven-development
http://technologyconversations.com/category/behavior-driven-development-bdd/
http://www.thoughtworks.com/insights/blog/qa-role-what-it-really
http://www.jbehave.org