-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Scenario Outlines inconsistencies #153
Comments
Checked with @aslakhellesoy and in Gherkin 6 Scenario Outline and Scenario are synonyms - they only differ based on whether they are followed by an Example, so the following are valid:
|
This would require a BC break here, and in Behat though, as outlines are currently treated differently from scenarios in Behat. Btw, I'm wondering how cucumber deals with the output formatting for these cases. Does it still tries to output something looking like a colored gherkin file ? |
I don't think it's necessarily a BC break - it allows some new syntaxes (above) that previously would have been a parse error (our AST would need to still differentiate ScenarioOutline nodes from Scenario nodes, but we could detect which it is based on whether it is followed by Examples) |
ah indeed, if we keep our 2 different nodes based on the presence of Examples, there is no BC break. |
@dpakach As you've been looking at how Examples and Outlines are treated, what do you think about implementing this? |
Just my 2c - the official Gherkin parser does the same - the AST node that gets created depends on the absence/presence of examples. And we managed to release this without any users complaining about BC issues. |
Removing these lines will now produce failing tests |
Checking the parsing examples from Gherkin, the following fail due to issues with scenario outlines:
descriptions.feature - the description on the final Example causes a parse error[moved to Examples description not supported #154]readme_example
,scenario_outlines_with_tags
,several_examples
,tags
) - scenario outlines without an Example are not allowed by our parser but are just ignored by cucumberThe text was updated successfully, but these errors were encountered: