Member-only story

BDD with C# and .NET

How to use Behaviour-Driven Development (BDD) with C# and SpecFlow

Here is an introductory guide on how to use Behaviour-Driven Development (BDD) with C# and SpecFlow in a .NET application.

xeladu

--

Photo by Taras Shypka on Unsplash

Behaviour-Driven Development (BDD) is a technique of agile software development to ensure that the requirements of the software to be developed are fulfilled. To achieve this a special syntax called Gherkin (see below) is used to write down the specification which then can be translated by tools into test case skeletons. The developers add the test code and write/enhance the application until the test passes.
A big advantage is that stakeholders, customers, business analysts, requirement engineers, all parties of a project can provide tests.

BDD Key features

  • Everyone can provide test cases
  • Test cases are easy to read
  • Good tool support for automation
  • Developers need less domain knowledge
  • Developers can focus on writing tests and features instead of finding test cases
  • Project documentation on the fly

What about Test-Driven…

--

--

No responses yet