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.

QA Fest 2015. Gáspár Nagy. BDD Crash Course for Testers

387 views

Published on

I'm a developer. Similarly to other developers, I like dealing with technologies, architectures and solutions. I also like thinking about ways how to do this better and better. 2009 was the first time I encountered behavior driven development (BDD) -- as a tool to extend our agile development process to the entire project, including testers and product owners. BDD works like a glue that connects and reinforces agile methods you already use, making one plus one more than two.
BDD is still often regarded as a developer tool, so in this session, I would like to explain why Testers should care about BDD: What it is good for? What benefits you might expect? What is the role and responsibility of a tester in a BDD process? What is Gherkin and why do we care about vegetables at all?

Published in: Education
  • Be the first to comment

  • Be the first to like this

QA Fest 2015. Gáspár Nagy. BDD Crash Course for Testers

  1. 1. BDD Crash Course for Testers Gaspar Nagy coach • trainer • bdd addict • creator of specflow @gasparnagy • gaspar@specsolutions.eu
  2. 2. Copyright © Gaspar Nagy What is BDD?
  3. 3. Copyright © Gaspar Nagy BDD? BDD is a second-generation, outside-in, pull-based, multiple- stakeholder, multiple-scale, high- automation, agile methodology. It describes a cycle of interactions with well-defined outputs, resulting in the delivery of working, tested software that matters. Dan North, Agile Testing, Specifications and BDD Exchange 2009
  4. 4. Copyright © Gaspar Nagy BDD Behavior Driven Development TDD Test Driven Development DDD Domain Driven Design ATDD Acceptance Test Driven Development User Stories Specification by Example Definition of Done Outside-In Development DSL Domain Specific Language
  5. 5. Copyright © Gaspar Nagy FEAR
  6. 6. My Story Agile Engineering (XP, TDD, pairing) Agile Project Mgmt. (Scrum, Kanban) Agile Requirement Analysis (User Story, Acceptance Criteria) Agile Testing (bug prevention, exploratory testing, context- driven)
  7. 7. Bug Hunting → Bug Prevention
  8. 8. Copyright © Gaspar Nagy Requirements vs. Tests As formality increases, tests and requirements become indistinguishable. At the limit, tests and requirements are equivalent. Equivalence Hypothesis (Martin, Melnik) Pic: Martin/Melnik: Requirements and Tests
  9. 9. Copyright © Gaspar Nagy Specification-By-Example Example Tests Specifications consist of describe validate fulfillment Source: Gojko Adzic – Bridging the Communication Gap
  10. 10. My Story Agile Engineering (XP, TDD, pairing) Agile Project Mgmt. (Scrum, Kanban) Agile Requirement Analysis (User Story, Acceptance Criteria) Agile Testing (bug prevention, exploratory testing, context- driven) BDD
  11. 11. Copyright © Gaspar Nagy BDD BDD = Product Ownership + Collaboration + Automation on the product of requirements real
  12. 12. Team Foundation Server Version Control TeamFoundation Server Workitems SpecLog Story Maps Product Backlog Sprint Backlog Task Board SpecFlow Scenarios Test- auto- mation Product Living Documen- tation Our Process Source: TechTalk (www.techtalk.at)
  13. 13. Planning a story with acceptance criteria “Imagine this story is already implemented: How would you verify it?” “I would try to put a book into the shopping cart …” “I would try to remove a book from the shopping cart…” “I’d check whether the shopping cart is empty, when I enter the shop …” Shopping cart should be empty when entering the shop
  14. 14. Gherkin Scenarios Scenario: Books can be added to the shopping basket Given the following books |Author |Title | |Martin Fowler |Analysis Patterns | |Gojko Adzic |Bridging the Communication Gap | And my shopping basket is empty When I add the book “Analysis Patterns” to my shopping basket Then my shopping basket should contain 1 copy of “Analysis Patterns”
  15. 15. Copyright © Gaspar Nagy DEMO SpecFlow in Action
  16. 16. Copyright © Gaspar Nagy Test automation is hard
  17. 17. Approach and Landing Tests Source: https://en.Wikipedia.org/wiki/Approach_and_Landing_Tests
  18. 18. An example of using stubs… Source: https://en.Wikipedia.org/wiki/Approach_and_Landing_Tests
  19. 19. Copyright © Gaspar Nagy Test-first thinking in designing complex applications helps a lot for test automation efficiency
  20. 20. Copyright © Gaspar Nagy Test-first is hard • When we exploring new areas/technologies • When we need to work with legacy systems • When … But this should not be an excuse but a source of inspiration!
  21. 21. Copyright © Gaspar Nagy
  22. 22. Copyright © Gaspar Nagy SpecFlow Course Kiev 9-11 November
  23. 23. Thank you! See you at on scrummaster.com.ua's booth! Gaspar Nagy coach • trainer • bdd addict • creator of specflow @gasparnagy • gaspar@specsolutions.eu

×