Documentation SpecFlow场景大纲“丢失”示例名称

Documentation SpecFlow场景大纲“丢失”示例名称,documentation,specflow,gherkin,scenarios,Documentation,Specflow,Gherkin,Scenarios,我正在尝试从specflow功能文件生成pdf格式的文档。我正在使用Nuget上的gerkin库来解析文件 我有一些场景提纲,每个场景提纲有2个示例表,根据Cucumber书,完全可以: Scenario Outline: My scenario Given "<this>" first value When I enter some second "<value>" Then the result must be equal to "<expected resu

我正在尝试从specflow功能文件生成pdf格式的文档。我正在使用Nuget上的gerkin库来解析文件

我有一些场景提纲,每个场景提纲有2个示例表,根据Cucumber书,完全可以:

Scenario Outline: My scenario

Given "<this>" first value
When I enter some second "<value>"
Then the result must be equal to "<expected result>"

Examples: Some first list of values // My example name
| this | value | expected result |
| 0    | 1     | 2               |

Examples: Some second list of values  // My example name
| this | value | expected result |
| A    | B     | C               |
我发现问题可能出在SpecFlow库本身,而不是用于解析的gerkin库上——它似乎在创建测试用例时也看不到第二个示例名称

以前有人处理过吗


请有人给场景加上标签。它与场景不同。

Specflow不支持场景大纲中的多个示例块。为什么不把你的第二个例子列表放到第一个列表中呢?i、 e

Examples:
| this | value | expected result |
| 0    | 1     | 2               |
| A    | B     | C               |
如果您确实希望为您可以拥有的不同类型的输入(即所有数字或所有字符)创建不同的测试场景,那么我将创建两个不同的场景大纲,例如

Scenario Outline: Calculate the result for numeric input

Given "<this>" first value
When I enter some second "<value>"
Then the result must be equal to "<expected result>"

Examples:
| this | value | expected result |
| 0    | 1     | 2               |
以及:

场景大纲:计算字母输入的结果

Given "<this>" first value
When I enter some second "<value>"
Then the result must be equal to "<expected result>"

Examples:
| this | value | expected result |
| A    | B     | C               |
Given "<this>" first value
When I enter some second "<value>"
Then the result must be equal to "<expected result>"

Examples:
| this | value | expected result |
| A    | B     | C               |