SlideShare a Scribd company logo
BDD Scenarios in a
Testing Strategy
A case study
16/11/2023 – AgileTD
Gáspár Nagy
coach • trainer • bdd addict • creator of specflow
https://bddbooks.com • “Discovery” • “Formulation”
@gasparnagy • gaspar@specsolutions.eu
ChatGPT
free
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Today…
• Super brief BDD & SpecSync intro
• The SpecSync quality strategy
• Living Documentation and Traceability
• Wrap-up, Q&A
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Let’s get prepared…
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
This is a BDD scenario
Scenario: Discount is applied when item added to the cart
Given a user without submitted order
And they selected a book that costs €50
When the user adds the book to the cart
Then the cart sub-total should be €45
BDD IS NOT
TESTING!
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
BDD Practices
Image source: https://cucumber.io/docs/bdd/
Discovery
Shared understanding is established through
collaboration and structured conversations
Formulation
The examples of system behaviour are
documented as scenarios
Automation
Scenarios are automated to be able to verify
the behaviour of the system
SpecSync for Azure DevOps
synchronize • share • trace
<TRX>
<JUnit XML>
<Cucumber JSON>
<…>
synchronize
(push)
(pull)
run tests
BUG
1234
share
(publish test results)
trace
SpecSync for Azure DevOps
synchronize • share • trace
Started in 2015
Cross-platform (Win/Linux/macOS/Docker)
Supports all major BDD Frameworks (SpecFlow, Cucumber, Behave, …)
Supports 5 Azure DevOps versions, Jira Data Center & Jira Cloud
60k+ line of code (C#)
Survived 3 major updates and an ADO API change
Build with BDD/SpecFlow (~300 scenarios)
Uses SpecSync for traceability – eat your own dogfood
SpecSync for Azure DevOps
synchronize • share • trace
Rule: Can create new Test Case work items from scenarios
Scenario: A new scenario is linked to a new Test Case
Given there is an Azure DevOps project
And there is a scenario in the local repository
"""
Scenario: Sample scenario
Given there is something
When I do something
Then something will happen
"""
When the local repository is synchronized with push
Then a new Test Case work item "Scenario: Sample scenario" is created in the project
And the Test Case contains the following test steps
| step |
| Given there is something |
| When I do something |
| Then something will happen |
And a tag "@tc:[id-of-new-test-case]" is added to the scenario in the local repository
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
The SpecSync Quality
Strategy
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
The
Pyramid
is
not
enough
Test Automation Pyramid: Mike Cohn – Succeeding with Agile
Pic: http://gasparnagy.com/2017/02/balancing-scenarios-and-unit-tests-case-study-with-specflow/
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
There
is
a
carnival
of
pyramids!
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
More Agile Testing: One-page test plan
Source: More Agile Testing, page 95, Bernice Niel Ruhland
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
The four-page quality strategy
• A quality strategy is like an overall test plan – gives a guidance for the whole
team about how we address quality
• Custom & specific to your project, but keep it short
• SpecSync’s strategy* has the following sections:
• Challenges (Risks)
• Quality Aspects
• Testing Methods
• Each with: purpose, automation strategy, structure, out-of-scope
• Feedback channels
THE STRATEGY
EVOLVES!
*Download current snapshot from: http://speclink.me/webinar190221-strategy
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Challenges (Risks)
• SpecSync is an integration product
• The quality cannot be fully ensured
• Quality changes externally (e.g., new version of ADO comes out)
• The majority of the business value cannot be tested without integration
• Supports 8 platforms, 5 target ADO versions, 15+ BDD Frameworks and 8
SpecFlow versions
• ADO versions: TFS 2017, TFS 2018, ADO 2019, ADO 2020, ADO Services (cloud)
• Critical for clients:
• chance of blocking traceability (e.g., traceability cannot be enforced if SpecSync does not
work)
• chance of obscuring traceability (e.g., generating unnecessary changes)
• chance of data loss (e.g., SpecSync deletes important data due to a bug)
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Why the Pyramid® is not enough as a strategy
WHAT WE WANT
IS QUALITY!
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Breaking down the undefinable quality:
quality aspects (sample)
Functional
• Works as
expected
• Expectations
are good
• Expectations
are
documented
Operational
• Secure
• Fast
• Convenient
• Pretty
• Consistent
• Predictable
Strategic
• Maintainable
• Architecture
• Code quality
• Easy to
integrate
• Flexible
Source: Kevlin Henney
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
SpecSync quality aspects
Functional
• Features documented and
work
• Supports different BDD
frameworks
• Supports different ADO
versions
• Handles variations in
configuration
• Handles variations in BDD
framework test results
• Handles ADO integration
edge cases (version, size
specialties)
Operational
• Works on different platforms
• Secure
• Understandable output, easy
to diagnose
user/configuration errors
• Provides guidance for
configuration
• Works with acceptable speed
(processes at least 100
scenario per minute)
Strategic
• Has a fast & offline
development environment
• Easy to make a fix, hotfix,
proposed fix or spike
• Easy to maintain long-term
• Flexible to support custom
development processes of the
clients
• Easily extensible for new BDD
frameworks and new ADO
versions
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Choosing
test
methods
Automated BDD Scenarios
(SpecFlow, Integration)
SpecSync
ADO
ADO
2019
TFS
2017
TFS
2018
STUB
ADO
SpecSync Algorithmic Logic
Tests (MsTest, Unit)
ADO Integration Tests
(MsTest, Integration)
sync
engine
service classes
console API
Smoke Tests
(SpecFlow, E2E)
Exploratory
Features documented and work
Supports different ADO versions
Has fast & offline dev env
Works on different platforms
Handles variations in BDD frw test results Handles ADO integration edge cases
Understandable output
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Code Coverage Results
Type Test Count Local execution time Coverage
Unit 462 2 sec 30%
ADO Integration 117 7 min 19%
Specs (ADO) 263 9.6 min 76%
Specs (Stub) 263 15.5 sec 73%
Smoke (ADO) 51 5.9 min N/A
Aggregated 1156 N/A 89%
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Testing
methods
&
Feedback
channels
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Living Documentation
and Traceability
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Living Documentation
Scenarios describe the requirements in a business-readable form. As
they are automated, by running them as tests, they can tell us when the
implementation diverges from our expectations – so it becomes living
documentation that the whole team can rely on.
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
The living documentation is a documentation!
http://speclink.me/specsyncdoc
STRUCTURE IT
AS A DOC!
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Feature – Rule – Scenario
Feature: Linking Work Items and other artifacts using tags
Rule: Establish work item links based on scenario tags
Scenario: A work item link tag added to the scenario
Scenario: A work item link tag added to the feature
Rule: Link type can be specified
Scenario: "Tests" link is created by default
Scenario: The work item is linked as "Parent“
Scenario: The link type has changed
Rule: Existing links are preserved and links should remain when tag is removed
Scenario: The work item tag is removed from the scenario
Rule: Multiple prefixes can be linked
Scenario: A product backlog link and a bug link tag is added to the scenario
Rule: Pull Requests can be linked […]
Rule: Adding a work item link should trigger an update […]
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Details: hide incidental, show real data
Rule: Establish work item links based on scenario tags
@tc:155
Scenario: A work item link tag added to the scenario
Given there is an Azure DevOps project with a Bug work item
And the synchronizer is configured as
| setting | value |
| synchronization/links[]/tagPrefix | bug |
And a @bug tag has been added to an existing synchronized scenario as:
"""
@tc:[id-of-test-case] @bug:[id-of-pbi]
Scenario: Sample scenario
When I do something
"""
When the local repository is synchronized with push
Then the test case is linked to the Bug work item
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Details: hide incidental, show real data
Rule: Establish work item links based on scenario tags
@tc:155
Scenario: A work item link tag added to the scenario
Given there is an Azure DevOps project with a Bug work item
And the synchronizer is configured as
| setting | value |
| synchronization/links[]/tagPrefix | bug |
And a @bug tag has been added to an existing synchronized scenario as:
"""
@tc:[id-of-test-case] @bug:[id-of-pbi]
Scenario: Sample scenario
When I do something
"""
When the local repository is synchronized with push
Then the test case is linked to the Bug work item
And the synchronizer is configured as
--- table step argument ---
| setting | value |
| synchronization/links[]/tagPrefix | bug |
Applying config settings:
{
"synchronization": {
"links": [
{
"tagPrefix": "bug"
}
]
}
}
-> done: ConfigurationSteps.GivenTheSynchronizerIsConfiguredAs(<table>) (0.3s)
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Tags – break out from strict hierarchy
Three examples from SpecSync tags:
• @customization – cross-cutting feature
• Describes “Customization” features: used to support special development process
requirements of the SpecSync clients.
• @notsupported-tfs2017 – exclusion criteria
• The particular scenario is not supported on the target platform (here TFS2017). These
scenarios are excluded from the CI builds testing that target
• @formulated – SpecSync development process
• Allows specifying (formulating) scenarios and commit them before automation. These
scenarios are excluded from CI builds (they would fail anyway).
Traceability via tags
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
Wrap-up
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy
• How to build and document a quality strategy
• BDD scenarios are phrased using the business language, and therefore the same
scenario can be executed against different targets
• Well-structured BDD scenarios can form a living documentation and enable
traceability
What have we seen?
MAKE YOUR
OWN STRATEGY!
Gáspár Nagy
coach • trainer • bdd addict • creator of specflow
http://bddbooks.com • “Discovery” • “Formulation”
@gasparnagy • gaspar@specsolutions.eu
Copyright © Gaspar Nagy
Copyright © Gaspar Nagy

More Related Content

Similar to BDD Scenarios in a Testing Strategy

PAPI and Promotional Deployment
PAPI and Promotional DeploymentPAPI and Promotional Deployment
PAPI and Promotional Deployment
Akamai Developers & Admins
 
Droidcon Paris 2015
Droidcon Paris 2015Droidcon Paris 2015
Droidcon Paris 2015
Renaud Boulard
 
Tech talk specflow_bddx_hassa_nagy
Tech talk specflow_bddx_hassa_nagyTech talk specflow_bddx_hassa_nagy
Tech talk specflow_bddx_hassa_nagy
Skills Matter
 
Developer Night - Opticon18
Developer Night - Opticon18Developer Night - Opticon18
Developer Night - Opticon18
Optimizely
 
AppSphere 2016 - Automate performance testing with AppDynamics using continuo...
AppSphere 2016 - Automate performance testing with AppDynamics using continuo...AppSphere 2016 - Automate performance testing with AppDynamics using continuo...
AppSphere 2016 - Automate performance testing with AppDynamics using continuo...
Brad Stoner
 
Eradicate Flaky Tests
Eradicate Flaky TestsEradicate Flaky Tests
Eradicate Flaky Tests
Anand Bagmar
 
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...
Gáspár Nagy
 
Test Automation you'll actually Like - Gauge by ThoughtWorks
Test Automation you'll actually Like - Gauge by ThoughtWorksTest Automation you'll actually Like - Gauge by ThoughtWorks
Test Automation you'll actually Like - Gauge by ThoughtWorks
Gemunu Priyadarshana
 
Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...
Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...
Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...
Amaaira Johns
 
Behaviour Driven Development: Oltre i limiti del possibile
Behaviour Driven Development: Oltre i limiti del possibileBehaviour Driven Development: Oltre i limiti del possibile
Behaviour Driven Development: Oltre i limiti del possibile
Iosif Itkin
 
StarWest 2019 - End to end testing: Stupid or Legit?
StarWest 2019 - End to end testing: Stupid or Legit?StarWest 2019 - End to end testing: Stupid or Legit?
StarWest 2019 - End to end testing: Stupid or Legit?
mabl
 
BDD Selenium for Agile Teams - User Stories
BDD Selenium for Agile Teams - User StoriesBDD Selenium for Agile Teams - User Stories
BDD Selenium for Agile Teams - User Stories
Sauce Labs
 
A Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical ExampleA Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical Example
Deborah Schalm
 
A Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical Example A Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical Example
DevOps.com
 
Building A Product Assortment Recommendation Engine
Building A Product Assortment Recommendation EngineBuilding A Product Assortment Recommendation Engine
Building A Product Assortment Recommendation Engine
Databricks
 
DSDT Meetup Nov 2017
DSDT Meetup Nov 2017DSDT Meetup Nov 2017
DSDT Meetup Nov 2017
DSDT_MTL
 
Dsdt meetup 2017 11-21
Dsdt meetup 2017 11-21Dsdt meetup 2017 11-21
Dsdt meetup 2017 11-21
JDA Labs MTL
 
Pa Project And Best Practice 2
Pa Project And Best Practice 2Pa Project And Best Practice 2
Pa Project And Best Practice 2
alice yang
 
Policy as Code: IT Governance With HashiCorp Sentinel
Policy as Code: IT Governance With HashiCorp SentinelPolicy as Code: IT Governance With HashiCorp Sentinel
Policy as Code: IT Governance With HashiCorp Sentinel
Mitchell Pronschinske
 
Streamlining Workflows: Unleashing Automation with Azure and Power Automate
Streamlining Workflows: Unleashing Automation with Azure and Power AutomateStreamlining Workflows: Unleashing Automation with Azure and Power Automate
Streamlining Workflows: Unleashing Automation with Azure and Power Automate
Hamida Rebai Trabelsi
 

Similar to BDD Scenarios in a Testing Strategy (20)

PAPI and Promotional Deployment
PAPI and Promotional DeploymentPAPI and Promotional Deployment
PAPI and Promotional Deployment
 
Droidcon Paris 2015
Droidcon Paris 2015Droidcon Paris 2015
Droidcon Paris 2015
 
Tech talk specflow_bddx_hassa_nagy
Tech talk specflow_bddx_hassa_nagyTech talk specflow_bddx_hassa_nagy
Tech talk specflow_bddx_hassa_nagy
 
Developer Night - Opticon18
Developer Night - Opticon18Developer Night - Opticon18
Developer Night - Opticon18
 
AppSphere 2016 - Automate performance testing with AppDynamics using continuo...
AppSphere 2016 - Automate performance testing with AppDynamics using continuo...AppSphere 2016 - Automate performance testing with AppDynamics using continuo...
AppSphere 2016 - Automate performance testing with AppDynamics using continuo...
 
Eradicate Flaky Tests
Eradicate Flaky TestsEradicate Flaky Tests
Eradicate Flaky Tests
 
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (BDDx L...
 
Test Automation you'll actually Like - Gauge by ThoughtWorks
Test Automation you'll actually Like - Gauge by ThoughtWorksTest Automation you'll actually Like - Gauge by ThoughtWorks
Test Automation you'll actually Like - Gauge by ThoughtWorks
 
Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...
Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...
Get Well Prepared for Google Professional Cloud Developer (GCP-PCD) Certifica...
 
Behaviour Driven Development: Oltre i limiti del possibile
Behaviour Driven Development: Oltre i limiti del possibileBehaviour Driven Development: Oltre i limiti del possibile
Behaviour Driven Development: Oltre i limiti del possibile
 
StarWest 2019 - End to end testing: Stupid or Legit?
StarWest 2019 - End to end testing: Stupid or Legit?StarWest 2019 - End to end testing: Stupid or Legit?
StarWest 2019 - End to end testing: Stupid or Legit?
 
BDD Selenium for Agile Teams - User Stories
BDD Selenium for Agile Teams - User StoriesBDD Selenium for Agile Teams - User Stories
BDD Selenium for Agile Teams - User Stories
 
A Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical ExampleA Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical Example
 
A Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical Example A Discussion of Automated Infrastructure Security with a Practical Example
A Discussion of Automated Infrastructure Security with a Practical Example
 
Building A Product Assortment Recommendation Engine
Building A Product Assortment Recommendation EngineBuilding A Product Assortment Recommendation Engine
Building A Product Assortment Recommendation Engine
 
DSDT Meetup Nov 2017
DSDT Meetup Nov 2017DSDT Meetup Nov 2017
DSDT Meetup Nov 2017
 
Dsdt meetup 2017 11-21
Dsdt meetup 2017 11-21Dsdt meetup 2017 11-21
Dsdt meetup 2017 11-21
 
Pa Project And Best Practice 2
Pa Project And Best Practice 2Pa Project And Best Practice 2
Pa Project And Best Practice 2
 
Policy as Code: IT Governance With HashiCorp Sentinel
Policy as Code: IT Governance With HashiCorp SentinelPolicy as Code: IT Governance With HashiCorp Sentinel
Policy as Code: IT Governance With HashiCorp Sentinel
 
Streamlining Workflows: Unleashing Automation with Azure and Power Automate
Streamlining Workflows: Unleashing Automation with Azure and Power AutomateStreamlining Workflows: Unleashing Automation with Azure and Power Automate
Streamlining Workflows: Unleashing Automation with Azure and Power Automate
 

More from Gáspár Nagy

Ramp up your testing solution, ExpoQA 2023
Ramp up your testing solution, ExpoQA 2023Ramp up your testing solution, ExpoQA 2023
Ramp up your testing solution, ExpoQA 2023
Gáspár Nagy
 
Fighting against technical debt (CukenFest 2020)
Fighting against technical debt (CukenFest 2020)Fighting against technical debt (CukenFest 2020)
Fighting against technical debt (CukenFest 2020)
Gáspár Nagy
 
Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...
Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...
Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...
Gáspár Nagy
 
Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...
Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...
Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...
Gáspár Nagy
 
Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)
Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)
Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)
Gáspár Nagy
 
Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)
Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)
Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)
Gáspár Nagy
 
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...
Gáspár Nagy
 
