Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
John	
  Ferguson	
  Smart
BDD In Action
Principles, practices and real-world applications
John Ferguson Smart
Consultant	
  
Trainer	
  
Mentor	
  
Author	
  
Speaker	
  
Coder
There are only two problems
in software development
1) Building the software wrong
2) Building the wrong software
BDD
Feature Injection
Automated Acceptance
Criteria
API and code design
Collaboration
Building the software right
Building...
Behaviour	
  Driven	
  Development	
  is…
Conversa>on	
  Focused
Story
bug	
  reports
Working	
  
code boring	
  
manual	
  
tes>ng
WASTE
BA
Developer
Tester
Many teams build features lik...
…but a little cooperation goes a long way…
Working	
  code	
  	
  
and	
  	
  
Working	
  Automated	
  
Acceptance	
  Test...
We call this “The Three Amigos”
BA	
  and/or	
  product	
  owner
Tester Developer Automatable	
  
Acceptance	
  
Criteria
...
We call this “The Three Amigos”
Conversa>on	
  Focused
Behaviour	
  Driven	
  Development	
  is…
Example-­‐based
Example-­‐based
Behaviour	
  Driven	
  Development	
  is…
Value-­‐Driven
Behaviour	
  Driven	
  Development	
  is…
Outside-­‐in
Outside
In
Behaviour	
  Driven	
  Development	
  is…
Executable	
  Specifica>ons
More value faster
Delivery	
  Time
Tradi>onal
Using	
  BDD
31%	
  faster	
  delivery
Behaviour	
  Driven	
  Development	
 ...
Higher Quality
Defect	
  Rate
Tradi>onal
Using	
  BDD
4	
  >mes	
  less	
  defects
Behaviour	
  Driven	
  Development	
  i...
Scenario
Step	
  Defini>ons
Low	
  level	
  specifica>ons	
  
(aka	
  “unit	
  tests”)
Applica>on	
  Code
BDD	
  guides	
  d...
Oh, the things you can learn…
BDD	
  guides	
  development
What	
  would	
  we	
  like	
  the	
  API	
  to	
  look	
  like?
BDD	
  guides	
  development
Then	
  write	
  low-­‐level	
  specifica>ons	
  for	
  the	
  code
BDD	
  guides	
  development
Then	
  write	
  low-­‐level	
  specifica>ons	
  for	
  the	
  code
BDD	
  guides	
  development
“Every class is an API for
someone”
BDD	
  in	
  Ac>on	
  -­‐	
  some	
  real-­‐world	
  examples
Mission	
  cri;cal	
  legacy	
  web	
  applica;on
Case	
  1	
  -­‐	
  an	
  e-­‐commerce	
  web	
  site
Frequent	
  small	...
Case	
  1	
  -­‐	
  an	
  e-­‐commerce	
  web	
  site
Approach
“BDD-­‐style”	
  regression	
  tests
High	
  communica;on	
...
“BDD-­‐style”	
  regression	
  tests
Case	
  1	
  -­‐	
  an	
  e-­‐commerce	
  web	
  site
Approach
Case	
  1	
  -­‐	
  an	
  e-­‐commerce	
  web	
  site
Outcomes
Living	
  documenta;on
Case	
  1	
  -­‐	
  an	
  e-­‐commerce	
  web	
  site
Outcomes
Living	
  documenta;on
Case	
  1	
  -­‐	
  an	
  e-­‐commerce	
  web	
  site
Outcomes
Living	
  documenta;on
New	
  large-­‐scale	
  project
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
7	
  years,	
  2	
  Scrum	
  teams...
Approach
Full	
  team-­‐wide	
  BDD	
  adop;on
Test	
  automa;on	
  for	
  (almost)	
  all	
  acceptance	
  criteria
Tight...
Approach
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Stories
Features
Capabilities
Goals
Requirements	
  organ...
Approach
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Stories
Features
Capabilities
Goals
Requirements	
  manag...
Approach
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Story
Examples
Automated	
  
acceptance	
  
criteria
“Thr...
Approach
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Acceptance	
  Criteria	
  map	
  back	
  to	
  JIRA
Approach
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Stories
Features
Capabilities
Goals
Manual	
  test	
  cas...
Approach
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Stories
Features
Capabilities
Goals
Automated	
  and	
  M...
Approach
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Releases	
  organised	
  in	
  JIRA
Outcomes
Case	
  2	
  -­‐	
  a	
  large	
  financial	
  ins>tu>on
Code	
  coverage	
  when	
  from	
  8%	
  to	
  80+%
Very...
BDD	
  involves	
  a	
  major	
  culture	
  change
BDD	
  Adop>on	
  -­‐	
  Tips	
  and	
  Tricks
Don’t	
  skimp	
  on	
  ...
References
http://jbehave.org
BDD in Java
http://thucydides.info
Living Documentation
Issue tracking and Agile
project man...
Thank you!
John Ferguson Smart
john.smart@wakaleo.com
wakaleo
http://www.wakaleo.com
Upcoming SlideShare
Loading in …5
×

BDD in Action – principles, practices and real-world application

10,019 views

Published on

Behaviour-driven development (BDD) started as an improved variation on test-driven development, but has evolved to become a formidable tool that helps teams communicate more effectively about requirements, using conversation and concrete examples to discover what features really matter to the business. BDD helps teams focus not only on building features that work, but on ensuring that the features they deliver are the ones that the client actually needs.

In this talk, we will discuss what BDD is about, its benefits, and how it affects teams and processes. We will discuss two case studies where BDD practices have been successfully introduced, including the benefits gained and challenges met. We will see how much benefit was gained when BDD was integrated into the broader development infrastructure, including issue tracking systems, requirements management, and project reporting.
We will also see how BDD can be applied to all levels of the development process, from requirements down to low-level coding. We will also look at the principle BDD tools available that can help teams implement executable specifications, BDD-style test automation, and living documentation effectively. Some of the tools discussed will include JBehave, Cucumber, Specflow, Jasmine and Spock.

We will also look at two case studies where BDD practices have been successfully integrated into several projects in large government and financial organizations. Teams that adopted BDD effectively benefited from significantly lower defect rates, much earlier discovery of errors and inconsistencies in the requirements, and better overall communication and collaboration within the team. However, practicing BDD does involve a significant change in mind-set compared to more traditional approaches, a different collaboration model between team members, and a high degree of stakeholder by-in and engagement, all of which should not be underestimated. We will discuss how the teams managed these various challenges during their BDD adoption story.

