SpecFlow+LivingDoc Generator Migration v3.4 to v3.5¶
With version 3.5 the LivingDoc Generator has been updated to support various document generation scenarios.
To upgrade LivingDoc Generator from v3.4 to v3.5 in your solution please follow the steps below.
Make sure that you upgrade both the plugin and the CLI to the same version
The SpecFlow.Plus.LivingDocPlugin has to be updated as a NuGet package in the SpecFlow project
The Command Line Tool (CLI) has to be updated as a dotnet tool:
To update SpecFlow.Plus.LivingDoc.CLI:
– Open a command prompt.
– Run the following command:
dotnet tool update --global SpecFlow.Plus.LivingDoc.CLI
The default file name of the JSON file generated by the LivingDocPlugin has been changed from “FeatureData.json” to “TestExecution.json”. With v3.5 this JSON file contains the test execution details only and the feature files are parsed by the CLI. Make sure to look for this new file after executing your SpecFlow scenarios to be able to pass it to the CLI (see further below).
Please note that if you have configured a custom file path in your
specflow.jsonthen the generated filename will not change automatically with the upgrade. We recommend to change the filename in the configuration to be consistent with the new semantics.
Change your command line scripts and build scripts to call the CLI with the new parameters
- Old command
- New command
livingdoc test-assembly C:\Work\MyProject.Specs\bin\Debug\netcoreapp3.1\MyProject.Specs.dll -t C:\Work\MyProject.Specs\bin\debug\netcoreapp3.1\TestExecution.json
Please note the following changes in the parameter syntax:
- The first parameter of the CLI is a mandatory command name.
- The list of available options depends on the selected command (still many options are available with all commands).
- All parameter names are in kebab format (e.g. test-assembly, feature-folder, work-item-url-template, etc.)
Please check the Troubleshooting page if you run into issues.