A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...
A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...
A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...
Gáspár Nagy
 
Property Based BDD Examples (ETSI UCAAT 2016, Budapest)
Property Based BDD Examples (ETSI UCAAT 2016, Budapest)Property Based BDD Examples (ETSI UCAAT 2016, Budapest)
Property Based BDD Examples (ETSI UCAAT 2016, Budapest)
Gáspár Nagy
 
Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...
Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...
Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...
Gáspár Nagy
 
Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...
Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...
Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...
Gáspár Nagy
 
Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)
Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)
Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)
Gáspár Nagy
 
Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)
Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)
Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)
Gáspár Nagy
 

More from Gáspár Nagy (13)

Ramp up your testing solution, ExpoQA 2023
Ramp up your testing solution, ExpoQA 2023Ramp up your testing solution, ExpoQA 2023
Ramp up your testing solution, ExpoQA 2023
 
Fighting against technical debt (CukenFest 2020)
Fighting against technical debt (CukenFest 2020)Fighting against technical debt (CukenFest 2020)
Fighting against technical debt (CukenFest 2020)
 
Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...
Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...
Süllyedünk! Ütközés a tesztelési jégheggyel (Teszt & Tea Meeup Budapest, 2018...
 
Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...
Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...
Continuous Behavior - BDD in Continuous Delivery (CoDers Who Test, Gothenburg...
 
Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)
Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)
Behavior Driven UI Automation (Agile Testing Days 2017, Potsdam)
 
Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)
Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)
Testing is Difficult (Agile in the City Bristol 2017, Lightening talk)
 
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...
Behavior Driven Web UI Automation with Selenium and Cucumber/SpecFlow (Qualit...
 
A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...
A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...
A tesztelés szerepe folyamatos kihelyezést használó projektekben (Microsoft, ...
 
Property Based BDD Examples (ETSI UCAAT 2016, Budapest)
Property Based BDD Examples (ETSI UCAAT 2016, Budapest)Property Based BDD Examples (ETSI UCAAT 2016, Budapest)
Property Based BDD Examples (ETSI UCAAT 2016, Budapest)
 
Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...
Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...
Given/When/Then-ready sprint planning with Example Mapping (Agilia Budapest 2...
 
Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...
Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...
Introducing BDD to Legacy Applications with SpecFlow/Cucumber (Agilia Confere...
 
Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)
Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)
Folyamatos integráció és kódépítés (ALM Day Budapest, 24/11/2015, Hungarian)
 
Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)
Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)
Given/When/Then-ready sprint planning (Agile Tour Vienna 2015)
 

Recently uploaded

Hotel Management Software Development Company
Hotel Management Software Development CompanyHotel Management Software Development Company
Hotel Management Software Development Company
XongoLab Technologies LLP
 
Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...
Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...
Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...
87tomato
 
Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...
Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...
Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...
norina2645
 
Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...
Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...
Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...
902basic
 
Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...
Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...
Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...
shanihomely
 
Introduction to Cloud computing for Internet of Things
Introduction to Cloud computing for Internet of ThingsIntroduction to Cloud computing for Internet of Things
Introduction to Cloud computing for Internet of Things
NachuSubramanian1
 
HIRE A HACKER FOR CHEATING HUSBAND/WIFE)
HIRE A HACKER FOR CHEATING HUSBAND/WIFE)HIRE A HACKER FOR CHEATING HUSBAND/WIFE)
HIRE A HACKER FOR CHEATING HUSBAND/WIFE)
josephinedrea942
 
Mobile App Development Company in Noida - Drona Infotech.
Mobile App Development Company in Noida - Drona Infotech.Mobile App Development Company in Noida - Drona Infotech.
Mobile App Development Company in Noida - Drona Infotech.
Mobile App Development Company in Noida - Drona Infotech
 
Authentication Review-June -2024 AP & TS.pptx
Authentication Review-June -2024 AP & TS.pptxAuthentication Review-June -2024 AP & TS.pptx
Authentication Review-June -2024 AP & TS.pptx
DEMONDUOS
 
