Specflow error: Force regenerate steps possible?

后端 未结 11 1797
猫巷女王i
猫巷女王i 2021-02-01 14:32

Is it possible to \"force\" regenerate step definitions for a specflow feature file? I have created this feature file but cannot generate all steps. Am getting a message that al

11条回答
  •  悲哀的现实
    2021-02-01 15:17

    You can regenerate all feature file test classes using the SpecFlow-provided tool specflow.exe.

    Assuming that SpecFlow has been installed through NuGet and is in the ./packages directory relative to your current directory, you can run, in the terminal, the command

    .\packages\SpecFlow.X.Y.Z\tools\specflow.exe generateall path\to\myfile.csproj
    

    which will regenerate all feature file unit tests. As the linked page states, you can add the /force flag to force regeneration of all tests.

提交回复
热议问题