-
Notifications
You must be signed in to change notification settings - Fork 238
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
Correctly expanding Scenario Outline params for pytest BDD (fixes #636) #644
Conversation
This fixes #636 by making each scenario outline param a separate param in the generated allure JSON.
Will write unit tests later today and am signing the CLA now. |
Example of bad JSON before this change:
Good JSON after this change:
|
So I've been working through the broken tests but would like some confirmation that this solution will be acceptable before I spend much more time on this if that's possible? |
Any update, please. We have updated our feature files as per pytest-bdd 5.0.0, we didnt realize about this allure reporting issue. This issue blocks us from using pytest-bdd 5.0.0 |
@skhomuti is there a problem with this bug fix? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks fine @chasinglogic
Can we please fix this code merge errors |
@aspenboy @JagadeeshJayachandran while I appreciate the reviews, AFAICT the maintainer of this repository is @sseliverstov and they haven't merged any PRs in quite a long time. I will not be monitoring this PR for further updates. |
@chasinglogic hi! Thank you for your contribution and sorry for a little bit inactive period. I'll check this PR and return back for you with feedback. 🙏 |
hello guys! Will that fix will be released this year? @sseliverstov @skhomuti what do you think? thanks in advance |
This fixes #636 by making each scenario outline param a separate param in the
generated allure JSON.
Context
When using a
Scenario Outline
and pytest-bdd the parameters passed to the allure listener were of the incorrect type. TheParameter
class in Allure expects thevalue
field to be aString
but since the callspec has_pytest_bdd_example
which is a dictionary the value would be of that type. Which would serialise to JSON correctly but cause the following error when Allure generate attempted to deserialise it:This change expands the pytest bdd examples so they are each a parameter and brings it in line with other test frameworks and Allure behaviour.
Checklist