Odoo E-commerce website development guides
Odoo E-commerce website development guidesOdoo E-commerce website development guides
Odoo E-commerce website development guides
jhkdigitalmarketing
 
Attendance Tracking From Paper To Digital
Attendance Tracking From Paper To DigitalAttendance Tracking From Paper To Digital
Attendance Tracking From Paper To Digital
Task Tracker
 
Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...
Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...
Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...
3610stuck
 
Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...
Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...
Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...
aslasdfmkhan4750
 
Artificial intelligence in customer services or chatbots
Artificial intelligence  in customer services or chatbotsArtificial intelligence  in customer services or chatbots
Artificial intelligence in customer services or chatbots
kayash1656
 
Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...
Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...
Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...
confluent
 
Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...
Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...
Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...
ashiklo9823
 
UMiami degree offer diploma Transcript
UMiami degree offer diploma TranscriptUMiami degree offer diploma Transcript
UMiami degree offer diploma Transcript
attueb
 
TEQnation 2024: Sustainable Software: May the Green Code Be with You
TEQnation 2024: Sustainable Software: May the Green Code Be with YouTEQnation 2024: Sustainable Software: May the Green Code Be with You
TEQnation 2024: Sustainable Software: May the Green Code Be with You
marcofolio
 
Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...
Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...
Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...
rachitkumar09887
 
AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.
AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.
AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.
Srinivas Dukka
 

Recently uploaded (20)

Hotel Management Software Development Company
Hotel Management Software Development CompanyHotel Management Software Development Company
Hotel Management Software Development Company
 
Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...
Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...
Verified Girls Call Mumbai 👀 9820252231 👀 Cash Payment With Room DeliveryDeli...
 
Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...
Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...
Celebrity Girls Call Mumbai 🛵🚡9910780858 💃 Choose Best And Top Girl Service A...
 
Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...
Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...
Private Girls Call Navi Mumbai 🛵🚡9820252231 💃 Choose Best And Top Girl Servic...
 
Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...
Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...
Russian Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service ...
 
Introduction to Cloud computing for Internet of Things
Introduction to Cloud computing for Internet of ThingsIntroduction to Cloud computing for Internet of Things
Introduction to Cloud computing for Internet of Things
 
HIRE A HACKER FOR CHEATING HUSBAND/WIFE)
HIRE A HACKER FOR CHEATING HUSBAND/WIFE)HIRE A HACKER FOR CHEATING HUSBAND/WIFE)
HIRE A HACKER FOR CHEATING HUSBAND/WIFE)
 
Mobile App Development Company in Noida - Drona Infotech.
Mobile App Development Company in Noida - Drona Infotech.Mobile App Development Company in Noida - Drona Infotech.
Mobile App Development Company in Noida - Drona Infotech.
 
