Skip to content

Don't convert built-in (reserved) pytest markers to allure tags (fix #817) #862

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

sharovd
Copy link
Contributor

@sharovd sharovd commented May 17, 2025

Context

  • Fix the issue to prevent saving marks with parameters as labels → tag #817

  • Code changes:

    • The pytest_markers(item) method in utils.py has been simplified - now only "simple" user-defined pytest markers are converted to allure tags. Built-in (reserved) markers (e.g. skip, xfail, etc.) are now ignored. The approach was taken from allure-pytest-bdd implementation
  • Unit tests changes:

    • Existing tests in tag_test.py have been updated, new tests have been added for each built-in (reserved) marker to verify they are ignored
    • Renamed both the update and the new tests to make their purpose clearer
    • Removed test_pytest_marker_with_kwargs_native_encoding as a duplicate of test_pytest_marker_with_kwargs_utf_encoding - they looked identical
    • Updated the affected test in pytest_rerunfailures_test.py accordingly

Checklist

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants