You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Scenario versus ScenarioOutline detection logic in behave/runner.py is extremely brittle
because it relies on English keyword "Scenario".
This solution will not work in other languages except in English.
In addition, by now Gherkin supports multiple aliases for Scenario (even in English language).
Therefore, it is better to check is-instance-of(Scenario) instead of checking the keyword, like:
Run behavex features against the behave/tools/test-features/french.feature (using keyword: Scénario (with accept)
File "/.../behavex/runner.py", line 2xx, in create_scenario_line_references
for scenario_multiline in scenario.scenarios:
AttributeError: 'Scenario' object has no attribute 'scenarios'
Expected behavior
Scenario detection logic should be independent of keywords and should work for any language.
Version Info:
behavex v2.0.2 (current HEAD of repository)
The text was updated successfully, but these errors were encountered:
Describe the bug
Scenario versus ScenarioOutline detection logic in
behave/runner.py
is extremely brittlebecause it relies on English keyword "Scenario".
This solution will not work in other languages except in English.
In addition, by now Gherkin supports multiple aliases for Scenario (even in English language).
Therefore, it is better to check
is-instance-of(Scenario)
instead of checking the keyword, like:To Reproduce
Steps to reproduce the behavior:
behavex features
against thebehave/tools/test-features/french.feature
(using keyword:Scénario
(with accept)Expected behavior
Scenario detection logic should be independent of keywords and should work for any language.
Version Info:
The text was updated successfully, but these errors were encountered: