Refactor producer invocation in cucumber features:
Use "When I successfully execute" instead of "When I execute", and assert that exit status code was successful in this new step.
This commit is contained in:
@@ -12,8 +12,7 @@ Feature: `has_env' condition keyword
|
||||
echo 'evaluated'
|
||||
end
|
||||
"""
|
||||
When I execute the recipe
|
||||
Then the exit status must be 0
|
||||
When I successfully execute the recipe
|
||||
And the output must contain "evaluated"
|
||||
|
||||
Scenario: fails when remote environment variable is not defined
|
||||
@@ -27,6 +26,5 @@ Feature: `has_env' condition keyword
|
||||
echo 'evaluated'
|
||||
end
|
||||
"""
|
||||
When I execute the recipe
|
||||
Then the exit status must be 0
|
||||
When I successfully execute the recipe
|
||||
And the output must not contain "evaluated"
|
||||
|
Reference in New Issue
Block a user