Skip to content
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

Update rule feature to test using tags #1549

Merged
merged 5 commits into from
Jul 9, 2021
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 22 additions & 6 deletions features/docs/gherkin/rule.feature
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ Feature: Rule
Feature: Rule Sample

Rule: This is a rule

Example: First example
Given some context
When I do an action
Expand All @@ -20,9 +19,9 @@ Feature: Rule
When I do another action
Then some other results should be there

Rule: This is a second rule

Example: First example
@rule2_tag
Rule: This is a second rule with a tag
Example: Third example
Given some other context
When I do another action
Then some results should be there
Expand All @@ -38,7 +37,6 @@ Feature: Rule

"""


Rule: I use Gherkin 6+
Example: I can use the Rule keyword
When I run `cucumber -q features/rule.feature`
Expand All @@ -56,11 +54,29 @@ Feature: Rule
When I do another action
Then some other results should be there

Example: First example
@rule2_tag
Example: Third example
Given some other context
When I do another action
Then some results should be there

3 scenarios (3 passed)
9 steps (9 passed)
"""

Rule: Filtering
Example: I can filter on tagged rules using the CLI
When I run `cucumber -q -t @rule2_tag`
Then it should pass with exactly:
"""
Feature: Rule Sample

@rule2_tag
Example: Third example
Given some other context
When I do another action
Then some results should be there

1 scenario (1 passed)
3 steps (3 passed)
"""