Authentication Review-June -2024 AP & TS.pptx
Authentication Review-June -2024 AP & TS.pptxAuthentication Review-June -2024 AP & TS.pptx
Authentication Review-June -2024 AP & TS.pptx
 
Odoo E-commerce website development guides
Odoo E-commerce website development guidesOdoo E-commerce website development guides
Odoo E-commerce website development guides
 
Attendance Tracking From Paper To Digital
Attendance Tracking From Paper To DigitalAttendance Tracking From Paper To Digital
Attendance Tracking From Paper To Digital
 
Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...
Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...
Mumbai Girls Call Mumbai 🎈🔥9930687706 🔥💋🎈 Provide Best And Top Girl Service A...
 
Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...
Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...
Independent Girls Call ServiCe Hyderabad 0000000000 Tanisha Best High Class H...
 
Artificial intelligence in customer services or chatbots
Artificial intelligence  in customer services or chatbotsArtificial intelligence  in customer services or chatbots
Artificial intelligence in customer services or chatbots
 
Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...
Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...
Unleashing the Future: Building a Scalable and Up-to-Date GenAI Chatbot with ...
 
Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...
Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...
Vip Girls Call ServiCe Hyderabad 0000000000 Pooja Best High Class Hyderabad A...
 
UMiami degree offer diploma Transcript
UMiami degree offer diploma TranscriptUMiami degree offer diploma Transcript
UMiami degree offer diploma Transcript
 
TEQnation 2024: Sustainable Software: May the Green Code Be with You
TEQnation 2024: Sustainable Software: May the Green Code Be with YouTEQnation 2024: Sustainable Software: May the Green Code Be with You
TEQnation 2024: Sustainable Software: May the Green Code Be with You
 
Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...
Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...
Agra Girls Call Agra 0X0000000X Unlimited Short Providing Girls Service Avail...
 
AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.
AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.
AWS DevOps-Tutorial CHANAKYA SRIYAN DUKKA.
 

