Posts

Showing posts with the label SpecFlow

The power of SpecFlow

Writing test could be boring and stakeholders could know how your software should behave. SpecFlow could help you. It's a framework for BDD that uses an extension of Visual Studio that transforms the feature asked by user into code to test. SpecFlow allows you to write the behaviors in your native language and displays the data in a form like Excel table. Install SpecFlow You have to install the extension for Visual Studio in your test project. Install this package, nuget SpecFlow , SpecFlow.Tools.MsBuild.Generation , that will generate the code from our IDE and SpecFlow.xUnit ( if you're using xUnit) that will allow Visual Studio to find the test that specFlow will generate automatically. Background Suppose you want to create tests for a fruit and vegetable warehouse with online purchase. However, be careful to split the sections correctly and it is what I'd like to dwell on. Background is the section where you collect all tha