Given, When, Then keywords explicitly mapped
See original GitHub issueGiven, When, Then keywords are explicitly mapped, the basic cucumber rules are not getting followed. i.e we are allowed to create duplicate step with a different keyword. For instance given(user navigates to {string}
) is valid as well as then(user navigates to {string}
) is also valid.
I believe the vice versa should be the case, wherein cucumber should allow the use of any keyword to define in the feature file but only one declaration of the step.
Issue Analytics
- State:
- Created 6 years ago
- Comments:5
Top Results From Across the Web
Rules + Examples · Issue #250 · cucumber/common - GitHub
Summary There is no useful mapping between Gherkin and "rules and examples". Expected Behavior I can express Rules and Examples naturally ...
Read more >BDD 101: Writing Good Gherkin - Automation Panda
Writing good feature files is harder that you think. Follow these tried-and-true best practices to write Gherkin like a pro.
Read more >Keyword mapping: What Is It And How To Do It In 2022
Keyword mapping is the process of assigning keywords – discovered during your keyword research – to specific pages on a website based on...
Read more >Gherkin Rules, tags, and Example Mapping | Cucumber Blog
Given/When/Then are the core keywords of Gherkin; Gherkin is the structured syntax understood by automation tools such as Cucumber; Cucumber is ...
Read more >3 What is Cucumber Feature File - YouTube
HelloIn this tutorial, I will explain you complete overview of the feature file and detailed information on Gherkin Keywords.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@lgandecki yes that is exactly what i am saying. cucumber wiki states that, “Every scenario consists of a list of steps, which must start with one of the keywords Given, When, Then, But or And. Cucumber treats them all the same, but you shouldn’t.” The reason cucumber treats them all same is to restrict step duplication and I think we should too.
This is fixed in 0.4.0 , please give it a try, and if still doesn’t work as needed please create a new issue. Thanks for reporting!