I found that this custom tool is used for generation of .cs files from SpecFlow's .feature file. Is there a way to use this tool outside of VS? I would like to call this tool from console for specific .feature file when building my project with NAnt.
Regards,
Vajda Vladimir
You sure can! That is if you mean: "Can I generate unit test code from my .feature-files without using Visual Studio"
I've written about that here: http://www.marcusoft.net/2010/12/specflowexe-and-mstest.html but in short you can use the SpecFlow.exe with the "generateAll" switch, and it will inspect your project settings and generate the appropiate unit tests for you (in my example it's MsTest but it can be any of the supported testing frameworks).
The SpecFlow.exe's help we get the following concise help:
Generate tests from all feature files in a project
usage: specflow generateall projectFile [/force] [/verbose]
projectFile Visual Studio Project File containing features
So for a project called Specs.csproj it would be:
"%ProgramFiles(x86)%\TechTalk\SpecFlow\SpecFlow.exe" generateAll Specs\Specs.csproj /force /verbose
You can read more in my blog post - but this is basically it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With