BDD Scenarios in a Testing Strategy

  • 1. BDD Scenarios in a Testing Strategy A case study 16/11/2023 – AgileTD Gáspár Nagy coach • trainer • bdd addict • creator of specflow https://bddbooks.com • “Discovery” • “Formulation” @gasparnagy • gaspar@specsolutions.eu ChatGPT free
  • 2. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Today… • Super brief BDD & SpecSync intro • The SpecSync quality strategy • Living Documentation and Traceability • Wrap-up, Q&A
  • 3. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Let’s get prepared…
  • 4. Copyright © Gaspar Nagy Copyright © Gaspar Nagy This is a BDD scenario Scenario: Discount is applied when item added to the cart Given a user without submitted order And they selected a book that costs €50 When the user adds the book to the cart Then the cart sub-total should be €45 BDD IS NOT TESTING!
  • 5. Copyright © Gaspar Nagy Copyright © Gaspar Nagy BDD Practices Image source: https://cucumber.io/docs/bdd/ Discovery Shared understanding is established through collaboration and structured conversations Formulation The examples of system behaviour are documented as scenarios Automation Scenarios are automated to be able to verify the behaviour of the system
  • 6. SpecSync for Azure DevOps synchronize • share • trace <TRX> <JUnit XML> <Cucumber JSON> <…> synchronize (push) (pull) run tests BUG 1234 share (publish test results) trace
  • 7. SpecSync for Azure DevOps synchronize • share • trace Started in 2015 Cross-platform (Win/Linux/macOS/Docker) Supports all major BDD Frameworks (SpecFlow, Cucumber, Behave, …) Supports 5 Azure DevOps versions, Jira Data Center & Jira Cloud 60k+ line of code (C#) Survived 3 major updates and an ADO API change Build with BDD/SpecFlow (~300 scenarios) Uses SpecSync for traceability – eat your own dogfood
  • 8. SpecSync for Azure DevOps synchronize • share • trace Rule: Can create new Test Case work items from scenarios Scenario: A new scenario is linked to a new Test Case Given there is an Azure DevOps project And there is a scenario in the local repository """ Scenario: Sample scenario Given there is something When I do something Then something will happen """ When the local repository is synchronized with push Then a new Test Case work item "Scenario: Sample scenario" is created in the project And the Test Case contains the following test steps | step | | Given there is something | | When I do something | | Then something will happen | And a tag "@tc:[id-of-new-test-case]" is added to the scenario in the local repository
  • 9. Copyright © Gaspar Nagy Copyright © Gaspar Nagy The SpecSync Quality Strategy
  • 10. Copyright © Gaspar Nagy Copyright © Gaspar Nagy The Pyramid is not enough Test Automation Pyramid: Mike Cohn – Succeeding with Agile Pic: http://gasparnagy.com/2017/02/balancing-scenarios-and-unit-tests-case-study-with-specflow/
  • 11. Copyright © Gaspar Nagy Copyright © Gaspar Nagy There is a carnival of pyramids!
  • 12. Copyright © Gaspar Nagy Copyright © Gaspar Nagy More Agile Testing: One-page test plan Source: More Agile Testing, page 95, Bernice Niel Ruhland
  • 13. Copyright © Gaspar Nagy Copyright © Gaspar Nagy The four-page quality strategy • A quality strategy is like an overall test plan – gives a guidance for the whole team about how we address quality • Custom & specific to your project, but keep it short • SpecSync’s strategy* has the following sections: • Challenges (Risks) • Quality Aspects • Testing Methods • Each with: purpose, automation strategy, structure, out-of-scope • Feedback channels THE STRATEGY EVOLVES! *Download current snapshot from: http://speclink.me/webinar190221-strategy
  • 14. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Challenges (Risks) • SpecSync is an integration product • The quality cannot be fully ensured • Quality changes externally (e.g., new version of ADO comes out) • The majority of the business value cannot be tested without integration • Supports 8 platforms, 5 target ADO versions, 15+ BDD Frameworks and 8 SpecFlow versions • ADO versions: TFS 2017, TFS 2018, ADO 2019, ADO 2020, ADO Services (cloud) • Critical for clients: • chance of blocking traceability (e.g., traceability cannot be enforced if SpecSync does not work) • chance of obscuring traceability (e.g., generating unnecessary changes) • chance of data loss (e.g., SpecSync deletes important data due to a bug)
  • 15. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Why the Pyramid® is not enough as a strategy WHAT WE WANT IS QUALITY!
  • 16. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Breaking down the undefinable quality: quality aspects (sample) Functional • Works as expected • Expectations are good • Expectations are documented Operational • Secure • Fast • Convenient • Pretty • Consistent • Predictable Strategic • Maintainable • Architecture • Code quality • Easy to integrate • Flexible Source: Kevlin Henney
  • 17. Copyright © Gaspar Nagy Copyright © Gaspar Nagy SpecSync quality aspects Functional • Features documented and work • Supports different BDD frameworks • Supports different ADO versions • Handles variations in configuration • Handles variations in BDD framework test results • Handles ADO integration edge cases (version, size specialties) Operational • Works on different platforms • Secure • Understandable output, easy to diagnose user/configuration errors • Provides guidance for configuration • Works with acceptable speed (processes at least 100 scenario per minute) Strategic • Has a fast & offline development environment • Easy to make a fix, hotfix, proposed fix or spike • Easy to maintain long-term • Flexible to support custom development processes of the clients • Easily extensible for new BDD frameworks and new ADO versions
  • 18. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Choosing test methods Automated BDD Scenarios (SpecFlow, Integration) SpecSync ADO ADO 2019 TFS 2017 TFS 2018 STUB ADO SpecSync Algorithmic Logic Tests (MsTest, Unit) ADO Integration Tests (MsTest, Integration) sync engine service classes console API Smoke Tests (SpecFlow, E2E) Exploratory Features documented and work Supports different ADO versions Has fast & offline dev env Works on different platforms Handles variations in BDD frw test results Handles ADO integration edge cases Understandable output
  • 19. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Code Coverage Results Type Test Count Local execution time Coverage Unit 462 2 sec 30% ADO Integration 117 7 min 19% Specs (ADO) 263 9.6 min 76% Specs (Stub) 263 15.5 sec 73% Smoke (ADO) 51 5.9 min N/A Aggregated 1156 N/A 89%
  • 20. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Testing methods & Feedback channels
  • 21. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Living Documentation and Traceability
  • 22. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Living Documentation Scenarios describe the requirements in a business-readable form. As they are automated, by running them as tests, they can tell us when the implementation diverges from our expectations – so it becomes living documentation that the whole team can rely on.
  • 23. Copyright © Gaspar Nagy Copyright © Gaspar Nagy The living documentation is a documentation! http://speclink.me/specsyncdoc STRUCTURE IT AS A DOC!
  • 24. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Feature – Rule – Scenario Feature: Linking Work Items and other artifacts using tags Rule: Establish work item links based on scenario tags Scenario: A work item link tag added to the scenario Scenario: A work item link tag added to the feature Rule: Link type can be specified Scenario: "Tests" link is created by default Scenario: The work item is linked as "Parent“ Scenario: The link type has changed Rule: Existing links are preserved and links should remain when tag is removed Scenario: The work item tag is removed from the scenario Rule: Multiple prefixes can be linked Scenario: A product backlog link and a bug link tag is added to the scenario Rule: Pull Requests can be linked […] Rule: Adding a work item link should trigger an update […]
  • 25. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Details: hide incidental, show real data Rule: Establish work item links based on scenario tags @tc:155 Scenario: A work item link tag added to the scenario Given there is an Azure DevOps project with a Bug work item And the synchronizer is configured as | setting | value | | synchronization/links[]/tagPrefix | bug | And a @bug tag has been added to an existing synchronized scenario as: """ @tc:[id-of-test-case] @bug:[id-of-pbi] Scenario: Sample scenario When I do something """ When the local repository is synchronized with push Then the test case is linked to the Bug work item
  • 26. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Details: hide incidental, show real data Rule: Establish work item links based on scenario tags @tc:155 Scenario: A work item link tag added to the scenario Given there is an Azure DevOps project with a Bug work item And the synchronizer is configured as | setting | value | | synchronization/links[]/tagPrefix | bug | And a @bug tag has been added to an existing synchronized scenario as: """ @tc:[id-of-test-case] @bug:[id-of-pbi] Scenario: Sample scenario When I do something """ When the local repository is synchronized with push Then the test case is linked to the Bug work item And the synchronizer is configured as --- table step argument --- | setting | value | | synchronization/links[]/tagPrefix | bug | Applying config settings: { "synchronization": { "links": [ { "tagPrefix": "bug" } ] } } -> done: ConfigurationSteps.GivenTheSynchronizerIsConfiguredAs(<table>) (0.3s)
  • 27. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Tags – break out from strict hierarchy Three examples from SpecSync tags: • @customization – cross-cutting feature • Describes “Customization” features: used to support special development process requirements of the SpecSync clients. • @notsupported-tfs2017 – exclusion criteria • The particular scenario is not supported on the target platform (here TFS2017). These scenarios are excluded from the CI builds testing that target • @formulated – SpecSync development process • Allows specifying (formulating) scenarios and commit them before automation. These scenarios are excluded from CI builds (they would fail anyway).
  • 29. Copyright © Gaspar Nagy Copyright © Gaspar Nagy Wrap-up
  • 30. Copyright © Gaspar Nagy Copyright © Gaspar Nagy • How to build and document a quality strategy • BDD scenarios are phrased using the business language, and therefore the same scenario can be executed against different targets • Well-structured BDD scenarios can form a living documentation and enable traceability What have we seen? MAKE YOUR OWN STRATEGY!
  • 31. Gáspár Nagy coach • trainer • bdd addict • creator of specflow http://bddbooks.com • “Discovery” • “Formulation” @gasparnagy • gaspar@specsolutions.eu
  • 32. Copyright © Gaspar Nagy Copyright © Gaspar Nagy