Published in: Technology
  • DOWNLOAD THAT BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download Full EPUB Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download Full doc Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download PDF EBOOK here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download EPUB Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... Download doc Ebook here { http://bit.ly/2m6jJ5M } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book that can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer that is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story That Helped Ignite a Movement,-- Atomic Habits: An Easy & Proven Way to Build Good Habits & Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money That the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths that Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD FULL BOOKS, INTO AVAILABLE FORMAT ......................................................................................................................... ......................................................................................................................... ,DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ,DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ,DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ,DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ,DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ,DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/yyxo9sk7 } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD FULL BOOKS, INTO AVAILABLE FORMAT ......................................................................................................................... ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/y6a5rkg5 } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/y6a5rkg5 } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/y6a5rkg5 } ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/y6a5rkg5 } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/y6a5rkg5 } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/y6a5rkg5 } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD FULL BOOKS, INTO AVAILABLE FORMAT ......................................................................................................................... ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/yxufevpm } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD FULL BOOKS, INTO AVAILABLE FORMAT ......................................................................................................................... ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here

BDD in Action – principles, practices and real-world application

  1. 1. John  Ferguson  Smart BDD In Action Principles, practices and real-world applications
  2. 2. John Ferguson Smart Consultant   Trainer   Mentor   Author   Speaker   Coder
  3. 3. There are only two problems in software development 1) Building the software wrong 2) Building the wrong software
  4. 4. BDD Feature Injection Automated Acceptance Criteria API and code design Collaboration Building the software right Building the right software Living Documentation What  is  Behaviour  Driven  Development
  5. 5. Behaviour  Driven  Development  is… Conversa>on  Focused
  6. 6. Story bug  reports Working   code boring   manual   tes>ng WASTE BA Developer Tester Many teams build features like this… Conversa>on  Focused
  7. 7. …but a little cooperation goes a long way… Working  code     and     Working  Automated   Acceptance  Tests Exploratory  tes>ng,   usability  tes>ng... Shared   understanding Story Examples Automated   acceptance   criteria Conversa>on  Focused
  8. 8. We call this “The Three Amigos” BA  and/or  product  owner Tester Developer Automatable   Acceptance   Criteria Shared   understanding Conversa>on  Focused
  9. 9. We call this “The Three Amigos” Conversa>on  Focused
  10. 10. Behaviour  Driven  Development  is… Example-­‐based
  11. 11. Example-­‐based
  12. 12. Behaviour  Driven  Development  is… Value-­‐Driven
  13. 13. Behaviour  Driven  Development  is… Outside-­‐in Outside In
  14. 14. Behaviour  Driven  Development  is… Executable  Specifica>ons
  15. 15. More value faster Delivery  Time Tradi>onal Using  BDD 31%  faster  delivery Behaviour  Driven  Development  is…
  16. 16. Higher Quality Defect  Rate Tradi>onal Using  BDD 4  >mes  less  defects Behaviour  Driven  Development  is…
  17. 17. Scenario Step  Defini>ons Low  level  specifica>ons   (aka  “unit  tests”) Applica>on  Code BDD  guides  development
  18. 18. Oh, the things you can learn… BDD  guides  development
  19. 19. What  would  we  like  the  API  to  look  like? BDD  guides  development
  20. 20. Then  write  low-­‐level  specifica>ons  for  the  code BDD  guides  development
  21. 21. Then  write  low-­‐level  specifica>ons  for  the  code BDD  guides  development
  22. 22. “Every class is an API for someone”
  23. 23. BDD  in  Ac>on  -­‐  some  real-­‐world  examples
  24. 24. Mission  cri;cal  legacy  web  applica;on Case  1  -­‐  an  e-­‐commerce  web  site Frequent  small  changes Business  requires  fast  release  cycle Background
  25. 25. Case  1  -­‐  an  e-­‐commerce  web  site Approach “BDD-­‐style”  regression  tests High  communica;on  value Designed  for  ease  of  maintenance Illustrate  key  business  scenarios Minimum  ini;al  impact  on  team
  26. 26. “BDD-­‐style”  regression  tests Case  1  -­‐  an  e-­‐commerce  web  site Approach
  27. 27. Case  1  -­‐  an  e-­‐commerce  web  site Outcomes Living  documenta;on
  28. 28. Case  1  -­‐  an  e-­‐commerce  web  site Outcomes Living  documenta;on
  29. 29. Case  1  -­‐  an  e-­‐commerce  web  site Outcomes Living  documenta;on
  30. 30. New  large-­‐scale  project Case  2  -­‐  a  large  financial  ins>tu>on 7  years,  2  Scrum  teams Conserva;ve  organisa;on Background Regulatory  and  traceability  
  31. 31. Approach Full  team-­‐wide  BDD  adop;on Test  automa;on  for  (almost)  all  acceptance  criteria Tight  integra;on  with  JIRA  for  traceability   “Three-­‐amigos”  sessions  to  refine  acceptance  criteria High  ini;al  impact  on  team Case  2  -­‐  a  large  financial  ins>tu>on
  32. 32. Approach Case  2  -­‐  a  large  financial  ins>tu>on Stories Features Capabilities Goals Requirements  organised  by  feature  and  capability
  33. 33. Approach Case  2  -­‐  a  large  financial  ins>tu>on Stories Features Capabilities Goals Requirements  managed  in  JIRA
  34. 34. Approach Case  2  -­‐  a  large  financial  ins>tu>on Story Examples Automated   acceptance   criteria “Three  amigos”  sessions  refine  acceptance  criteria
  35. 35. Approach Case  2  -­‐  a  large  financial  ins>tu>on Acceptance  Criteria  map  back  to  JIRA
  36. 36. Approach Case  2  -­‐  a  large  financial  ins>tu>on Stories Features Capabilities Goals Manual  test  cases  managed  in  Zephyr
  37. 37. Approach Case  2  -­‐  a  large  financial  ins>tu>on Stories Features Capabilities Goals Automated  and  Manual  Tests  produce  Living  Documenta;on   Acceptance Criteria
  38. 38. Approach Case  2  -­‐  a  large  financial  ins>tu>on Releases  organised  in  JIRA
  39. 39. Outcomes Case  2  -­‐  a  large  financial  ins>tu>on Code  coverage  when  from  8%  to  80+% Very  liZle  rework  to  delivered  features   Well  documented  APIs Automated  tests  used  to  demonstrate  features Happy  teams!
  40. 40. BDD  involves  a  major  culture  change BDD  Adop>on  -­‐  Tips  and  Tricks Don’t  skimp  on  training! Put  care  into  your  test  automa;on   Need  tester  and  BA  buy-­‐in
  41. 41. References http://jbehave.org BDD in Java http://thucydides.info Living Documentation Issue tracking and Agile project management Manual test case management in JIRA
  42. 42. Thank you! John Ferguson Smart john.smart@wakaleo.com wakaleo http://www.wakaleo.com

×